opendb-app-versions.schema.json 4.0 KB
Newer Older
1
// 文档教程: https://uniapp.dcloud.net.cn/uniCloud/schema
DCloud_JSON's avatar
DCloud_JSON 已提交
2 3
{
	"bsonType": "object",
4 5 6 7 8 9 10
	"required": [
		"appid",
		"uni_platform",
		"version",
		"type",
		"create_env"
	],
DCloud_JSON's avatar
DCloud_JSON 已提交
11
	"permission": {
12 13 14 15
		"read": "'READ_OPENDB_APP_VERSIONS' in auth.permission",
		"create": "'CREATE_OPENDB_APP_VERSIONS' in auth.permission",
		"update": "'UPDATE_OPENDB_APP_VERSIONS' in auth.permission",
		"delete": "'DELETE_OPENDB_APP_VERSIONS' in auth.permission"
DCloud_JSON's avatar
DCloud_JSON 已提交
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 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65
	},
	"properties": {
		"_id": {
			"description": "记录id,自动生成"
		},
		"appid": {
			"bsonType": "string",
			"trim": "both",
			"description": "应用的AppID",
			"label": "AppID",
			"componentForEdit": {
				"name": "uni-easyinput",
				"props": {
					"disabled": true
				}
			}
		},
		"name": {
			"bsonType": "string",
			"trim": "both",
			"description": "应用名称",
			"label": "应用名称",
			"componentForEdit": {
				"name": "uni-easyinput",
				"props": {
					"disabled": true
				}
			}
		},
		"title": {
			"bsonType": "string",
			"description": "更新标题",
			"label": "更新标题"
		},
		"contents": {
			"bsonType": "string",
			"description": "更新内容",
			"label": "更新内容",
			"componentForEdit": {
				"name": "textarea"
			},
			"componentForShow": {
				"name": "textarea",
				"props": {
					"disabled": true
				}
			}
		},
		"platform": {
			"bsonType": "array",
66 67 68 69 70 71 72 73 74 75
			"enum": [
				{
					"value": "Android",
					"text": "安卓"
				},
				{
					"value": "iOS",
					"text": "苹果"
				}
			],
DCloud_JSON's avatar
DCloud_JSON 已提交
76 77 78 79 80
			"description": "更新平台,Android || iOS || [Android, iOS]",
			"label": "平台"
		},
		"type": {
			"bsonType": "string",
81 82 83 84 85 86 87 88 89 90
			"enum": [
				{
					"value": "native_app",
					"text": "原生App安装包"
				},
				{
					"value": "wgt",
					"text": "Wgt资源包"
				}
			],
DCloud_JSON's avatar
DCloud_JSON 已提交
91 92 93 94 95 96 97 98 99 100 101 102 103 104 105
			"description": "安装包类型,native_app || wgt",
			"label": "安装包类型"
		},
		"version": {
			"bsonType": "string",
			"description": "当前包版本号,必须大于当前线上发行版本号",
			"label": "版本号"
		},
		"min_uni_version": {
			"bsonType": "string",
			"description": "原生App最低版本",
			"label": "原生App最低版本"
		},
		"url": {
			"bsonType": "string",
106 107
			"description": "可下载或跳转的链接",
			"label": "链接"
DCloud_JSON's avatar
DCloud_JSON 已提交
108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134
		},
		"stable_publish": {
			"bsonType": "bool",
			"description": "是否上线发行",
			"label": "上线发行"
		},
		"is_silently": {
			"bsonType": "bool",
			"description": "是否静默更新",
			"label": "静默更新",
			"defaultValue": false
		},
		"is_mandatory": {
			"bsonType": "bool",
			"description": "是否强制更新",
			"label": "强制更新",
			"defaultValue": false
		},
		"create_date": {
			"bsonType": "timestamp",
			"label": "上传时间",
			"forceDefaultValue": {
				"$env": "now"
			},
			"componentForEdit": {
				"name": "uni-dateformat"
			}
135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174
		},
		"uni_platform": {
			"bsonType": "string",
			"description": "uni平台信息,如:mp-weixin/web/ios/android",
			"label": "uni 平台"
		},
		"create_env": {
			"bsonType": "string",
			"description": "创建来源,uni-stat:uni统计自动创建,upgrade-center:升级中心管理员创建"
		},
		"store_list": {
			"bsonType": "array",
			"description": "发布的应用市场",
			"label": "应用市场",
			"properties": {
				"id": {
					"bsonType": "string",
					"description": "应用id,自动生成",
					"label": "id"
				},
				"name": {
					"bsonType": "string",
					"description": "应用名称",
					"label": "应用名称"
				},
				"scheme": {
					"bsonType": "string",
					"description": "应用 scheme",
					"label": "应用 scheme"
				},
				"enable": {
					"bsonType": "bool",
					"description": "是否启用"
				},
				"priority": {
					"bsonType": "int",
					"description": "按照从大到小排序",
					"label": "优先级"
				}
			}
DCloud_JSON's avatar
DCloud_JSON 已提交
175
		}
176 177 178
	},
	"version": "0.0.1"
}