This commit is contained in:
2025-09-30 22:42:07 +08:00
parent 95c2c2e0c1
commit 981e523440

View File

@@ -184,7 +184,7 @@ type UserActionLog struct {
Time time.Time `gorm:"primaryKey" json:"time"`
// --- Who (谁) ---
UserID uint `gorm:"primaryKey" json:"user_id,omitempty"`
UserID uint `gorm:"not null" json:"user_id,omitempty"`
Username string `json:"username,omitempty"` // 操作发生时用户名的快照
// --- Where (何地) ---