mirror of
https://github.com/go-admin-team/go-admin.git
synced 2026-09-21 18:20:50 +00:00
format🥚 :调整主键key和自增长tag
This commit is contained in:
@@ -12,9 +12,9 @@ import (
|
||||
type RoleMenu struct {
|
||||
RoleId int `gorm:""`
|
||||
MenuId int `gorm:""`
|
||||
RoleName string `gorm:"size:128)"`
|
||||
CreateBy string `gorm:"size:128)"`
|
||||
UpdateBy string `gorm:"size:128)"`
|
||||
RoleName string `gorm:"size:128"`
|
||||
CreateBy string `gorm:"size:128"`
|
||||
UpdateBy string `gorm:"size:128"`
|
||||
}
|
||||
|
||||
func (RoleMenu) TableName() string {
|
||||
|
||||
@@ -3,7 +3,7 @@ package system
|
||||
import "go-admin/common/models"
|
||||
|
||||
type SysPost struct {
|
||||
PostId int `gorm:"primary_key;AUTO_INCREMENT" json:"postId"` //岗位编号
|
||||
PostId int `gorm:"primaryKey;autoIncrement" json:"postId"` //岗位编号
|
||||
PostName string `gorm:"size:128;" json:"postName"` //岗位名称
|
||||
PostCode string `gorm:"size:128;" json:"postCode"` //岗位代码
|
||||
Sort int `gorm:"" json:"sort"` //岗位排序
|
||||
|
||||
@@ -3,7 +3,7 @@ package system
|
||||
import "go-admin/common/models"
|
||||
|
||||
type SysRole struct {
|
||||
RoleId int `json:"roleId" gorm:"primary_key;AUTO_INCREMENT"` // 角色编码
|
||||
RoleId int `json:"roleId" gorm:"primaryKey;autoIncrement"` // 角色编码
|
||||
RoleName string `json:"roleName" gorm:"size:128;"` // 角色名称
|
||||
Status string `json:"status" gorm:"size:4;"` //
|
||||
RoleKey string `json:"roleKey" gorm:"size:128;"` //角色代码
|
||||
|
||||
Reference in New Issue
Block a user