重构项目结构,将 orm 和 rds 包迁移到 web/globals
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
package models
|
||||
|
||||
import (
|
||||
"platform/pkg/orm"
|
||||
"platform/web/globals/orm"
|
||||
|
||||
"gorm.io/gorm"
|
||||
)
|
||||
@@ -14,8 +14,8 @@ const TableNamePermission = "permission"
|
||||
|
||||
// Permission mapped from table <permission>
|
||||
type Permission struct {
|
||||
ID int32 `gorm:"column:id;primaryKey;autoIncrement:true;comment:权限ID" json:"id"` // 权限ID
|
||||
ParentID int32 `gorm:"column:parent_id;comment:父权限ID" json:"parent_id"` // 父权限ID
|
||||
ID int32 `gorm:"column:id;primaryKey;autoIncrement:true;comment:权限ID" json:"id"` // 权限ID
|
||||
ParentID int32 `gorm:"column:parent_id;comment:父权限ID" json:"parent_id"` // 父权限ID
|
||||
Name string `gorm:"column:name;not null;comment:权限名称" json:"name"` // 权限名称
|
||||
Description string `gorm:"column:description;comment:权限描述" json:"description"` // 权限描述
|
||||
CreatedAt orm.LocalDateTime `gorm:"column:created_at;default:CURRENT_TIMESTAMP;comment:创建时间" json:"created_at"` // 创建时间
|
||||
|
||||
Reference in New Issue
Block a user