Schema - RawBData/Checkoff GitHub Wiki
Database Schema
users
| column name | data type | details | 
|---|---|---|
| id | integer | not null, primary key | 
| username | string | not null, indexed, unique | 
| email | string | not null, indexed, unique | 
| Facebook | string | |
| Gmail | string | |
| password_digest | string | not null | 
| session_token | string | not null, indexed, unique | 
| created_at | datetime | not null | 
| updated_at | datetime | not null | 
lists
| column name | data type | details | 
|---|---|---|
| id | integer | not null, primary key | 
| user_id | integer | not null, indexed | 
| title | string | not null, indexed | 
| created_at | datetime | not null | 
| updated_at | datetime | not null | 
- user_idreferences- users id
tasks
| column name | data type | details | 
|---|---|---|
| id | integer | not null, primary key | 
| title | string | not null, indexed | 
| notes | text | |
| start_date | date | |
| due_date | date | |
| author_id | integer | not null, primary key | 
| performer_id | integer | |
| list_id | integer | |
| parent_id | integer | |
| complete | boolean | not null, default: false | 
| created_at | datetime | not null | 
| updated_at | datetime | not null | 
- author_idreferences- users id
list_tasks
| column name | data type | details | 
|---|---|---|
| id | integer | not null, primary key | 
| task_id | integer | not null, indexed | 
| list_id | integer | not null, indexed | 
| created_at | datetime | not null | 
| updated_at | datetime | not null | 
- task_idreferences- tasks id
- list_idreferences- lists id
tags
| column name | data type | details | 
|---|---|---|
| id | integer | not null, primary key | 
| title | string | not null, indexed | 
| created_at | datetime | not null | 
| updated_at | datetime | not null | 
taggings
| column name | data type | details | 
|---|---|---|
| id | integer | not null, primary key | 
| task_id | integer | not null, indexed | 
| tag_id | integer | not null, indexed | 
| created_at | datetime | not null | 
| updated_at | datetime | not null | 
- task_idreferences 'tasks id'
- tag_idreferences 'tag id'