First merge from develop to main (WIP) #7

Merged
sugar merged 199 commits from develop into main 2026-01-27 17:47:07 +00:00
Showing only changes of commit 5f7f078f02 - Show all commits

View File

@@ -15,6 +15,7 @@ type Event struct {
EventId uuid.UUID `json:"event_id" gorm:"type:uuid;uniqueIndex;not null"` EventId uuid.UUID `json:"event_id" gorm:"type:uuid;uniqueIndex;not null"`
Name string `json:"name" gorm:"type:varchar(255);index;not null"` Name string `json:"name" gorm:"type:varchar(255);index;not null"`
Type string `json:"type" gotm:"type:varchar(255);index;not null"` Type string `json:"type" gotm:"type:varchar(255);index;not null"`
Description string `json:"description" gorm:"type:text;not null"`
StartTime time.Time `json:"start_time" gorm:"index"` StartTime time.Time `json:"start_time" gorm:"index"`
EndTime time.Time `json:"end_time" gorm:"index"` EndTime time.Time `json:"end_time" gorm:"index"`
Owner uuid.UUID `json:"owner" gorm:"type:uuid;index;not null"` Owner uuid.UUID `json:"owner" gorm:"type:uuid;index;not null"`
@@ -23,6 +24,8 @@ type Event struct {
type EventSearchDoc struct { type EventSearchDoc struct {
EventId string `json:"event_id"` EventId string `json:"event_id"`
Name string `json:"name"` Name string `json:"name"`
Type string `json:"type"`
Description string `json:"description"`
StartTime time.Time `json:"start_time"` StartTime time.Time `json:"start_time"`
EndTime time.Time `json:"end_time"` EndTime time.Time `json:"end_time"`
} }
@@ -127,6 +130,8 @@ func (self *Event) UpdateSearchIndex() error {
doc := EventSearchDoc{ doc := EventSearchDoc{
EventId: self.EventId.String(), EventId: self.EventId.String(),
Name: self.Name, Name: self.Name,
Type: self.Type,
Description: self.Description,
StartTime: self.StartTime, StartTime: self.StartTime,
EndTime: self.EndTime, EndTime: self.EndTime,
} }