|
|
@@ -15,7 +15,8 @@ func init() {
|
|
15
|
15
|
String("store_group_id", 32).Comment("所属店铺组ID").End().
|
|
16
|
16
|
String("region_code", 32).Comment("区域编码").End().
|
|
17
|
17
|
String("creator", 32).NotNull().Comment("创建人").End().
|
|
18
|
|
- DateTime("created_at").NotNull().Default("CURRENT_TIMESTAMP").Comment("创建时间").End()
|
|
|
18
|
+ DateTime("created_at").NotNull().Default("CURRENT_TIMESTAMP").Comment("创建时间").End().
|
|
|
19
|
+ DateTime("updated_at").NotNull().Default("CURRENT_TIMESTAMP").Comment("最后修改时间").End()
|
|
19
|
20
|
r.RegisterTable(tb.Build())
|
|
20
|
21
|
})
|
|
21
|
22
|
}
|
|
|
@@ -28,6 +29,7 @@ type DimStore struct {
|
|
28
|
29
|
RegionCode string `gorm:"column:region_code;type:varchar(32);comment:区域编码"`
|
|
29
|
30
|
Creator string `gorm:"column:creator;type:varchar(32);not null;comment:创建人"`
|
|
30
|
31
|
CreatedAt time.Time `gorm:"column:created_at;not null;default:CURRENT_TIMESTAMP;comment:创建时间"`
|
|
|
32
|
+ UpdatedAt time.Time `gorm:"column:updated_at;not null;default:CURRENT_TIMESTAMP;comment:最后修改时间"`
|
|
31
|
33
|
TenantId string `gorm:"column:tenant_id;type:varchar(8);comment:租户ID"`
|
|
32
|
34
|
}
|
|
33
|
35
|
|