Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
DCloud
hello-uniCloud
提交
3ddef0ae
H
hello-uniCloud
项目概览
DCloud
/
hello-uniCloud
通知
294
Star
3
Fork
2
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
H
hello-uniCloud
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
3ddef0ae
编写于
1月 15, 2024
作者:
A
Anne_LXM
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
1.4.0
上级
fc4ed132
变更
3
显示空白变更内容
内联
并排
Showing
3 changed file
with
3 addition
and
437 deletion
+3
-437
changelog.md
changelog.md
+2
-0
package.json
package.json
+1
-1
uniCloud-aliyun/database/db_init.json
uniCloud-aliyun/database/db_init.json
+0
-436
未找到文件。
changelog.md
浏览文件 @
3ddef0ae
## 1.4.0(2024-01-15)
-
更新 db_init.json 按collection拆分,每个collection由schema.json、index.json、init_data.json三个文件描述
[
详情
](
https://doc.dcloud.net.cn/uniCloud/hellodb.html#init-db-2
)
## 1.3.9(2023-12-29)
-
新增 七牛云扩展存储示例,价格更优、权限更灵活
[
详见
](
https://doc.dcloud.net.cn/uniCloud/ext-storage/intro.html
)
## 1.3.8(2023-10-24)
...
...
package.json
浏览文件 @
3ddef0ae
{
"id"
:
"uni-cloud"
,
"displayName"
:
"hello uniCloud"
,
"version"
:
"1.
3.9
"
,
"version"
:
"1.
4.0
"
,
"description"
:
"为开发者提供的基于 serverless 模式和 js 编程的云开发平台。示例代码"
,
"keywords"
:
[
"uniCloud示例"
...
...
uniCloud-aliyun/database/db_init.json
已删除
100644 → 0
浏览文件 @
fc4ed132
//
在本文件中可配置云数据库初始化,数据格式见:https://uniapp.dcloud.io/uniCloud/cf-database?id=db_init
//
编写完毕后对本文件点右键,可按配置规则创建表和添加数据
{
"opendb-department"
:
{
"data"
:
[{
"_id"
:
"5fe77207974b6900018c6c9c"
,
"name"
:
"总部"
,
"parent_id"
:
""
,
"status"
:
0
},
{
"_id"
:
"5fe77232974b6900018c6cb1"
,
"name"
:
"一级部门A"
,
"parent_id"
:
"5fe77207974b6900018c6c9c"
,
"status"
:
0
}
]
},
"book"
:
{
"data"
:
[{
"_id"
:
"1"
,
"title"
:
"西游记"
,
"author"
:
"吴承恩"
},
{
"_id"
:
"2"
,
"title"
:
"水浒传"
,
"author"
:
"施耐庵"
},
{
"_id"
:
"3"
,
"title"
:
"三国演义"
,
"author"
:
"罗贯中"
},
{
"_id"
:
"4"
,
"title"
:
"红楼梦"
,
"author"
:
"曹雪芹"
}
]
},
"order"
:
{
"data"
:
[{
"book_id"
:
"1"
,
"quantity"
:
111
,
"create_date"
:
5
//演示数据方便比较分析
},
{
"book_id"
:
"2"
,
"quantity"
:
222
,
"create_date"
:
3
},
{
"book_id"
:
"3"
,
"quantity"
:
333
,
"create_date"
:
6
},
{
"book_id"
:
"4"
,
"quantity"
:
444
,
"create_date"
:
9
},
{
"book_id"
:
"3"
,
"quantity"
:
555
,
"create_date"
:
4
}
]
},
"test"
:
{
"data"
:
[]
},
"opendb-app-list"
:
{
"data"
:
[],
"index"
:
[{
"IndexName"
:
"appid"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"appid"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
true
}
},
{
"IndexName"
:
"name"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"name"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
}]
},
"opendb-app-versions"
:
{
"data"
:
[],
"index"
:
[{
"IndexName"
:
"appid"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"appid"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"查找上线发行应用"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"appid"
,
"Direction"
:
"1"
},
{
"Name"
:
"platform"
,
"Direction"
:
"1"
},
{
"Name"
:
"stable_publish"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
}]
},
"permission-test-1"
:
{
"data"
:
[{
"state"
:
0
,
"text"
:
"该用户比较懒啥也没写!"
}]
},
"permission-test-2"
:
{
"data"
:
[{
"state"
:
0
,
"text"
:
"该用户比较懒啥也没写!"
}]
},
"permission-test-3"
:
{
"data"
:
[{
"state"
:
0
,
"text"
:
"该用户比较懒啥也没写!"
}]
},
"permission-test-4"
:
{
"data"
:
[{
"state"
:
0
,
"text"
:
"该用户比较懒啥也没写!"
}]
},
"permission-test-5"
:
{
"data"
:
[{
"state"
:
0
,
"text"
:
"该用户比较懒啥也没写!"
}]
},
"permission-test-6"
:
{
"data"
:
[{
"state"
:
0
,
"text"
:
"该用户比较懒啥也没写!"
}]
},
"permission-test-7"
:
{
"data"
:
[{
"state"
:
0
,
"text"
:
"该用户比较懒啥也没写!"
}]
},
"opendb-notice-comment"
:
{},
"opendb-notice"
:
{
"data"
:
[{
"view_count"
:
0
,
"_id"
:
"65365ac355b3379a66170144"
,
"data"
:
"这是一个由clientDB实现的留言板示例;权限部分由DBschema和action云函数控制。
\n
规则如下:
\n
1.未登陆的游客,只能看到审核通过的留言。
\n
2.登陆的用户还可以:发表留言,会进入审核状态,期间支持查看和删除。审核通过后可以重新编辑留言。但在重新编辑后会自动再次进入审核状态。
\n
3.审核员和管理员可以:查看所有状态的留言,操作:审核、编辑、删除。"
}]
},
"opendb-city-china"
:
{},
"uni-id-users"
:
{
"data"
:
[{
"username"
:
"admin"
,
"nickname"
:
"admin"
,
"password"
:
"03caebb36670995fc261a275d212cad65e4bbebd"
,
"role"
:
[
"admin"
]
},
{
"username"
:
"user"
,
"nickname"
:
"user"
,
"password"
:
"03caebb36670995fc261a275d212cad65e4bbebd"
,
"role"
:
[
"USER"
]
},
{
"username"
:
"auditor"
,
"nickname"
:
"auditor"
,
"password"
:
"03caebb36670995fc261a275d212cad65e4bbebd"
,
"role"
:
[
"AUDITOR"
]
}
],
"index"
:
[{
"IndexName"
:
"username"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"username"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"mobile"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"mobile"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"email"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"email"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"wx_openid.app-plus"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"wx_openid.app-plus"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"wx_openid.mp-weixin"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"wx_openid.mp-weixin"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"wx_unionid"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"wx_unionid"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"ali_openid"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"ali_openid"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"my_invite_code"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"my_invite_code"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"inviter_uid"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"inviter_uid"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"invite_time"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"invite_time"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"role"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"role"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
}]
},
"uni-verify"
:
{
"data"
:
[],
"index"
:
[{
"IndexName"
:
"mobile"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"mobile"
,
"Direction"
:
"1"
},
{
"Name"
:
"code"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
},
{
"IndexName"
:
"email"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"email"
,
"Direction"
:
"1"
},
{
"Name"
:
"code"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
}]
},
"uni-id-roles"
:
{
"data"
:
[{
"role_id"
:
"USER"
,
"role_name"
:
"用户"
,
"permission"
:
[
"P_TEST_ADD"
]
},
{
"role_id"
:
"AUDITOR"
,
"role_name"
:
"审核员"
,
"permission"
:
[
"P_TEST_UPDATE"
]
}
],
"index"
:
[{
"IndexName"
:
"role_id"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"role_id"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
true
}
},
{
"IndexName"
:
"permission"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"permission"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
}
]
},
"uni-id-permissions"
:
{
"data"
:
[{
"permission_id"
:
"P_TEST_ADD"
,
"permission_name"
:
"增加permission-test表数据"
},
{
"permission_id"
:
"P_TEST_UPDATE"
,
"permission_name"
:
"修改permission-test表数据"
}
],
"index"
:
[{
"IndexName"
:
"permission_id"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"permission_id"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
true
}
}]
},
"opendb-admin-menu"
:
{
"data"
:
[],
"index"
:
[{
"IndexName"
:
"parent_id"
,
"MgoKeySchema"
:
{
"MgoIndexKeys"
:
[{
"Name"
:
"parent_id"
,
"Direction"
:
"1"
}],
"MgoIsUnique"
:
false
}
}]
},
"unicloud-test"
:{},
"opendb-verify-codes"
:
{
"data"
:
[]
},
"uni-id-log"
:
{
"data"
:
[]
},
"opendb-admin-menus"
:
{
"data"
:
[{
"menu_id"
:
"system_management"
,
"name"
:
"系统管理"
,
"icon"
:
"uni-icons-gear"
,
"url"
:
""
,
"sort"
:
1000
,
"parent_id"
:
""
,
"permission"
:
[],
"enable"
:
true
,
"create_date"
:
1602662469396
},
{
"menu_id"
:
"system_user"
,
"name"
:
"用户管理"
,
"icon"
:
"uni-icons-person"
,
"url"
:
"/pages/system/user/list"
,
"sort"
:
1010
,
"parent_id"
:
"system_management"
,
"permission"
:
[],
"enable"
:
true
,
"create_date"
:
1602662469398
},
{
"menu_id"
:
"system_role"
,
"name"
:
"角色管理"
,
"icon"
:
"uni-icons-personadd"
,
"url"
:
"/pages/system/role/list"
,
"sort"
:
1020
,
"parent_id"
:
"system_management"
,
"permission"
:
[],
"enable"
:
true
,
"create_date"
:
1602662469397
},
{
"menu_id"
:
"system_permission"
,
"name"
:
"权限管理"
,
"icon"
:
"uni-icons-locked"
,
"url"
:
"/pages/system/permission/list"
,
"sort"
:
1030
,
"parent_id"
:
"system_management"
,
"permission"
:
[],
"enable"
:
true
,
"create_date"
:
1602662469396
},
{
"menu_id"
:
"system_menu"
,
"name"
:
"菜单管理"
,
"icon"
:
"uni-icons-settings"
,
"url"
:
"/pages/system/menu/list"
,
"sort"
:
1040
,
"parent_id"
:
"system_management"
,
"permission"
:
[],
"enable"
:
true
,
"create_date"
:
1602662469396
}]
}
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录