Current database schema:
Current data model:
It's built with Erd in Kroki with the following source:
[User]
*id
name
passwordHash
active
email
createdAt
[Role]
*id
name
User *--+ Role
[Content]
*id
text
+author
createdAt
Content *--1 User
[Vote]
*id
+voter
+content
value
createdAt
Vote *--1 User
Vote *--1 Content
[Question]
*id
+data
title
Question 1--1 Content
[Answer]
*id
+question
+data
Question 1--* Answer
Answer 1--1 Content
[Comment]
*id
+parent
+data
Comment 1--1 Content {label: "data"}
Comment +--1 Content {label: "parent"}
[Tag]
*id
name
Question 1--* Tag