fix(models): sub_distributors created_at/updated_at 去掉带引号的 CURRENT_TIMESTAMP default
default: "CURRENT_TIMESTAMP" 让 json2ddl 生成 DEFAULT 'CURRENT_TIMESTAMP'(带引号), MySQL 报 Invalid default value for created_at,导致建表中断(11张表未建)。
This commit is contained in:
parent
2bc6288fae
commit
ebff8d7f08
@ -18,26 +18,26 @@
|
|||||||
"nullable": "no"
|
"nullable": "no"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "resellerid",
|
"name": "resellerid",
|
||||||
"title": "所属主分销商机构ID",
|
"title": "所属主分销商机构ID",
|
||||||
"type": "str",
|
"type": "str",
|
||||||
"length": 32,
|
"length": 32,
|
||||||
"nullable": "no"
|
"nullable": "no"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "sub_distributorid",
|
"name": "sub_distributorid",
|
||||||
"title": "二级分销商机构ID",
|
"title": "二级分销商机构ID",
|
||||||
"type": "str",
|
"type": "str",
|
||||||
"length": 32,
|
"length": 32,
|
||||||
"nullable": "no",
|
"nullable": "no",
|
||||||
"default": ""
|
"default": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "sub_dist_name",
|
"name": "sub_dist_name",
|
||||||
"title": "二级分销商名称",
|
"title": "二级分销商名称",
|
||||||
"type": "str",
|
"type": "str",
|
||||||
"length": 255,
|
"length": 255,
|
||||||
"nullable": "no"
|
"nullable": "no"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "contact_person",
|
"name": "contact_person",
|
||||||
@ -111,14 +111,12 @@
|
|||||||
"name": "created_at",
|
"name": "created_at",
|
||||||
"title": "创建时间",
|
"title": "创建时间",
|
||||||
"type": "datetime",
|
"type": "datetime",
|
||||||
"nullable": "no",
|
"nullable": "no"
|
||||||
"default": "CURRENT_TIMESTAMP"
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "updated_at",
|
"name": "updated_at",
|
||||||
"title": "更新时间",
|
"title": "更新时间",
|
||||||
"type": "datetime",
|
"type": "datetime"
|
||||||
"default": "CURRENT_TIMESTAMP"
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"indexes": [
|
"indexes": [
|
||||||
@ -166,4 +164,4 @@
|
|||||||
"cond": "parentid='sub_distributor_status'"
|
"cond": "parentid='sub_distributor_status'"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user