package models import "time" type AuditEvent struct { ID uint64 `gorm:"primaryKey;autoIncrement"` CreatedAt time.Time `gorm:"not null;index:idx_audit_events_created_at;index:idx_audit_events_actor,priority:3;index:idx_audit_events_category,priority:2"` Action string `gorm:"not null;size:64"` Category string `gorm:"not null;size:16;index:idx_audit_events_category,priority:1"` ActorType string `gorm:"not null;size:16;index:idx_audit_events_actor,priority:1"` ActorID *uint32 `gorm:"index:idx_audit_events_actor,priority:2"` ActorName string `gorm:"not null;size:255"` TargetType string `gorm:"not null;size:32"` TargetID string `gorm:"not null;size:64"` TargetName string `gorm:"not null;size:255"` Outcome string `gorm:"not null;size:16"` FailureReason *string `gorm:"size:255"` Security bool `gorm:"not null"` Source string `gorm:"not null;size:16"` IP *string `gorm:"size:64"` UserAgent *string `gorm:"size:255"` Params string `gorm:"not null;type:text"` Changes string `gorm:"not null;type:text"` }