[feat] 移除 ResFieldByMap, ResFieldByAnys 类型

This commit is contained in:
2023-06-23 00:10:24 +08:00
parent 88ed380018
commit 6ccef0fbb8
25 changed files with 416 additions and 459 deletions
+14 -18
View File
@@ -1,24 +1,20 @@
package base
import (
"git.fsdpf.net/go/contracts/res_type"
)
type GridLayout struct {
Uuid string `db:"uuid"`
ResourceUuid string `db:"resource_uuid"` // 所属资源UUID
Code string `db:"code"` // 布局标识
Name string `db:"name"` // 布局名称
PrimaryKey string `db:"primaryKey"` // 主键
MarginX int `db:"marginX"` // 栅格 x 间距
MarginY int `db:"marginY"` // 栅格 y 间距
Cols int `db:"cols"` // 网格列基数
RowHeight int `db:"rowHeight"` // 栅格行高
Css res_type.ResFieldByMap `db:"css"` // 布局CSS
Props res_type.ResFieldByAnys `db:"props"` // 布局PROPS
Roles res_type.ResFieldByAnys `db:"roles"`
UpdatedAt string `db:"updated_at"`
CreatedAt string `db:"created_at"`
Uuid string `db:"uuid"`
ResourceUuid string `db:"resource_uuid"` // 所属资源UUID
Code string `db:"code"` // 布局标识
Name string `db:"name"` // 布局名称
PrimaryKey string `db:"primaryKey"` // 主键
MarginX int `db:"marginX"` // 栅格 x 间距
MarginY int `db:"marginY"` // 栅格 y 间距
Cols int `db:"cols"` // 网格列基数
RowHeight int `db:"rowHeight"` // 栅格行高
Css map[string]any `db:"css"` // 布局CSS
Props []any `db:"props"` // 布局PROPS
Roles []string `db:"roles"`
UpdatedAt string `db:"updated_at"`
CreatedAt string `db:"created_at"`
}
type GetGridLayout func(code string) (GridLayout, bool)