mirror of
https://gitee.com/dcloud/opendb.git
synced 2024-11-10 11:09:44 +08:00
update:
1. opendb-verify-codes 添加device_uuid索引 2. opendb-id-log 去除 user_id 的required,添加 device_uuid 和 user_id索引
This commit is contained in:
parent
421dfcc14f
commit
0188fba9eb
@ -68,5 +68,17 @@
|
||||
}],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
}, {
|
||||
"IndexName": "device_uuid_code_",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [{
|
||||
"Name": "device_uuid",
|
||||
"Direction": "1"
|
||||
}, {
|
||||
"Name": "code",
|
||||
"Direction": "1"
|
||||
}],
|
||||
"MgoIsUnique": false
|
||||
}
|
||||
}]
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"schema": {
|
||||
"bsonType": "object",
|
||||
"required": ["user_id"],
|
||||
"required": [],
|
||||
"properties": {
|
||||
"_id": {
|
||||
"description": "ID,系统自动生成"
|
||||
@ -16,11 +16,14 @@
|
||||
},
|
||||
"device_uuid": {
|
||||
"bsonType": "string",
|
||||
"description": "设备唯一标识(需要加密存储)"
|
||||
"description": "设备唯一标识"
|
||||
},
|
||||
"type": {
|
||||
"bsonType": "string",
|
||||
"enum": ["login", "logout"],
|
||||
"enum": [
|
||||
"login",
|
||||
"logout"
|
||||
],
|
||||
"description": "登录类型"
|
||||
},
|
||||
"state": {
|
||||
@ -40,5 +43,30 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"index": []
|
||||
"index": [
|
||||
{
|
||||
"IndexName": "user_id",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "user_id",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"IndexName": "device_uuid",
|
||||
"MgoKeySchema": {
|
||||
"MgoIndexKeys": [
|
||||
{
|
||||
"Name": "device_uuid",
|
||||
"Direction": "1"
|
||||
}
|
||||
],
|
||||
"MgoIsUnique": true
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
Loading…
Reference in New Issue
Block a user