mirror of
https://github.com/go-admin-team/go-admin.git
synced 2026-09-21 10:13:01 +00:00
tpl:update tpl
This commit is contained in:
@@ -9,7 +9,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
type SysDept struct {
|
type SysDept struct {
|
||||||
DeptId int `json:"deptId" gorm:"primary_key;AUTO_INCREMENT"` //部门编码
|
DeptId int `json:"deptId" gorm:"primary_key;auto_increment;"` //部门编码
|
||||||
ParentId int `json:"parentId" gorm:""` //上级部门
|
ParentId int `json:"parentId" gorm:""` //上级部门
|
||||||
DeptPath string `json:"deptPath" gorm:"size:255;"` //
|
DeptPath string `json:"deptPath" gorm:"size:255;"` //
|
||||||
DeptName string `json:"deptName" gorm:"size:128;"` //部门名称
|
DeptName string `json:"deptName" gorm:"size:128;"` //部门名称
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
type DictData struct {
|
type DictData struct {
|
||||||
DictCode int `gorm:"primary_key;AUTO_INCREMENT" json:"dictCode" example:"1"` //字典编码
|
DictCode int `gorm:"primary_key;auto_increment;" json:"dictCode" example:"1"` //字典编码
|
||||||
DictSort int `gorm:"" json:"dictSort"` //显示顺序
|
DictSort int `gorm:"" json:"dictSort"` //显示顺序
|
||||||
DictLabel string `gorm:"size:128;" json:"dictLabel"` //数据标签
|
DictLabel string `gorm:"size:128;" json:"dictLabel"` //数据标签
|
||||||
DictValue string `gorm:"size:255;" json:"dictValue"` //数据键值
|
DictValue string `gorm:"size:255;" json:"dictValue"` //数据键值
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
type DictType struct {
|
type DictType struct {
|
||||||
DictId int `gorm:"primary_key;AUTO_INCREMENT" json:"dictId"`
|
DictId int `gorm:"primary_key;auto_increment;" json:"dictId"`
|
||||||
DictName string `gorm:"size:128;" json:"dictName"` //字典名称
|
DictName string `gorm:"size:128;" json:"dictName"` //字典名称
|
||||||
DictType string `gorm:"size:128;" json:"dictType"` //字典类型
|
DictType string `gorm:"size:128;" json:"dictType"` //字典类型
|
||||||
Status string `gorm:"size:4;" json:"status"` //状态
|
Status string `gorm:"size:4;" json:"status"` //状态
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import (
|
|||||||
|
|
||||||
type SysFileDir struct {
|
type SysFileDir struct {
|
||||||
gorm.Model
|
gorm.Model
|
||||||
Id int `json:"id" gorm:"type:int(11);primary_key;AUTO_INCREMENT"` //
|
Id int `json:"id" gorm:"type:int(11);primary_key;auto_increment;"` //
|
||||||
Label string `json:"label" gorm:"type:varchar(255);"` // 名称
|
Label string `json:"label" gorm:"type:varchar(255);"` // 名称
|
||||||
PId int `json:"pId" gorm:"type:int(11);"` // 父id
|
PId int `json:"pId" gorm:"type:int(11);"` // 父id
|
||||||
Sort int `json:"sort" gorm:""` //排序
|
Sort int `json:"sort" gorm:""` //排序
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
type LoginLog struct {
|
type LoginLog struct {
|
||||||
InfoId int `json:"infoId" gorm:"primary_key;AUTO_INCREMENT"` //主键
|
InfoId int `json:"infoId" gorm:"primary_key;auto_increment;"` //主键
|
||||||
Username string `json:"username" gorm:"size:128;"` //用户名
|
Username string `json:"username" gorm:"size:128;"` //用户名
|
||||||
Status string `json:"status" gorm:"size:4;"` //状态
|
Status string `json:"status" gorm:"size:4;"` //状态
|
||||||
Ipaddr string `json:"ipaddr" gorm:"size:255;"` //ip地址
|
Ipaddr string `json:"ipaddr" gorm:"size:255;"` //ip地址
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ type MenuLable struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Menus struct {
|
type Menus struct {
|
||||||
MenuId int `json:"menuId" gorm:"column:menu_id;primary_key"`
|
MenuId int `json:"menuId" gorm:"column:menu_id;primary_key;"`
|
||||||
MenuName string `json:"menuName" gorm:"column:menu_name"`
|
MenuName string `json:"menuName" gorm:"column:menu_name"`
|
||||||
Title string `json:"title" gorm:"column:title"`
|
Title string `json:"title" gorm:"column:title"`
|
||||||
Icon string `json:"icon" gorm:"column:icon"`
|
Icon string `json:"icon" gorm:"column:icon"`
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
type SysFileInfo struct {
|
type SysFileInfo struct {
|
||||||
Id int `json:"id" gorm:"type:int(11);primary_key;AUTO_INCREMENT"` // id
|
Id int `json:"id" gorm:"type:int(11);primary_key;auto_increment;"` // id
|
||||||
Type string `json:"type" gorm:"type:varchar(255);"` // 文件类型
|
Type string `json:"type" gorm:"type:varchar(255);"` // 文件类型
|
||||||
Name string `json:"name" gorm:"type:varchar(255);"` // 文件名称
|
Name string `json:"name" gorm:"type:varchar(255);"` // 文件名称
|
||||||
Size string `json:"size" gorm:"type:int(11);"` // 文件大小
|
Size string `json:"size" gorm:"type:int(11);"` // 文件大小
|
||||||
|
|||||||
@@ -38,6 +38,7 @@ func _1599190683659Tables(db *gorm.DB, version string) error {
|
|||||||
new(models.SysConfig),
|
new(models.SysConfig),
|
||||||
new(models.SysSetting),
|
new(models.SysSetting),
|
||||||
new(models.SysFileDir),
|
new(models.SysFileDir),
|
||||||
|
new(models.SysFileInfo),
|
||||||
new(models.SysCategory),
|
new(models.SysCategory),
|
||||||
new(models.SysContent),
|
new(models.SysContent),
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -378,7 +378,7 @@
|
|||||||
{{- end -}}
|
{{- end -}}
|
||||||
// 文件
|
// 文件
|
||||||
{{range .Columns}}
|
{{range .Columns}}
|
||||||
{{- if ne .HtmlType "file" -}}
|
{{- if eq .HtmlType "file" -}}
|
||||||
fileShow{{.GoField}}: function() {
|
fileShow{{.GoField}}: function() {
|
||||||
this.fileOpen = true
|
this.fileOpen = true
|
||||||
this.fileIndex = '{{.JsonField}}'
|
this.fileIndex = '{{.JsonField}}'
|
||||||
|
|||||||
Reference in New Issue
Block a user