Skip to content

Latest commit

 

History

History
655 lines (434 loc) · 17.5 KB

MLD.md

File metadata and controls

655 lines (434 loc) · 17.5 KB

Schema documentation

Generated by MySQL Workbench Model Documentation v1.0.0 - Copyright (c) 2015 Hieu Le

MLD

MLD

Table: acknowledged_Events

Description:

Acknowledged Events

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
user_id INT Not null foreign key to column id on table users.
event_id INT Not null foreign key to column id on table events.
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
acknowledged_events_id_index id INDEX
acknowledged_events_user_id_foreign user_id INDEX
acknowledged_events_event_id_foreign event_id INDEX

Table: checkList_Items

Description:

Items of a checkList

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
title VARCHAR(45) Not null
description LONGTEXT NULL
done TINYINT Not null
checkList_id INT Not null foreign key to column id on table checkLists.
link LONGTEXT NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
checklist_items_id_index id INDEX
checklist_items_checklist_id_foreign checkList_id INDEX

Table: checkList_Tables

Description:

The names of tables where the checklist can be connected to.

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
name VARCHAR(45) Not null

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
checklist_tables_id_index id INDEX

Table: checkList_Types

Description:

Type of checkList

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
name VARCHAR(45) Not null

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
checklist_types_id_index id INDEX

Table: checkLists

Description:

contains checkLists

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
recordId INT Not null id of the element on the specified table
checkListTable_id INT Not null foreign key to column id on table checkList_Tables.
checkListType_id INT Not null foreign key to column id on table checkList_Types.

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
checklists_id_index id INDEX
checklists_checklisttable_id_foreign checkListTable_id INDEX
checklists_checklisttype_id_foreign checkListType_id INDEX

Table: classes

Description:

contain the classes from the cpnv database

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
name VARCHAR(20) Not null
friendlyId VARCHAR(20) Not null id of the class on the cpnv database
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
classes_id_index id INDEX

Table: comments

Description:

contains comments to tasks

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
user_id INT Not null foreign key to column id on table users.
task_id INT Not null foreign key to column id on table tasks.
comment LONGTEXT Not null
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
comments_id_index id INDEX
comments_user_id_foreign user_id INDEX
comments_task_id_foreign task_id INDEX

Table: durations_tasks

Description:

time spend on task

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
user_task_id INT Not null foreign key to column id on table users_tasks.
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL
ended_at DATETIME Not null

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
durations_tasks_id_index id INDEX
durations_tasks_user_task_id_foreign user_task_id INDEX

Table: events

Description:

Events append on a project

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
user_id INT Not null foreign key to column id on table users.
project_id INT Not null foreign key to column id on table projects.
description LONGTEXT Not null
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
events_id_index id INDEX
events_user_id_foreign user_id INDEX
events_project_id_foreign project_id INDEX

Table: files

Description:

Files by project

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
name VARCHAR(45) Not null
description LONGTEXT Not null
url LONGTEXT Not null
mime VARCHAR(45) Not null
size VARCHAR(45) Not null
project_id INT Not null foreign key to column id on table projects.
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
files_id_index id INDEX
files_project_id_foreign project_id INDEX

Table: memberships

Description:

Members of a project

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
user_id INT Not null foreign key to column id on table users.
project_id INT Not null foreign key to column id on table projects.
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
memberships_id_index id INDEX
memberships_user_id_foreign user_id INDEX
memberships_project_id_foreign project_id INDEX

Table: migrations

Description:

Laravel table auto generated

Columns:

Column Data type Attributes Default Description
migration VARCHAR(255) Not null
batch INT Not null

Table: mockups

Description:

Pictures used on scenarios

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
project_id INT Not null foreign key to column id on table projects.
url VARCHAR(500) Not null

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
mockups_id_index id INDEX
mockups_project_id_foreign project_id INDEX

Table: projects

Description:

Contains projects

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
name VARCHAR(45) Not null
description LONGTEXT Not null
startDate DATETIME Not null
endDate DATETIME Not null
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
projects_id_index id INDEX

Table: roles

Description:

Contains diferent users roles

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
name VARCHAR(15) Not null

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
roles_id_index id INDEX

Table: scenario_tests

Description:

contains tests of a scenario

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
date DATETIME Not null
resume VARCHAR(500) NULL
done TINYINT NULL status of the test
user_id INT Not null foreign key to column id on table users.

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
scenario_tests_id_index id INDEX
scenario_tests_user_id_foreign user_id INDEX

Table: scenarios

Description:

Contains scenarios

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
description VARCHAR(500) NULL
name VARCHAR(200) Not null
actif TINYINT Not null '0' know if scenario is aprouved for testing
test_validated TINYINT Not null '0' know if tests are done and OK
checkList_item_id INT Not null foreign key to column id on table checkList_Items.

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
scenarios_id_index id INDEX
scenarios_checklist_item_id_foreign checkList_item_id INDEX

Table: states

Description:

know if a student still into the school

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
name VARCHAR(20) Not null

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
states_id_index id INDEX

Table: statuses

Description:

Tasks status

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
name VARCHAR(20) Not null
description VARCHAR(60) NULL
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY

Table: step_test_results

Description:

Result of each step of a scenario

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
step_id INT Not null foreign key to column id on table steps.
test_id INT Not null foreign key to column id on table scenario_tests.
result VARCHAR(1000) Not null the result written by the user
succes INT Not null '-1' status of the step

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
step_test_results_id_index id INDEX
step_test_results_step_id_foreign step_id INDEX
step_test_results_test_id_foreign test_id INDEX

Table: steps

Description:

Scenario steps

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
action VARCHAR(1000) Not null What is supposed to do
result VARCHAR(1000) Not null What is supposed to append
order INT Not null
scenario_id INT Not null foreign key to column id on table scenarios.
mockup_id INT NULL foreign key to column id on table mockups.

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
steps_id_index id INDEX
steps_scenario_id_foreign scenario_id INDEX
steps_mockup_id_foreign mockup_id INDEX

Table: taskTypes

Description:

Type of Task

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
name VARCHAR(30) Not null
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
tasktypes_id_index id INDEX

Table: tasks

Description:

Contains tasks

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
name VARCHAR(45) Not null
duration INT Not null
priority INT Not null
project_id INT Not null foreign key to column id on table projects.
parent_id INT NULL foreign key to column id on table tasks.
objective_id INT NULL
type_id INT NULL foreign key to column id on table taskTypes.
status_id INT NULL foreign key to column id on table statuses.
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
tasks_id_index id INDEX
tasks_project_id_foreign project_id INDEX
tasks_parent_id_foreign parent_id INDEX
tasks_type_id_foreign type_id INDEX
tasks_status_id_foreign status_id INDEX

Table: users

Description:

Contains users
User are retrieved from the cpnv database

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
friendlyid VARCHAR(255) Not null id given from cpnv database
firstname VARCHAR(20) Not null
lastname VARCHAR(20) Not null
mail VARCHAR(45) Not null
role_id INT Not null foreign key to column id on table roles.
class_id INT NULL foreign key to column id on table classes.
state_id INT Not null foreign key to column id on table states.
password VARCHAR(100) Not null
remember_token LONGTEXT Not null
avatar VARCHAR(45) Not null
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
users_id_index id INDEX
users_role_id_foreign role_id INDEX
users_class_id_foreign class_id INDEX
users_state_id_foreign state_id INDEX

Table: users_tasks

Description:

Users on each task

Columns:

Column Data type Attributes Default Description
id INT PRIMARY, Auto increments, Not null
user_id INT Not null foreign key to column id on table users.
task_id INT Not null foreign key to column id on table tasks.
created_at TIMESTAMP NULL
updated_at TIMESTAMP NULL

Indices:

Name Columns Type Description
PRIMARY id PRIMARY
users_tasks_id_index id INDEX
users_tasks_user_id_foreign user_id INDEX
users_tasks_task_id_foreign task_id INDEX