feature:自动化增加前端可控显隐和自定义class。

This commit is contained in:
pixelmaxQM
2024-04-25 21:02:43 +08:00
parent 17d3639443
commit 90549a09e1
4 changed files with 84 additions and 88 deletions

View File

@@ -34,6 +34,7 @@ type AutoCodeStruct struct {
HasRichText bool `json:"-"`
HasFile bool `json:"-"`
NeedJSON bool `json:"-"`
FrontFields []*Field `json:"-"`
}
func (a *AutoCodeStruct) Pretreatment() {
@@ -67,6 +68,8 @@ type Field struct {
ColumnName string `json:"columnName"` // 数据库字段
FieldSearchType string `json:"fieldSearchType"` // 搜索条件
DictType string `json:"dictType"` // 字典
Front bool `json:"front"` // 是否前端可见
Class string `json:"class"` // 前端样式类
Require bool `json:"require"` // 是否必填
DefaultValue string `json:"defaultValue"` // 是否必填
ErrorText string `json:"errorText"` // 校验失败文字