opendb/collection/opendb-admin-menus/collection.json

95 lines
1.9 KiB
JSON
Raw Normal View History

2020-10-23 11:25:15 +08:00
{
"schema": {
"bsonType": "object",
"required": [
"name",
2020-10-26 14:43:20 +08:00
"menu_id"
2020-10-23 11:25:15 +08:00
],
"properties": {
"_id": {
"description": "存储文档 ID系统自动生成"
},
"menu_id": {
2020-10-29 17:21:33 +08:00
"bsonType": "string",
2020-12-23 20:20:34 +08:00
"description": "菜单项的ID不可重复",
"trim":"both"
},
2020-10-23 11:25:15 +08:00
"name": {
"bsonType": "string",
2020-12-23 20:20:34 +08:00
"description": "菜单名称",
"trim":"both"
2020-10-23 11:25:15 +08:00
},
"icon": {
"bsonType": "string",
2020-12-23 20:20:34 +08:00
"description": "菜单图标",
"trim":"both"
2020-10-23 11:25:15 +08:00
},
"url": {
"bsonType": "string",
2020-12-23 20:20:34 +08:00
"description": "菜单url",
"trim":"both"
2020-10-23 11:25:15 +08:00
},
"sort": {
"bsonType": "int",
2020-10-23 11:27:03 +08:00
"description": "菜单序号(越大越靠后)"
2020-10-23 11:25:15 +08:00
},
"parent_id": {
"bsonType": "string",
"description": "父级菜单Id"
},
"permission": {
"bsonType": "array",
"description": "菜单权限列表"
},
"enable": {
"bsonType": "bool",
"description": "是否启用菜单true启用、false禁用"
2020-10-23 11:25:15 +08:00
},
"create_date": {
"bsonType": "timestamp",
"description": "菜单创建时间",
"forceDefaultValue": {
"$env": "now"
}
2020-10-23 11:25:15 +08:00
}
}
},
"index": [
{
2020-10-26 14:34:20 +08:00
"IndexName": "menu_id",
2020-10-23 11:25:15 +08:00
"MgoKeySchema": {
"MgoIndexKeys": [
{
2020-10-26 14:34:20 +08:00
"Name": "menu_id",
"Direction": "1"
}
],
"MgoIsUnique": true
}
},
{
"IndexName": "parent_id",
"MgoKeySchema": {
"MgoIndexKeys": [
{
"Name": "parent_id",
2020-10-23 11:25:15 +08:00
"Direction": "1"
}
],
"MgoIsUnique": false
}
},
{
2020-10-26 14:34:20 +08:00
"IndexName": "permission",
"MgoKeySchema": {
"MgoIndexKeys": [
{
2020-10-26 14:34:20 +08:00
"Name": "permission",
"Direction": "1"
}
],
2020-10-26 14:34:20 +08:00
"MgoIsUnique": false
}
2020-10-23 11:25:15 +08:00
}
]
}