update collection/opendb-mall-comments/collection.json.

This commit is contained in:
崔红保 2020-10-26 19:03:12 +08:00 committed by Gitee
parent 19072336ba
commit d70b5ee06d

View File

@ -1,7 +1,7 @@
{
"schema": {
"bsonType": "object",
"required": ["goods_id", "user_id", "comment_content"],
"required": ["goods_id", "user_id", "content"],
"properties": {
"_id": {
"description": "存储文档 ID文章 ID系统自动生成"
@ -12,22 +12,42 @@
},
"user_id": {
"bsonType": "string",
"description": "商品的唯一货号"
"description": "评论者的uid参考 uni-id-users 表"
},
"comment_content": {
"content": {
"bsonType": "string",
"description": "评论内容"
"description": "评论内容",
"title":"评论内容"
},
"comment_date": {
"create_date": {
"bsonType": "timestamp",
"description": "评论发表时间"
"description": "评论发表时间",
"defaultValue": {
"$env": "now"
}
},
"comment_ip": {
"publish_ip": {
"bsonType": "string",
"description": "评论发表时 IP 地址"
"description": "评论发表时,客户端的 IP 地址",
"forceDefaultValue": {
"$env": "clientIP"
}
}
}
},
"data": [],
"index": []
"index": [
{
"IndexName": "goods_id_",
"MgoKeySchema": {
"MgoIndexKeys": [
{
"Name": "goods_id",
"Direction": "1"
}
],
"MgoIsUnique": false
}
}
]
}