refactor🎨: 修改数据迁移脚本
This commit is contained in:
1 parent
897b9e6919
commit
352224b994
3 files changed
+22
-3829
No files matched your search
@@ -0,0 +1,13 @@
|
||||
package models
|
||||
|
||||
type SysChinaAreaData struct {
|
||||
Model
|
||||
PId string `json:"p_id" gorm:"size:11;comment:上级编码"`
|
||||
Name string `json:"name" gorm:"size:128;comment:名称"`
|
||||
ControlBy
|
||||
ModelTime
|
||||
}
|
||||
|
||||
func (SysChinaAreaData) TableName() string {
|
||||
return "sys_china_area_data"
|
||||
}
|
||||
@@ -39,6 +39,7 @@ func _1599190683659Tables(db *gorm.DB, version string) error {
|
||||
new(models.SysCategory),
|
||||
new(models.SysContent),
|
||||
new(models.SysApi),
|
||||
new(models.SysChinaAreaData),
|
||||
)
|
||||
if err != nil {
|
||||
return err
|
||||
@@ -46,4 +47,4 @@ func _1599190683659Tables(db *gorm.DB, version string) error {
|
||||
return db.Create(&common.Migration{
|
||||
Version: version,
|
||||
}).Error
|
||||
}
|
||||
}
|
||||
+7
-3828
File diff suppressed because it is too large.
Load diff
Reference in new issue
Block a user