feat(B批收尾): B1门禁可信/B7-1菜单环防护/B2空值守卫/B7-2分页/B7-3字段清洗/B3空态/B4索引key/B5-3 comment三集合选A新建schema(漂移清零)/B6清理+admin配置+changelog
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
[
|
||||
{
|
||||
"IndexName": "create_date",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "create_date",
|
||||
"Direction": "-1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -1,35 +1,89 @@
|
||||
{
|
||||
"bsonType": "object",
|
||||
"required": ["src"],
|
||||
"permission": {
|
||||
"read": true,
|
||||
"create": "auth.uid != null",
|
||||
"update": false,
|
||||
"delete": false
|
||||
},
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
|
||||
"src": {
|
||||
"bsonType": "string",
|
||||
"description": "资源地址(支持云存储 ID 或外部链接)",
|
||||
"format": "url",
|
||||
"pattern": "^(cloud://|http://|https://)",
|
||||
"trim": true,
|
||||
"maxLength": 512,
|
||||
"errorMessage": {
|
||||
"format": "URL 格式无效,示例:cloud://example.jpg 或 https://example.com/image.jpg",
|
||||
"pattern": "仅支持云存储路径(cloud://)或 HTTP/HTTPS 链接"
|
||||
}
|
||||
},
|
||||
"name": {
|
||||
"bsonType": "string",
|
||||
"description": "模板名",
|
||||
"trim": true,
|
||||
"minLength": 1,
|
||||
"maxLength": 64
|
||||
}
|
||||
}
|
||||
}
|
||||
{
|
||||
"bsonType": "object",
|
||||
"required": [
|
||||
"font_color",
|
||||
"backgrond_color",
|
||||
"select_src",
|
||||
"temptele_src",
|
||||
"temptele_name",
|
||||
"select_icon_color",
|
||||
"icon_color",
|
||||
"user_name_color",
|
||||
"btn_color"
|
||||
],
|
||||
"permission": {
|
||||
"read": true,
|
||||
"create": "'admin' in auth.role",
|
||||
"update": "'admin' in auth.role",
|
||||
"delete": "'admin' in auth.role"
|
||||
},
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"font_color": {
|
||||
"bsonType": "string",
|
||||
"description": "文字颜色代码",
|
||||
"trim": true,
|
||||
"pattern": "^#[0-9a-fA-F]{3,8}$"
|
||||
},
|
||||
"background_color": {
|
||||
"bsonType": "string",
|
||||
"description": "背景颜色代码(新字段)",
|
||||
"trim": true,
|
||||
"pattern": "^#[0-9a-fA-F]{3,8}$"
|
||||
},
|
||||
"backgrond_color": {
|
||||
"bsonType": "string",
|
||||
"description": "背景颜色代码(兼容旧拼写)",
|
||||
"trim": true,
|
||||
"pattern": "^#[0-9a-fA-F]{3,8}$"
|
||||
},
|
||||
"select_src": {
|
||||
"bsonType": "string",
|
||||
"description": "素材选择地址",
|
||||
"trim": true,
|
||||
"minLength": 1,
|
||||
"maxLength": 512
|
||||
},
|
||||
"temptele_src": {
|
||||
"bsonType": "string",
|
||||
"description": "模板素材地址",
|
||||
"trim": true,
|
||||
"minLength": 1,
|
||||
"maxLength": 512
|
||||
},
|
||||
"temptele_name": {
|
||||
"bsonType": "string",
|
||||
"description": "模板名称",
|
||||
"trim": true,
|
||||
"minLength": 2,
|
||||
"maxLength": 50
|
||||
},
|
||||
"select_icon_color": {
|
||||
"bsonType": "string",
|
||||
"description": "图标选中颜色代码",
|
||||
"trim": true,
|
||||
"pattern": "^#[0-9a-fA-F]{3,8}$"
|
||||
},
|
||||
"icon_color": {
|
||||
"bsonType": "string",
|
||||
"description": "图标未选中颜色代码",
|
||||
"trim": true,
|
||||
"pattern": "^#[0-9a-fA-F]{3,8}$"
|
||||
},
|
||||
"user_name_color": {
|
||||
"bsonType": "string",
|
||||
"description": "默认用户名字颜色代码",
|
||||
"trim": true,
|
||||
"pattern": "^#[0-9a-fA-F]{3,8}$"
|
||||
},
|
||||
"btn_color": {
|
||||
"bsonType": "string",
|
||||
"description": "按钮默认颜色代码",
|
||||
"trim": true,
|
||||
"pattern": "^#[0-9a-fA-F]{3,8}$"
|
||||
}
|
||||
},
|
||||
"version": "0.0.1"
|
||||
}
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
[
|
||||
{
|
||||
"IndexName": "article_id",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "article_id",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"IndexName": "create_time",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "create_time",
|
||||
"Direction": "-1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,55 @@
|
||||
{
|
||||
"bsonType": "object",
|
||||
"permission": {
|
||||
"create": true,
|
||||
"delete": false,
|
||||
"read": false,
|
||||
"update": false
|
||||
},
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"content": {
|
||||
"bsonType": "string",
|
||||
"description": "评论内容"
|
||||
},
|
||||
"root_id": {
|
||||
"bsonType": "string",
|
||||
"description": "根评论ID(盖楼模型)"
|
||||
},
|
||||
"author_id": {
|
||||
"bsonType": "string",
|
||||
"description": "作者ID,参考uni-id-users表"
|
||||
},
|
||||
"parent_id": {
|
||||
"bsonType": "string",
|
||||
"description": "父评论ID"
|
||||
},
|
||||
"article_id": {
|
||||
"bsonType": "string",
|
||||
"description": "文章ID"
|
||||
},
|
||||
"like_count": {
|
||||
"bsonType": "int",
|
||||
"description": "点赞数"
|
||||
},
|
||||
"create_time": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "创建时间"
|
||||
},
|
||||
"update_time": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "更新时间"
|
||||
},
|
||||
"reply_count": {
|
||||
"bsonType": "int",
|
||||
"description": "回复数"
|
||||
},
|
||||
"ip_location": {
|
||||
"bsonType": "string",
|
||||
"description": "IP归属地"
|
||||
}
|
||||
},
|
||||
"required": ["content"]
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
[
|
||||
{
|
||||
"IndexName": "comment_id",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "comment_id",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"IndexName": "user_id",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "user_id",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,27 @@
|
||||
{
|
||||
"bsonType": "object",
|
||||
"permission": {
|
||||
"create": true,
|
||||
"delete": false,
|
||||
"read": false,
|
||||
"update": false
|
||||
},
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"user_id": {
|
||||
"bsonType": "string",
|
||||
"description": "用户ID,参考uni-id-users表"
|
||||
},
|
||||
"comment_id": {
|
||||
"bsonType": "string",
|
||||
"description": "评论ID"
|
||||
},
|
||||
"create_time": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "创建时间"
|
||||
}
|
||||
},
|
||||
"required": ["user_id", "comment_id"]
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
[
|
||||
{
|
||||
"IndexName": "create_time",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "create_time",
|
||||
"Direction": "-1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,43 @@
|
||||
{
|
||||
"bsonType": "object",
|
||||
"permission": {
|
||||
"create": true,
|
||||
"delete": false,
|
||||
"read": false,
|
||||
"update": false
|
||||
},
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"parent_id": {
|
||||
"bsonType": "string",
|
||||
"description": "父级ID"
|
||||
},
|
||||
"user_id": {
|
||||
"bsonType": "string",
|
||||
"description": "用户ID,参考uni-id-users表"
|
||||
},
|
||||
"content": {
|
||||
"bsonType": "string",
|
||||
"description": "操作内容"
|
||||
},
|
||||
"like_count": {
|
||||
"bsonType": "int",
|
||||
"description": "点赞数"
|
||||
},
|
||||
"create_time": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "创建时间"
|
||||
},
|
||||
"update_time": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "更新时间"
|
||||
},
|
||||
"status": {
|
||||
"bsonType": "int",
|
||||
"description": "状态"
|
||||
}
|
||||
},
|
||||
"required": ["content"]
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
[
|
||||
{
|
||||
"IndexName": "content",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "content",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"IndexName": "create_date",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "create_date",
|
||||
"Direction": "-1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,38 @@
|
||||
[
|
||||
{
|
||||
"IndexName": "create_date",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "create_date",
|
||||
"Direction": "-1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"IndexName": "device_id",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "device_id",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"IndexName": "user_id",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "user_id",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,38 @@
|
||||
[
|
||||
{
|
||||
"IndexName": "task_id",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "task_id",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"IndexName": "status",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "status",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"IndexName": "mobile",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "mobile",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -1,63 +1,63 @@
|
||||
{
|
||||
"bsonType": "object",
|
||||
"required": [],
|
||||
"permission": {
|
||||
"read": false,
|
||||
"create": false,
|
||||
"update": false,
|
||||
"delete": false
|
||||
},
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"task_id": {
|
||||
"bsonType": "string",
|
||||
"description": "任务ID",
|
||||
"foreignKey": "batch-sms-task._id"
|
||||
},
|
||||
"uid": {
|
||||
"bsonType": "string",
|
||||
"description": "用户ID",
|
||||
"foreignKey": "uni-id-users._id"
|
||||
},
|
||||
"mobile": {
|
||||
"bsonType": "int",
|
||||
"description": "手机号"
|
||||
},
|
||||
"var_data": {
|
||||
"bsonType": "object",
|
||||
"description": "变量数据"
|
||||
},
|
||||
"status": {
|
||||
"bsonType": "int",
|
||||
"description": "发送状态",
|
||||
"defaultValue": 0,
|
||||
"enum": [{
|
||||
"text": "未发送",
|
||||
"value": 0
|
||||
}, {
|
||||
"text": "已发送",
|
||||
"value": 1
|
||||
}, {
|
||||
"text": "发送失败",
|
||||
"value": 2
|
||||
}]
|
||||
},
|
||||
"reason": {
|
||||
"bsonType": "string",
|
||||
"description": "发送失败原因"
|
||||
},
|
||||
"send_date": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "发送时间"
|
||||
},
|
||||
"ccreate_date": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "创建时间",
|
||||
"forceDefaultValue": {
|
||||
"$env": "now"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
{
|
||||
"bsonType": "object",
|
||||
"required": [],
|
||||
"permission": {
|
||||
"read": false,
|
||||
"create": false,
|
||||
"update": false,
|
||||
"delete": false
|
||||
},
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"task_id": {
|
||||
"bsonType": "string",
|
||||
"description": "任务ID",
|
||||
"foreignKey": "opendb-sms-task._id"
|
||||
},
|
||||
"uid": {
|
||||
"bsonType": "string",
|
||||
"description": "用户ID",
|
||||
"foreignKey": "uni-id-users._id"
|
||||
},
|
||||
"mobile": {
|
||||
"bsonType": "string",
|
||||
"description": "手机号"
|
||||
},
|
||||
"var_data": {
|
||||
"bsonType": "object",
|
||||
"description": "变量数据"
|
||||
},
|
||||
"status": {
|
||||
"bsonType": "int",
|
||||
"description": "发送状态",
|
||||
"defaultValue": 0,
|
||||
"enum": [{
|
||||
"text": "未发送",
|
||||
"value": 0
|
||||
}, {
|
||||
"text": "已发送",
|
||||
"value": 1
|
||||
}, {
|
||||
"text": "发送失败",
|
||||
"value": 2
|
||||
}]
|
||||
},
|
||||
"reason": {
|
||||
"bsonType": "string",
|
||||
"description": "发送失败原因"
|
||||
},
|
||||
"send_date": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "发送时间"
|
||||
},
|
||||
"create_date": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "创建时间",
|
||||
"forceDefaultValue": {
|
||||
"$env": "now"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
[
|
||||
{
|
||||
"IndexName": "create_date",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "create_date",
|
||||
"Direction": "-1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
}
|
||||
]
|
||||
Reference in New Issue
Block a user