✨ 新增几大中心功能
This commit is contained in:
25
server/model/system/sys_param_change_log.go
Normal file
25
server/model/system/sys_param_change_log.go
Normal file
@@ -0,0 +1,25 @@
|
||||
package system
|
||||
|
||||
import "time"
|
||||
|
||||
type SysParamChangeAction string
|
||||
|
||||
const (
|
||||
SysParamChangeActionCreate SysParamChangeAction = "create"
|
||||
SysParamChangeActionUpdate SysParamChangeAction = "update"
|
||||
SysParamChangeActionDelete SysParamChangeAction = "delete"
|
||||
)
|
||||
|
||||
// SysParamChangeLog 参数变更审计(策略/开关等都落在 sys_params)
|
||||
type SysParamChangeLog struct {
|
||||
ID uint `json:"id" gorm:"primaryKey"`
|
||||
ParamID uint `json:"paramId" gorm:"index;not null"`
|
||||
Key string `json:"key" gorm:"index;size:191;not null"`
|
||||
Action SysParamChangeAction `json:"action" gorm:"type:varchar(16);index;not null"`
|
||||
OldValue string `json:"oldValue" gorm:"type:text"`
|
||||
NewValue string `json:"newValue" gorm:"type:text"`
|
||||
OperatorUserID uint `json:"operatorUserId" gorm:"index;not null"`
|
||||
CreatedAt time.Time `json:"createdAt" gorm:"index"`
|
||||
}
|
||||
|
||||
func (SysParamChangeLog) TableName() string { return "sys_param_change_logs" }
|
||||
Reference in New Issue
Block a user