mirror of
https://gitee.com/dcloud/opendb.git
synced 2024-12-27 15:01:15 +08:00
Merge branch 'master' of https://gitee.com/phoooob/opendb
This commit is contained in:
commit
a18b1a3c4f
20
collection/opendb-news-favorite/collection.json
Normal file
20
collection/opendb-news-favorite/collection.json
Normal file
@ -0,0 +1,20 @@
|
||||
{
|
||||
"schema": {
|
||||
"bsonType": "object",
|
||||
"required": ["user_id", "article_id"],
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"article_id": {
|
||||
"bsonType": "string",
|
||||
"description": "文章id,参考opendb-news-categories表"
|
||||
},
|
||||
"user_id": {
|
||||
"bsonType": "string",
|
||||
"description": "收藏者id,参考uni-id-users表"
|
||||
}
|
||||
}
|
||||
},
|
||||
"index": []
|
||||
}
|
17
collection/opendb-news-favorite/package.json
Normal file
17
collection/opendb-news-favorite/package.json
Normal file
@ -0,0 +1,17 @@
|
||||
{
|
||||
"name": "@opendb/opendb-news-favorite",
|
||||
"version": "0.0.1",
|
||||
"description": "opendb-news-favorite",
|
||||
"keywords": ["收藏文章", "favorite"],
|
||||
"opendb": {
|
||||
"title": "收藏文章",
|
||||
"type": "collection",
|
||||
"contributors": [
|
||||
{
|
||||
"name": "DCloud",
|
||||
"email": "",
|
||||
"homepage": "https://gitee.com/dcloud/opendb"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
24
collection/opendb-search-hot/collection.json
Normal file
24
collection/opendb-search-hot/collection.json
Normal file
@ -0,0 +1,24 @@
|
||||
{
|
||||
"schema": {
|
||||
"bsonType": "object",
|
||||
"required": ["content", "count"],
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"content": {
|
||||
"bsonType": "string",
|
||||
"description": "搜索内容"
|
||||
},
|
||||
"count": {
|
||||
"bsonType": "long",
|
||||
"description": "搜索次数"
|
||||
},
|
||||
"create_date": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "统计时间"
|
||||
}
|
||||
}
|
||||
},
|
||||
"index": []
|
||||
}
|
17
collection/opendb-search-hot/package.json
Normal file
17
collection/opendb-search-hot/package.json
Normal file
@ -0,0 +1,17 @@
|
||||
{
|
||||
"name": "@opendb/opendb-search-hot",
|
||||
"version": "0.0.1",
|
||||
"description": "opendb-search-hot",
|
||||
"keywords": ["热搜"],
|
||||
"opendb": {
|
||||
"title": "热搜",
|
||||
"type": "collection",
|
||||
"contributors": [
|
||||
{
|
||||
"name": "DCloud",
|
||||
"email": "",
|
||||
"homepage": "https://gitee.com/dcloud/opendb"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
28
collection/opendb-search-log/collection.json
Normal file
28
collection/opendb-search-log/collection.json
Normal file
@ -0,0 +1,28 @@
|
||||
{
|
||||
"schema": {
|
||||
"bsonType": "object",
|
||||
"required": ["user_id", "content"],
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"user_id": {
|
||||
"bsonType": "string",
|
||||
"description": "收藏者id,参考uni-id-users表"
|
||||
},
|
||||
"device_id": {
|
||||
"bsonType": "string",
|
||||
"description": "设备id"
|
||||
},
|
||||
"content": {
|
||||
"bsonType": "string",
|
||||
"description": "搜索内容"
|
||||
},
|
||||
"create_date": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "统计时间"
|
||||
}
|
||||
}
|
||||
},
|
||||
"index": []
|
||||
}
|
17
collection/opendb-search-log/package.json
Normal file
17
collection/opendb-search-log/package.json
Normal file
@ -0,0 +1,17 @@
|
||||
{
|
||||
"name": "@opendb/opendb-search-log",
|
||||
"version": "0.0.1",
|
||||
"description": "opendb-search-log",
|
||||
"keywords": ["搜索记录"],
|
||||
"opendb": {
|
||||
"title": "搜索记录",
|
||||
"type": "collection",
|
||||
"contributors": [
|
||||
{
|
||||
"name": "DCloud",
|
||||
"email": "",
|
||||
"homepage": "https://gitee.com/dcloud/opendb"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
24
collection/uni-id-followers/collection.json
Normal file
24
collection/uni-id-followers/collection.json
Normal file
@ -0,0 +1,24 @@
|
||||
{
|
||||
"schema": {
|
||||
"bsonType": "object",
|
||||
"required": ["friend_uid", "follow_uid"],
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"friend_uid": {
|
||||
"bsonType": "string",
|
||||
"description": "被关注者user_id,参考uni-id-users表"
|
||||
},
|
||||
"follow_uid": {
|
||||
"bsonType": "string",
|
||||
"description": "关注者user_id,参考uni-id-users表"
|
||||
},
|
||||
"create_date": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "创建时间"
|
||||
}
|
||||
}
|
||||
},
|
||||
"index": []
|
||||
}
|
17
collection/uni-id-followers/package.json
Normal file
17
collection/uni-id-followers/package.json
Normal file
@ -0,0 +1,17 @@
|
||||
{
|
||||
"name": "@opendb/uni-id-followers",
|
||||
"version": "0.0.1",
|
||||
"description": "uni-id-followers",
|
||||
"keywords": ["关注用户", "followers"],
|
||||
"opendb": {
|
||||
"title": "关注用户",
|
||||
"type": "collection",
|
||||
"contributors": [
|
||||
{
|
||||
"name": "DCloud",
|
||||
"email": "",
|
||||
"homepage": "https://gitee.com/dcloud/opendb"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
37
collection/uni-id-scores/collection.json
Normal file
37
collection/uni-id-scores/collection.json
Normal file
@ -0,0 +1,37 @@
|
||||
{
|
||||
"schema": {
|
||||
"bsonType": "object",
|
||||
"required": ["user_id", "score", "balance"],
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"user_id": {
|
||||
"bsonType": "string",
|
||||
"description": "用户id,参考uni-id-users表"
|
||||
},
|
||||
"score": {
|
||||
"bsonType": "int",
|
||||
"description": "本次变化的积分"
|
||||
},
|
||||
"type": {
|
||||
"bsonType": "int",
|
||||
"enum": [1, 2],
|
||||
"description": "积分类型 1:收入 2:指出"
|
||||
},
|
||||
"balance": {
|
||||
"bsonType": "int",
|
||||
"description": "变化后的积分余额"
|
||||
},
|
||||
"comment": {
|
||||
"bsonType": "string",
|
||||
"description": "备注,说明积分新增、消费的缘由"
|
||||
},
|
||||
"create_date": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "创建时间"
|
||||
}
|
||||
}
|
||||
},
|
||||
"index": []
|
||||
}
|
17
collection/uni-id-scores/package.json
Normal file
17
collection/uni-id-scores/package.json
Normal file
@ -0,0 +1,17 @@
|
||||
{
|
||||
"name": "@opendb/uni-id-scores",
|
||||
"version": "0.0.1",
|
||||
"description": "uni-id-scores",
|
||||
"keywords": ["积分", "用户积分", "scores"],
|
||||
"opendb": {
|
||||
"title": "用户积分",
|
||||
"type": "collection",
|
||||
"contributors": [
|
||||
{
|
||||
"name": "DCloud",
|
||||
"email": "",
|
||||
"homepage": "https://gitee.com/dcloud/opendb"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
32
collection/uni-id-task-log/collection.json
Normal file
32
collection/uni-id-task-log/collection.json
Normal file
@ -0,0 +1,32 @@
|
||||
{
|
||||
"schema": {
|
||||
"bsonType": "object",
|
||||
"required": ["user_id", "task_id"],
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"user_id": {
|
||||
"bsonType": "string",
|
||||
"description": "用户id,参考uni-id-users表"
|
||||
},
|
||||
"task_id": {
|
||||
"bsonType": "string",
|
||||
"description": "任务ID"
|
||||
},
|
||||
"result": {
|
||||
"bsonType": "bool",
|
||||
"description": "任务执行结果,true:成功,false:失败"
|
||||
},
|
||||
"bounty": {
|
||||
"bsonType": "int",
|
||||
"description": "奖励积分"
|
||||
},
|
||||
"create_date": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "创建时间"
|
||||
}
|
||||
}
|
||||
},
|
||||
"index": []
|
||||
}
|
17
collection/uni-id-task-log/package.json
Normal file
17
collection/uni-id-task-log/package.json
Normal file
@ -0,0 +1,17 @@
|
||||
{
|
||||
"name": "@opendb/uni-id-task-log",
|
||||
"version": "0.0.1",
|
||||
"description": "uni-id-task-log",
|
||||
"keywords": ["任务日志", "task-log"],
|
||||
"opendb": {
|
||||
"title": "任务日志",
|
||||
"type": "collection",
|
||||
"contributors": [
|
||||
{
|
||||
"name": "DCloud",
|
||||
"email": "",
|
||||
"homepage": "https://gitee.com/dcloud/opendb"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
40
collection/uni-id-task/collection.json
Normal file
40
collection/uni-id-task/collection.json
Normal file
@ -0,0 +1,40 @@
|
||||
{
|
||||
"schema": {
|
||||
"bsonType": "object",
|
||||
"required": ["name", "comment"],
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
},
|
||||
"name": {
|
||||
"bsonType": "string",
|
||||
"description": "任务名称"
|
||||
},
|
||||
"comment": {
|
||||
"bsonType": "string",
|
||||
"description": "任务描述"
|
||||
},
|
||||
"bounty": {
|
||||
"bsonType": "int",
|
||||
"description": "任务完成后的奖励积分"
|
||||
},
|
||||
"max_per_hour": {
|
||||
"bsonType": "int",
|
||||
"description": "每小时允许执行的最大次数"
|
||||
},
|
||||
"max_per_day": {
|
||||
"bsonType": "int",
|
||||
"description": "每天允许执行的最大次数"
|
||||
},
|
||||
"max_per_week": {
|
||||
"bsonType": "int",
|
||||
"description": "每周允许执行的最大次数"
|
||||
},
|
||||
"create_date": {
|
||||
"bsonType": "timestamp",
|
||||
"description": "创建时间"
|
||||
}
|
||||
}
|
||||
},
|
||||
"index": []
|
||||
}
|
17
collection/uni-id-task/package.json
Normal file
17
collection/uni-id-task/package.json
Normal file
@ -0,0 +1,17 @@
|
||||
{
|
||||
"name": "@opendb/uni-id-task",
|
||||
"version": "0.0.1",
|
||||
"description": "uni-id-task",
|
||||
"keywords": ["任务", "task"],
|
||||
"opendb": {
|
||||
"title": "用户任务",
|
||||
"type": "collection",
|
||||
"contributors": [
|
||||
{
|
||||
"name": "DCloud",
|
||||
"email": "",
|
||||
"homepage": "https://gitee.com/dcloud/opendb"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
@ -1,5 +1,6 @@
|
||||
{
|
||||
"opendb-news-articles": {},
|
||||
"opendb-news-categories": {},
|
||||
"opendb-news-comments": {}
|
||||
"opendb-news-comments": {},
|
||||
"opendb-news-favorite": {}
|
||||
}
|
||||
|
@ -3,5 +3,9 @@
|
||||
"uni-id-address": {},
|
||||
"uni-id-device": {},
|
||||
"uni-id-log": {},
|
||||
"uni-id-base-order":{}
|
||||
"uni-id-base-order":{},
|
||||
"uni-id-scores": {},
|
||||
"uni-id-task": {},
|
||||
"uni-id-task-log": {},
|
||||
"uni-id-followers": {}
|
||||
}
|
||||
|
41
uni-id-score.md
Normal file
41
uni-id-score.md
Normal file
@ -0,0 +1,41 @@
|
||||
|
||||
## 用户积分表
|
||||
|
||||
表名:uni-id-scores
|
||||
|
||||
| 字段 | 类型 | 必填 | 描述 |
|
||||
| ---------------- | --------- | ---- | ------------------------------------------- |
|
||||
| \_id | Object ID | 是 | 存储文档 ID,系统自动生成 |
|
||||
| user_id | String | 是 | |
|
||||
| score | Integer | 是 | 本次变化的积分 |
|
||||
| type | Integer | 否 | 积分类型 1:收入 2:指出 |
|
||||
| balance | Integer | 是 | 变化后的积分余额 |
|
||||
| comment | String | 否 | 备注,说明积分新增、消费的缘由 |
|
||||
| create_date | Timestamp | 否 | 创建时间 |
|
||||
|
||||
|
||||
## 用户任务表
|
||||
|
||||
表名:uni-id-task
|
||||
|
||||
| 字段 | 类型 | 必填 | 描述 |
|
||||
| ---------------- | --------- | ---- | ------------------------------------------- |
|
||||
| \_id | Object ID | 是 | 存储文档 ID,系统自动生成 |
|
||||
| name | String | 是 | 任务名称 |
|
||||
| comment | String | 是 | 任务描述 |
|
||||
| bounty | Integer | 否 | 任务完成后的奖励积分 |
|
||||
| max_per_hour | Integer | 否 | 每小时允许执行的最大次数 |
|
||||
| max_per_day | Integer | 否 | 每天允许执行的最大次数 |
|
||||
| max_per_week | Integer | 否 | 每周允许执行的最大次数 |
|
||||
| create_date | Timestamp | 否 | 创建时间 |
|
||||
|
||||
表名:uni-id-task-log
|
||||
|
||||
| 字段 | 类型 | 必填 | 描述 |
|
||||
| ---------------- | --------- | ---- | ------------------------------------------- |
|
||||
| \_id | Object ID | 是 | 存储文档 ID,系统自动生成 |
|
||||
| user_id | String | 是 | 用户ID |
|
||||
| task_id | String | 是 | 任务ID |
|
||||
| result | Boolean | 否 | 任务执行结果,true:成功,false:失败 |
|
||||
| bounty | Integer | 否 | 奖励积分 |
|
||||
| create_date | Timestamp | 否 | 创建时间 |
|
Loading…
Reference in New Issue
Block a user