From 91c1e050fa9fe1aa86433e22aff01e23ec46c1ce Mon Sep 17 00:00:00 2001 From: teo <78679830+woosung1223@users.noreply.github.com> Date: Sun, 22 Sep 2024 16:59:13 +0900 Subject: [PATCH] =?UTF-8?q?:memo:=20docs:=20ERD=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: teo <78679830+woosung1223@users.noreply.github.com> --- docs/toyou-erd.md | 69 ++++++++++++++++++++++++++++------------------- 1 file changed, 41 insertions(+), 28 deletions(-) diff --git a/docs/toyou-erd.md b/docs/toyou-erd.md index 911be1c..0584b71 100644 --- a/docs/toyou-erd.md +++ b/docs/toyou-erd.md @@ -2,45 +2,58 @@ ```mermaid erDiagram - USER ||--o{ MEMBER: belongs_to - USER { - bigint id - string name - string profile_picture + User { + Long id + String name + LocalDate birthday + String introduction + String profilePicture + SocialAuthProvider provider } - GROUP ||--o{ ROLLING_PAPER: within - GROUP { - bigint id - string name + Sticker { + Long id + String imageUrl + Integer x + Integer y + Double rotate + Double scale + StickerSide side } - GROUP ||--o{ MEMBER: has - MEMBER { - bigint user_id FK - bigint group_id FK + RollingPaper { + Long id + String title + String content + String coverImageUrl + Long themeId } - MEMBER ||--|{ ROLLING_PAPER: creates - ROLLING_PAPER { - bigint id - string title - bigint member_id FK - bigint group_id FK + Member { + Long id } - ROLLING_PAPER ||--o{ COMMENT: has - MEMBER ||--o{ COMMENT: written_by - COMMENT { - bigint rolling_paper_id FK - bigint member_id FK - string message + Group { + Long id + String name } - BaseTimeEntity { - timestamp created_at - timestamp updated_at + Event { + Long id + String name + LocalDate date + EventType eventType + String description } + + User ||--o{ Member : has + Member ||--o{ Group : belongs_to + RollingPaper ||--o{ Sticker : has + RollingPaper ||--o| Member : belongs_to + Member ||--o| Group : belongs_to + Sticker ||--o| RollingPaper : belongs_to + Event ||--o| User : associated_with + ``` ### Details