优化结构

This commit is contained in:
Yvan
2026-08-20 20:46:18 +08:00
parent 01b5c2f78a
commit 23bc29ce0f
67 changed files with 1594 additions and 465 deletions
+22
View File
@@ -0,0 +1,22 @@
package data
import (
"time"
"gorm.io/gorm"
)
// dataAccessLogPO is the infrastructure-side write model used by GORM
// callbacks. The system module owns the query repository for the same table.
type dataAccessLogPO struct {
ID uint `gorm:"primaryKey"`
CreatedAt time.Time
UpdatedAt time.Time
DeletedAt gorm.DeletedAt `gorm:"index"`
EventType, TargetTable, Operation string
UserID, AuthorityID uint
Scope int
RequestID, Method, Path, Detail string
}
func (dataAccessLogPO) TableName() string { return "sys_data_access_logs" }