notice.schema.json 789 字节
Newer Older
study夏羽's avatar
study夏羽 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
// 文档教程: https://uniapp.dcloud.net.cn/uniCloud/schema
{
	"bsonType": "object",
	"required": [],
	"permission": {
		"read": "action in 'add_view_count'",
		"create": false,
		"update": false,
		"delete": false
	},
	"properties": {
		"_id": {
			"description": "ID,系统自动生成",
			"foreignKey": "comment.notice_id"
		},
		"data":{
			"bsonType":"string",
			"description":"公告内容",
			"label":"公告内容",
			"maxLength":32,
			"errorMessage":{
				"maxLength": "{label}不能大于{maxLength}个字符"
			}
		},
		"view_count": {
			"bsonType": "int",
			"title": "阅读数量",
			"description": "阅读数量",
			"permission": {
				"write": false
			}
		},
		"update_time":{
			"bsonType":"timestamp",
			"forceDefaultValue":{
				"$env":"now"
			}
		}
	}
}