122 lines
2.4 KiB
JSON
122 lines
2.4 KiB
JSON
{
|
|
"name": "云服务库",
|
|
"table": {
|
|
"name": "service",
|
|
"comment": "云服务表",
|
|
"engine": "InnoDB"
|
|
},
|
|
"columns": [
|
|
{ "name": "id", "type": "ID" },
|
|
{
|
|
"name": "short_name",
|
|
"type": "string",
|
|
"length": 200,
|
|
"comment": "简称",
|
|
"index": true
|
|
},
|
|
{
|
|
"name": "name",
|
|
"type": "string",
|
|
"length": 200,
|
|
"comment": "服务名称",
|
|
"index": true
|
|
},
|
|
{
|
|
"name": "kind",
|
|
"type": "string",
|
|
"length": 200,
|
|
"comment": "服务类型",
|
|
"index": true
|
|
},
|
|
{
|
|
"name": "manu",
|
|
"type": "string",
|
|
"length": 200,
|
|
"comment": "所属厂商",
|
|
"index": true
|
|
},
|
|
{
|
|
"name": "registed_at",
|
|
"type": "string",
|
|
"length": 200,
|
|
"comment": "注册地",
|
|
"nullable": true,
|
|
"index": true
|
|
},
|
|
{
|
|
"name": "link",
|
|
"type": "string",
|
|
"length": 200,
|
|
"comment": "官网地址",
|
|
"nullable": true
|
|
},
|
|
{
|
|
"name": "contact_name",
|
|
"type": "string",
|
|
"length": 200,
|
|
"comment": "联系人",
|
|
"nullable": true,
|
|
"index": true
|
|
},
|
|
{
|
|
"name": "contact_mobile",
|
|
"type": "string",
|
|
"comment": "联系电话",
|
|
"nullable": true,
|
|
"index": true
|
|
},
|
|
{
|
|
"name": "fields",
|
|
"type": "string",
|
|
"length": 500,
|
|
"comment": "JSON|服务领域(多选)",
|
|
"nullable": true,
|
|
"index": true
|
|
},
|
|
{
|
|
"name": "price_options",
|
|
"type": "string",
|
|
"length": 500,
|
|
"default": "[\"按月订阅\"]",
|
|
"comment": "JSON|订阅方式(多选)",
|
|
"index": true
|
|
},
|
|
{
|
|
"name": "industries",
|
|
"type": "string",
|
|
"length": 500,
|
|
"comment": "JSON|行业覆盖(多选)",
|
|
"nullable": true,
|
|
"index": true
|
|
},
|
|
{
|
|
"name": "rank",
|
|
"type": "integer",
|
|
"default": 9999999,
|
|
"comment": "查询排序"
|
|
},
|
|
{
|
|
"name": "status",
|
|
"type": "enum",
|
|
"default": "enabled",
|
|
"option": ["enabled", "disabled"],
|
|
"comment": "状态 enabled 开启, disabled 关闭",
|
|
"index": true
|
|
}
|
|
],
|
|
"relations": {
|
|
"manu": {
|
|
"type": "hasOne",
|
|
"key": "manu",
|
|
"model": "Manu",
|
|
"foreign": "id"
|
|
},
|
|
"kind": {
|
|
"type": "hasOne",
|
|
"key": "kind",
|
|
"model": "Kind",
|
|
"foreign": "id"
|
|
}
|
|
},
|
|
"option": { "timestamps": true, "soft_deletes": true }
|
|
}
|