From db0f857f0ad4c146e20a1260c3b7859e07a20a56 Mon Sep 17 00:00:00 2001 From: theorose49 Date: Sun, 28 Jun 2026 11:23:38 +0900 Subject: [PATCH] =?UTF-8?q?feat(project):=20=EA=B3=84=EC=95=BD=EB=B2=94?= =?UTF-8?q?=EC=9C=84=EB=A5=BC=20=EA=B8=80/=EA=B7=B8=EB=A6=BC=20=EC=9E=90?= =?UTF-8?q?=EC=9C=A0=20=ED=85=8D=EC=8A=A4=ED=8A=B8=202=EC=B9=B8=EC=9C=BC?= =?UTF-8?q?=EB=A1=9C=20=EB=B3=80=EA=B2=BD=20(=EB=93=9C=EB=A1=AD=EB=8B=A4?= =?UTF-8?q?=EC=9A=B4=20=EC=A0=9C=EA=B1=B0)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 4.8 (1M context) --- internal/models/project.go | 11 +++-------- internal/seed/seed.go | 4 +++- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/internal/models/project.go b/internal/models/project.go index 75f7a97..e13b00c 100644 --- a/internal/models/project.go +++ b/internal/models/project.go @@ -38,13 +38,6 @@ type Version struct { func (m *Version) BeforeCreate(*gorm.DB) error { m.ensureID(); return nil } -// Consulting metadata enums (stored as free strings for flexibility). -const ( - ScopeText = "text" // 글 - ScopeGraphic = "graphic" // 그림 - ScopeBoth = "both" // 글+그림 -) - // Project is the core engagement record. The bracketed [admin-only] fields in the // spec live on Contract / PaymentSplit, not here, so Project is safe to expose to // any member who belongs to it. @@ -59,7 +52,9 @@ type Project struct { VersionName string `json:"versionName"` ConsultingType string `json:"consultingType"` // 컨설팅 종류 Country string `json:"country"` // 제출 국가 - Scope string `json:"scope"` // text | graphic | both + // 계약 범위: 글/그림 각각 자유 입력(무엇을 포함하는지 텍스트로 기술). + ScopeText string `json:"scopeText"` // 글 계약 범위 + ScopeGraphic string `json:"scopeGraphic"` // 그림 계약 범위 PMEmail string `json:"pmEmail"` // 프로젝트 PM Cautions string `json:"cautions"` // 주의사항 (구성원 공개) Status string `json:"status"` // planned | active | hold | done | dropped diff --git a/internal/seed/seed.go b/internal/seed/seed.go index 28ce013..86ecec0 100644 --- a/internal/seed/seed.go +++ b/internal/seed/seed.go @@ -81,7 +81,9 @@ func Run(db *gorm.DB) error { proj := models.Project{Name: "CardioScan FDA 510(k)", CompanyID: comp.ID, ProductID: prod.ID, VersionID: ver.ID, CompanyName: comp.Name, ProductName: prod.Name, VersionName: ver.Label, - ConsultingType: "510(k) 인허가", Country: "미국(FDA)", Scope: models.ScopeBoth, + ConsultingType: "510(k) 인허가", Country: "미국(FDA)", + ScopeText: "기술문서(STED)·라벨링·사용적합성 보고서 작성 및 검토", + ScopeGraphic: "기기 도면·UI 목업·포장 그래픽 제작", PMEmail: "park@special-partners.com", Cautions: "임상 데이터 보완 필요", Status: "active", StartDate: time.Now().Format("2006-01-02"), DueDate: time.Now().AddDate(0, 4, 0).Format("2006-01-02")} db.Create(&proj)