feat: complete project workspace tags and notes UI

This commit is contained in:
2026-07-21 00:46:09 +08:00
parent 54958382f1
commit c613d4c997
28 changed files with 1621 additions and 284 deletions

View File

@@ -41,6 +41,9 @@ func (m *SenlinAgentTask) BeforeCreate(tx *gorm.DB) error {
if err := resolveOptionalIdentity(tx, &SenlinAgentUser{}, m.AssigneeID, &m.AssigneeIdentity); err != nil {
return err
}
if err := resolveOptionalIdentity(tx, &SenlinAgentTag{}, m.TagID, &m.TagIdentity); err != nil {
return err
}
return resolveOptionalIdentity(tx, &SenlinAgentInboxItem{}, m.SourceInboxItemID, &m.SourceInboxItemIdentity)
}

View File

@@ -8,6 +8,9 @@ type SenlinAgentProject struct {
OwnerID uint `gorm:"index;not null"`
OwnerIdentity string `gorm:"type:char(36);index"`
Name string `gorm:"not null"`
Identifier string `gorm:"index"`
Icon string
Background string
Description string
CreatedAt time.Time
UpdatedAt time.Time

View File

@@ -11,6 +11,8 @@ type SenlinAgentTask struct {
CreatedByIdentity string `gorm:"type:char(36);index"`
AssigneeID *uint `gorm:"index"`
AssigneeIdentity *string `gorm:"type:char(36);index"`
TagID *uint `gorm:"index"`
TagIdentity *string `gorm:"type:char(36);index"`
SourceInboxItemID *uint `gorm:"index"`
SourceInboxItemIdentity *string `gorm:"type:char(36);index"`
Title string `gorm:"not null"`