| | 1 | == Релациско мапирање |
| | 2 | === Ознаки |
| | 3 | |
| | 4 | * Примарните клучеви се означени со __**задебелени и подвлечени букви**__ |
| | 5 | * Задолжителните атрибути се означени со **задебелени букви** |
| | 6 | * Надворешните клучеви се означени со # проследено од името на референцираната табела, обвиени со (). - ''attb#(tabela)'' |
| | 7 | * Наследување се означува со наследениот примарен клуч обвиен со "*" **''само при првото појавување на табелата, потоа се референцира нормално примарниот клуч од основната класа.''** |
| | 8 | |
| | 9 | табелата што ја референцираат. |
| | 10 | |
| | 11 | === Табели |
| | 12 | |
| | 13 | 1. **users** (__**id**__,**username**, is_activate, password, description, registered_at, sex) |
| | 14 | |
| | 15 | 2. **moderator** (__***id#(users)***__) |
| | 16 | |
| | 17 | 3. **developer** (__***id#(users)***__) |
| | 18 | |
| | 19 | 4. **project_manager** (__***id#(users)***__) |
| | 20 | |
| | 21 | 5. **thread** (__**id**__, content, __**user_id#(users)**__) |
| | 22 | |
| | 23 | 6. **likes** (__**user_id#(users)**__, __**thread_id#(thread)**__) |
| | 24 | |
| | 25 | 7. **topic_threads_moderators** (__**thread_id#(thread)**__, __***user_id#(users)***__) |
| | 26 | |
| | 27 | 8. **tag** (__**name**__) |
| | 28 | |
| | 29 | 9. **tag_threads** (__**thread_id#(thread)**__, __**tag_name#(tag)**__) |
| | 30 | |
| | 31 | 10. **topic_thread** (__***id#(thread)***__, **title**, guidelines, next_discussion_id, parent_topic_id#(thread)) |
| | 32 | |
| | 33 | 11. **topic_belongs_to_project** (__**topic_id#(thread)**__, __**project_id#(thread)**__) |
| | 34 | |
| | 35 | 12. **topic_blacklist** (__**topic_id#(thread)**__, __**user_id#(users)**__, __**moderator_id#(users)**__, __**start_date**__, end_date) |
| | 36 | |
| | 37 | 13. **project_thread** (__***id#(thread)***__, **title**, repo_url) |
| | 38 | |
| | 39 | 14. **discussion_thread** (__***id#(thread)***__, **user_id#(users)**, reply_discussion_id#(thread), topic_id#(thread)) |
| | 40 | |
| | 41 | 15. **developer_associated_with_project** (__**project_id#(thread)**__, __**developer_id#(users)**__, __**started_at**__, ended_at) |
| | 42 | |
| | 43 | 16. **permissions** (__**name**__) |
| | 44 | |
| | 45 | 17. **project_roles** (__**name**__, __**project_id#(thread)**__, description) |
| | 46 | |
| | 47 | 18. **users_project_roles** (__**user_id#(users)**__, __**project_id#(thread)**__, __**role_name#(project_roles)**__) |
| | 48 | |
| | 49 | 19. **project_roles_permissions** (__**permission_name#(permissions)**__, __**role_name#(project_roles)**__, __**project_id#(thread)**__) |
| | 50 | |
| | 51 | 20. **project_request** (__**id**__, description, **status**, **user_id#(users)**, **project_id#(thread)**) |
| | 52 | |
| | 53 | 21. **report** (__**id**__, created_at, description, status, **thread_id#(thread)**, **for_user_id#(users)**, **by_user_id#(users)**) |
| | 54 | |
| | 55 | 22. **channel** (__**name**__, description, logo_url, __***project_id#(thread)***__, **developer#(users)**) |
| | 56 | |
| | 57 | 23. **messages** (__**sent_at**__, content, __***sent_by#(users)***__, __***project_id#(thread)***__, __***channel_name#(channel)***__) |