Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
水星冲浪手88
uni-starter
提交
78a1788c
U
uni-starter
项目概览
水星冲浪手88
/
uni-starter
与 Fork 源项目一致
Fork自
DCloud / uni-starter
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
uni-starter
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
78a1788c
编写于
7月 27, 2021
作者:
DCloud_JSON
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
1. 支持vue3.0 2. 去掉App.vue全局样式,避免与非flex布局的页面样式冲突
上级
ae8b3826
变更
23
隐藏空白更改
内联
并排
Showing
23 changed file
with
645 addition
and
502 deletion
+645
-502
changelog.md
changelog.md
+3
-0
common/all-flex.css
common/all-flex.css
+0
-15
common/appInit.js
common/appInit.js
+1
-2
components/uni-agreements/uni-agreements.vue
components/uni-agreements/uni-agreements.vue
+8
-2
components/uni-quick-login/uni-quick-login.vue
components/uni-quick-login/uni-quick-login.vue
+24
-18
components/uni-send-sms-code/uni-send-sms-code.vue
components/uni-send-sms-code/uni-send-sms-code.vue
+27
-21
manifest.json
manifest.json
+130
-112
package.json
package.json
+1
-1
pages/list/list.nvue
pages/list/list.nvue
+3
-0
pages/ucenter/about/about.vue
pages/ucenter/about/about.vue
+193
-169
pages/ucenter/login-page/common/login-page.css
pages/ucenter/login-page/common/login-page.css
+61
-54
pages/ucenter/login-page/index/index.vue
pages/ucenter/login-page/index/index.vue
+8
-2
pages/ucenter/login-page/phone-code/phone-code.vue
pages/ucenter/login-page/phone-code/phone-code.vue
+5
-4
pages/ucenter/settings/settings.vue
pages/ucenter/settings/settings.vue
+0
-1
pages/ucenter/ucenter.vue
pages/ucenter/ucenter.vue
+17
-10
pages/ucenter/userinfo/userinfo.vue
pages/ucenter/userinfo/userinfo.vue
+14
-8
uni_modules/uni-config-center/uniCloud/cloudfunctions/common/uni-config-center/uni-id/config.json
...loudfunctions/common/uni-config-center/uni-id/config.json
+52
-0
uni_modules/uni-file-picker/components/uni-file-picker/uni-file-picker.vue
...ile-picker/components/uni-file-picker/uni-file-picker.vue
+84
-72
uni_modules/uni-id-cf/uniCloud/cloudfunctions/uni-id-cf/index.js
...ules/uni-id-cf/uniCloud/cloudfunctions/uni-id-cf/index.js
+5
-5
uni_modules/uni-sign-in/components/uni-sign-in/uni-sign-in.vue
...odules/uni-sign-in/components/uni-sign-in/uni-sign-in.vue
+1
-1
uni_modules_tools/config.js
uni_modules_tools/config.js
+3
-1
uni_modules_tools/copy/manifest.json
uni_modules_tools/copy/manifest.json
+2
-1
uni_modules_tools/copy/uni_modules/uni-config-center/uniCloud/cloudfunctions/common/uni-config-center/uni-id/config.json
...loudfunctions/common/uni-config-center/uni-id/config.json
+3
-3
未找到文件。
changelog.md
浏览文件 @
78a1788c
## 1.0.41(2021-07-27)
1.
支持vue3.0
2.
去掉App.vue全局样式,避免与非flex布局的页面样式冲突
## 1.0.40(2021-07-22)
## 1.0.40(2021-07-22)
1.
调整使用正则表达式配置强制登陆功能的写法,解决在小程序端的兼容问题。
1.
调整使用正则表达式配置强制登陆功能的写法,解决在小程序端的兼容问题。
2.
新增签到功能(培养用户习惯,提升用户粘性)。支持:每日签到奖励、周期性连续7日签到,奖励翻倍。
2.
新增签到功能(培养用户习惯,提升用户粘性)。支持:每日签到奖励、周期性连续7日签到,奖励翻倍。
...
...
common/all-flex.css
已删除
100644 → 0
浏览文件 @
ae8b3826
view
,
scroll-view
,
text
,
image
,
switch
,
navigator
,
icons
{
display
:
flex
!important
;
box-sizing
:
border-box
;
flex-direction
:
column
;
}
scroll-view
{
-webkit-overflow-scrolling
:
touch
;
}
common/appInit.js
浏览文件 @
78a1788c
...
@@ -115,7 +115,7 @@ export default async function() {
...
@@ -115,7 +115,7 @@ export default async function() {
//拦截器封装callFunction
//拦截器封装callFunction
let
callFunctionOption
;
let
callFunctionOption
;
uniCloud
.
addInterceptor
(
'
callFunction
'
,
{
uniCloud
.
addInterceptor
(
'
callFunction
'
,
{
async
invoke
(
option
)
{
async
invoke
(
option
)
{
// #ifdef APP-PLUS
// #ifdef APP-PLUS
// 判断如果是执行登陆(无论是哪种登陆方式),就记录用户的相关设备id
// 判断如果是执行登陆(无论是哪种登陆方式),就记录用户的相关设备id
if
(
option
.
name
==
'
uni-id-cf
'
&&
(
option
.
data
.
action
==
'
register
'
||
option
.
data
.
action
.
slice
(
0
,
5
)
==
'
login
'
))
{
if
(
option
.
name
==
'
uni-id-cf
'
&&
(
option
.
data
.
action
==
'
register
'
||
option
.
data
.
action
.
slice
(
0
,
5
)
==
'
login
'
))
{
...
@@ -303,7 +303,6 @@ export default async function() {
...
@@ -303,7 +303,6 @@ export default async function() {
list
.
forEach
(
item
=>
{
//用遍历的方式分别为,uni.navigateTo,uni.redirectTo,uni.reLaunch,uni.switchTab这4个路由方法添加拦截器
list
.
forEach
(
item
=>
{
//用遍历的方式分别为,uni.navigateTo,uni.redirectTo,uni.reLaunch,uni.switchTab这4个路由方法添加拦截器
uni
.
addInterceptor
(
item
,
{
uni
.
addInterceptor
(
item
,
{
invoke
(
e
)
{
// 调用前拦截
invoke
(
e
)
{
// 调用前拦截
// console.log(e);
//获取用户的token
//获取用户的token
const
token
=
uni
.
getStorageSync
(
'
uni_id_token
'
),
const
token
=
uni
.
getStorageSync
(
'
uni_id_token
'
),
//token是否已失效
//token是否已失效
...
...
components/uni-agreements/uni-agreements.vue
浏览文件 @
78a1788c
...
@@ -44,8 +44,14 @@
...
@@ -44,8 +44,14 @@
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
'@/common/all-flex.css'
;
/* #ifndef APP-NVUE */
view
{
display
:
flex
;
box-sizing
:
border-box
;
flex-direction
:
column
;
}
/* #endif */
.root
{
.root
{
flex-direction
:
row
;
flex-direction
:
row
;
align-items
:
center
;
align-items
:
center
;
...
...
components/uni-quick-login/uni-quick-login.vue
浏览文件 @
78a1788c
...
@@ -105,29 +105,29 @@
...
@@ -105,29 +105,29 @@
let
servicesList
=
this
.
servicesList
let
servicesList
=
this
.
servicesList
//去掉配置中不存在的
//去掉配置中不存在的
servicesList
=
servicesList
.
filter
(
item
=>
this
.
loginConfig
.
includes
(
item
.
id
))
servicesList
=
servicesList
.
filter
(
item
=>
this
.
loginConfig
.
includes
(
item
.
id
))
//处理一键登录
//处理一键登录
if
(
this
.
loginConfig
.
includes
(
'
univerify
'
)){
if
(
this
.
loginConfig
.
includes
(
'
univerify
'
)){
this
.
univerifyStyle
.
privacyTerms
.
privacyItems
=
this
.
agreements
this
.
univerifyStyle
.
privacyTerms
.
privacyItems
=
this
.
agreements
//设置一键登录功能底下的快捷登陆按钮
//设置一键登录功能底下的快捷登陆按钮
servicesList
.
forEach
(({
id
,
logo
})
=>
{
servicesList
.
forEach
(({
id
,
logo
})
=>
{
if
(
id
!=
'
univerify
'
)
{
if
(
id
!=
'
univerify
'
)
{
this
.
univerifyStyle
.
buttons
.
list
.
push
({
this
.
univerifyStyle
.
buttons
.
list
.
push
({
"
iconPath
"
:
logo
,
"
iconPath
"
:
logo
,
"
provider
"
:
id
"
provider
"
:
id
})
})
}
}
})
})
}
}
//如果当前页面为默认登陆界面。当前第一优先级的“微信和苹果登陆”要隐藏,因为他已经被渲染在默认登陆界面顶部
//如果当前页面为默认登陆界面。当前第一优先级的“微信和苹果登陆”要隐藏,因为他已经被渲染在默认登陆界面顶部
if
(
if
(
this
.
getRoute
(
1
)
==
'
/pages/ucenter/login-page/index/index
'
&&
this
.
getRoute
(
1
)
==
'
/pages/ucenter/login-page/index/index
'
&&
[
'
weixin
'
,
'
apple
'
].
includes
(
this
.
loginConfig
[
0
])
[
'
weixin
'
,
'
apple
'
].
includes
(
this
.
loginConfig
[
0
])
)
{
)
{
servicesList
=
servicesList
.
filter
(
item
=>
item
.
id
!=
this
.
loginConfig
[
0
])
servicesList
=
servicesList
.
filter
(
item
=>
item
.
id
!=
this
.
loginConfig
[
0
])
}
}
//去掉当前页面对应的登录选项
//去掉当前页面对应的登录选项
this
.
servicesList
=
servicesList
.
filter
(
item
=>
{
this
.
servicesList
=
servicesList
.
filter
(
item
=>
{
let
path
=
item
.
path
?
item
.
path
.
split
(
'
?
'
)[
0
]:
''
;
let
path
=
item
.
path
?
item
.
path
.
split
(
'
?
'
)[
0
]:
''
;
return
path
!=
this
.
getRoute
(
1
)
return
path
!=
this
.
getRoute
(
1
)
})
})
console
.
log
(
'
servicesList
'
,
servicesList
,
this
.
servicesList
);
console
.
log
(
'
servicesList
'
,
servicesList
,
this
.
servicesList
);
...
@@ -343,7 +343,13 @@
...
@@ -343,7 +343,13 @@
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
'@/common/all-flex.css'
;
/* #ifndef APP-NVUE */
view
{
display
:
flex
;
box-sizing
:
border-box
;
flex-direction
:
column
;
}
/* #endif */
.quick-login-box
{
.quick-login-box
{
flex-direction
:
row
;
flex-direction
:
row
;
width
:
750rpx
;
width
:
750rpx
;
...
@@ -369,4 +375,4 @@
...
@@ -369,4 +375,4 @@
margin-top
:
4px
;
margin-top
:
4px
;
font-size
:
26rpx
;
font-size
:
26rpx
;
}
}
</
style
>
</
style
>
components/uni-send-sms-code/uni-send-sms-code.vue
浏览文件 @
78a1788c
...
@@ -74,33 +74,33 @@
...
@@ -74,33 +74,33 @@
title
:
'
手机号格式错误
'
,
title
:
'
手机号格式错误
'
,
icon
:
'
none
'
icon
:
'
none
'
});
});
uniCloud
.
callFunction
({
uniCloud
.
callFunction
({
name
:
'
uni-id-cf
'
,
name
:
'
uni-id-cf
'
,
data
:{
data
:{
action
:
'
sendSmsCode
'
,
action
:
'
sendSmsCode
'
,
params
:{
params
:{
"
mobile
"
:
this
.
phone
,
"
mobile
"
:
this
.
phone
,
"
type
"
:
this
.
codeType
"
type
"
:
this
.
codeType
},
},
},
},
success
:
({
result
})
=>
{
success
:
({
result
})
=>
{
console
.
log
(
result
);
console
.
log
(
result
);
if
(
result
.
code
===
0
){
if
(
result
.
code
===
0
){
uni
.
showToast
({
uni
.
showToast
({
title
:
"
短信验证码发送成功
"
,
title
:
"
短信验证码发送成功
"
,
icon
:
'
none
'
icon
:
'
none
'
});
});
this
.
reverseNumber
=
Number
(
this
.
count
);
this
.
reverseNumber
=
Number
(
this
.
count
);
this
.
getCode
();
this
.
getCode
();
this
.
$emit
(
'
getCode
'
);
this
.
$emit
(
'
getCode
'
);
}
else
{
}
else
{
uni
.
showModal
({
uni
.
showModal
({
content
:
result
.
msg
,
content
:
result
.
msg
,
showCancel
:
false
showCancel
:
false
});
});
}
}
}
}
})
})
},
},
getCode
()
{
getCode
()
{
if
(
this
.
reverseNumber
==
0
)
{
if
(
this
.
reverseNumber
==
0
)
{
...
@@ -118,7 +118,13 @@
...
@@ -118,7 +118,13 @@
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
'@/common/all-flex.css'
;
/* #ifndef APP-NVUE */
view
{
display
:
flex
;
box-sizing
:
border-box
;
flex-direction
:
column
;
}
/* #endif */
.short-code-btn
{
.short-code-btn
{
width
:
200rpx
;
width
:
200rpx
;
height
:
85rpx
;
height
:
85rpx
;
...
...
manifest.json
浏览文件 @
78a1788c
{
{
"name"
:
"uni-starter"
,
"name"
:
"uni-starter"
,
"appid"
:
"__UNI__03B096E"
,
"appid"
:
"请点击重新获取"
,
"description"
:
"云端一体应用快速开发模版"
,
"description"
:
"云端一体应用快速开发模版"
,
"versionName"
:
"1.0.0"
,
"versionName"
:
"1.0.0"
,
"versionCode"
:
"100"
,
"versionCode"
:
"100"
,
"transformPx"
:
false
,
"transformPx"
:
false
,
"app-plus"
:
{
"app-plus"
:
{
"privacy"
:
{
"privacy"
:
{
"prompt"
:
"template"
,
"prompt"
:
"template"
,
"template"
:
{
"template"
:
{
"title"
:
"服务协议和隐私政策"
,
"title"
:
"服务协议和隐私政策"
,
"message"
:
" 请你务必审慎阅读、充分理解“服务协议”和“隐私政策”各条款,包括但不限于:为了更好的向你提供服务,我们需要收集你的设备标识、操作日志等信息用于分析、优化应用性能。<br/> 你可阅读<a href=
\"
https://ask.dcloud.net.cn/protocol.html
\"
>《服务协议》</a>和<a href=
\"
https://ask.dcloud.net.cn/protocol.html
\"
>《隐私政策》</a>了解详细信息。如果你同意,请点击下面按钮开始接受我们的服务。"
,
"message"
:
" 请你务必审慎阅读、充分理解“服务协议”和“隐私政策”各条款,包括但不限于:为了更好的向你提供服务,我们需要收集你的设备标识、操作日志等信息用于分析、优化应用性能。<br/> 你可阅读<a href=
\"
https://ask.dcloud.net.cn/protocol.html
\"
>《服务协议》</a>和<a href=
\"
https://ask.dcloud.net.cn/protocol.html
\"
>《隐私政策》</a>了解详细信息。如果你同意,请点击下面按钮开始接受我们的服务。"
,
"buttonAccept"
:
"同意"
,
"buttonAccept"
:
"同意"
,
"buttonRefuse"
:
"暂不同意"
"buttonRefuse"
:
"暂不同意"
}
}
},
},
"compatible"
:
{
"compatible"
:
{
"ignoreVersion"
:
true
"ignoreVersion"
:
true
},
"usingComponents"
:
true
,
"nvueStyleCompiler"
:
"uni-app"
,
"compilerVersion"
:
3
,
"splashscreen"
:
{
"alwaysShowBeforeRender"
:
true
,
"waiting"
:
true
,
"autoclose"
:
true
,
"delay"
:
0
},
"modules"
:
{
"Fingerprint"
:
{
},
"Share"
:
{
},
"OAuth"
:
{
},
"FaceID"
:
{
},
"Push"
:
{
}
},
"distribute"
:
{
"android"
:
{
"permissions"
:
[
"<uses-feature android:name=
\"
android.hardware.camera
\"
/>"
,
"<uses-feature android:name=
\"
android.hardware.camera.autofocus
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.ACCESS_NETWORK_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.ACCESS_WIFI_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.CAMERA
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.CHANGE_NETWORK_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.CHANGE_WIFI_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.FLASHLIGHT
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.GET_ACCOUNTS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.MODIFY_AUDIO_SETTINGS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.MOUNT_UNMOUNT_FILESYSTEMS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.READ_LOGS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.READ_PHONE_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.USE_FINGERPRINT
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.VIBRATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.WAKE_LOCK
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.WRITE_SETTINGS
\"
/>"
],
"abiFilters"
:
[
"armeabi-v7a"
,
"arm64-v8a"
,
"x86"
]
},
"ios"
:
{
"capabilities"
:
{
"entitlements"
:
{
"com.apple.developer.associated-domains"
:
[
"applinks:static-76ce2c5e-31c7-4d81-8fcf-ed1541ecbc6e.bspapp.com"
]
}
}
},
"sdkConfigs"
:
{
"oauth"
:
{
"apple"
:
{
},
"weixin"
:
{
"appid"
:
"wxffdd8fa6ec4ef2a0"
,
"appsecret"
:
""
,
"UniversalLinks"
:
"https://static-76ce2c5e-31c7-4d81-8fcf-ed1541ecbc6e.bspapp.com/uni-universallinks/__UNI__03B096E"
},
"univerify"
:
{
}
},
},
"usingComponents"
:
true
,
"ad"
:
{
"nvueStyleCompiler"
:
"uni-app"
,
"compilerVersion"
:
3
,
"splashscreen"
:
{
"alwaysShowBeforeRender"
:
true
,
"waiting"
:
true
,
"autoclose"
:
true
,
"delay"
:
0
},
},
"modules"
:
{
"share"
:
{
"Fingerprint"
:
{},
"weixin"
:
{
"Share"
:
{},
"appid"
:
"wxffdd8fa6ec4ef2a0"
,
"OAuth"
:
{},
"UniversalLinks"
:
"https://static-76ce2c5e-31c7-4d81-8fcf-ed1541ecbc6e.bspapp.com/uni-universallinks/__UNI__03B096E"
"FaceID"
:
{},
}
"Push"
:
{}
},
},
"distribute"
:
{
"geolocation"
:
{
"android"
:
{
"permissions"
:
[
"<uses-feature android:name=
\"
android.hardware.camera
\"
/>"
,
"<uses-feature android:name=
\"
android.hardware.camera.autofocus
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.ACCESS_NETWORK_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.ACCESS_WIFI_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.CAMERA
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.CHANGE_NETWORK_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.CHANGE_WIFI_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.FLASHLIGHT
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.GET_ACCOUNTS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.MODIFY_AUDIO_SETTINGS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.MOUNT_UNMOUNT_FILESYSTEMS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.READ_LOGS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.READ_PHONE_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.USE_FINGERPRINT
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.VIBRATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.WAKE_LOCK
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.WRITE_SETTINGS
\"
/>"
],
"abiFilters"
:
[
"armeabi-v7a"
,
"arm64-v8a"
,
"x86"
]
},
"ios"
:
{
"capabilities"
:
{
"entitlements"
:
{
"com.apple.developer.associated-domains"
:
[
"applinks:static-76ce2c5e-31c7-4d81-8fcf-ed1541ecbc6e.bspapp.com"
]
}
}
},
"sdkConfigs"
:
{
"oauth"
:
{
"apple"
:
{},
"weixin"
:
{
"appid"
:
"wxffdd8fa6ec4ef2a0"
,
"appsecret"
:
""
,
"UniversalLinks"
:
"https://static-76ce2c5e-31c7-4d81-8fcf-ed1541ecbc6e.bspapp.com/uni-universallinks/__UNI__03B096E"
},
"univerify"
:
{}
},
"ad"
:
{},
"share"
:
{
"weixin"
:
{
"appid"
:
"wxffdd8fa6ec4ef2a0"
,
"UniversalLinks"
:
"https://static-76ce2c5e-31c7-4d81-8fcf-ed1541ecbc6e.bspapp.com/uni-universallinks/__UNI__03B096E"
}
},
"geolocation"
:
{},
"push"
:
{
"unipush"
:
{}
},
"payment"
:
{}
}
},
},
"nvueLaunchMode"
:
""
"push"
:
{
},
"unipush"
:
{
"quickapp"
:
{},
}
"mp-weixin"
:
{
"appid"
:
"wx81dbb061d2258234"
,
"setting"
:
{
"urlCheck"
:
false
,
"es6"
:
false
},
},
"usingComponents"
:
true
,
"payment"
:
{
"betterScopedSlots"
:
true
}
},
}
"mp-alipay"
:
{
"usingComponents"
:
true
},
"mp-baidu"
:
{
"usingComponents"
:
true
},
"mp-toutiao"
:
{
"usingComponents"
:
true
},
"uniStatistics"
:
{
"enable"
:
false
},
},
"h5"
:
{
"nvueLaunchMode"
:
""
"template"
:
""
},
"quickapp"
:
{
},
"mp-weixin"
:
{
"appid"
:
""
,
"setting"
:
{
"urlCheck"
:
false
,
"es6"
:
false
},
},
"_spaceID"
:
"76ce2c5e-31c7-4d81-8fcf-ed1541ecbc6e"
,
"usingComponents"
:
true
,
"vueVersion"
:
"2"
"betterScopedSlots"
:
true
}
},
"mp-alipay"
:
{
"usingComponents"
:
true
},
"mp-baidu"
:
{
"usingComponents"
:
true
},
"mp-toutiao"
:
{
"usingComponents"
:
true
},
"uniStatistics"
:
{
"enable"
:
false
},
"h5"
:
{
"template"
:
""
},
"_spaceID"
:
""
,
"vueVersion"
:
"2"
}
\ No newline at end of file
package.json
浏览文件 @
78a1788c
{
{
"id"
:
"uni-starter"
,
"id"
:
"uni-starter"
,
"displayName"
:
"uni-starter"
,
"displayName"
:
"uni-starter"
,
"version"
:
"1.0.4
0
"
,
"version"
:
"1.0.4
1
"
,
"description"
:
"云端一体应用快速开发基本项目模版"
,
"description"
:
"云端一体应用快速开发基本项目模版"
,
"keywords"
:
[
"keywords"
:
[
"login"
,
"login"
,
...
...
pages/list/list.nvue
浏览文件 @
78a1788c
...
@@ -183,6 +183,9 @@
...
@@ -183,6 +183,9 @@
left: 0;
left: 0;
/* #ifndef APP-PLUS */
/* #ifndef APP-PLUS */
z-index: 9;
z-index: 9;
/* #endif */
/* #ifdef MP-WEIXIN */
width: 580rpx;
/* #endif */
/* #endif */
}
}
...
...
pages/ucenter/about/about.vue
浏览文件 @
78a1788c
<
template
>
<
template
>
<view
class=
"about"
>
<view
class=
"about"
>
<view
class=
"box"
>
<view
class=
"box"
>
<image
class=
"logoImg"
:src=
"about.logo"
></image>
<image
class=
"logoImg"
:src=
"about.logo"
></image>
<text
class=
"tip appName"
>
{{
about
.
appName
}}
</text>
<text
class=
"tip appName"
>
{{
about
.
appName
}}
</text>
<text
class=
"tip"
>
Version
{{
version
}}
</text>
<text
class=
"tip"
>
Version
{{
version
}}
</text>
<!--Sansnn-uQRCode组件来源,插件市场:https://ext.dcloud.net.cn/plugin?id=1287 微调后-->
<!--Sansnn-uQRCode组件来源,插件市场:https://ext.dcloud.net.cn/plugin?id=1287 微调后-->
<Sansnn-uQRCode
:text=
"about.download"
:makeOnLoad=
"true"
class=
"qrcode"
></Sansnn-uQRCode>
<Sansnn-uQRCode
:text=
"about.download"
:makeOnLoad=
"true"
class=
"qrcode"
></Sansnn-uQRCode>
<text
class=
"tip"
>
扫描二维码,您的朋友也可以下载
{{
about
.
appName
}}
客户端
</text>
<text
class=
"tip"
>
扫描二维码,您的朋友也可以下载
{{
about
.
appName
}}
客户端
</text>
</view>
</view>
<view
class=
"copyright"
>
<view
class=
"copyright"
>
<view
class=
"agreement-box"
v-for=
"(agreement,index) in about.agreements"
:key=
"index"
>
<view
class=
"agreement-box"
v-for=
"(agreement,index) in about.agreements"
:key=
"index"
>
<text
class=
"agreement"
@
click=
"navigateTo(agreement)"
>
《
{{
agreement
.
title
}}
》
</text>
<text
class=
"agreement"
@
click=
"navigateTo(agreement)"
>
《
{{
agreement
.
title
}}
》
</text>
<text
class=
"hint"
v-if=
"about.agreements.length-1>index"
>
和
</text>
<text
class=
"hint"
v-if=
"about.agreements.length-1>index"
>
和
</text>
</view>
</view>
<text
class=
"hint"
>
Copyright ©
{{
year
}}
</text>
<text
class=
"hint"
>
Copyright ©
{{
year
}}
</text>
<text
class=
"hint"
>
{{
about
.
company
}}
</text>
<text
class=
"hint"
>
{{
about
.
company
}}
</text>
</view>
</view>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
import
uniShare
from
'
@/uni_modules/uni-share/js_sdk/uni-share.js
'
;
import
uniShare
from
'
@/uni_modules/uni-share/js_sdk/uni-share.js
'
;
export
default
{
export
default
{
onLoad
()
{
onLoad
()
{
// #ifdef APP-PLUS
// #ifdef APP-PLUS
this
.
version
=
plus
.
runtime
.
version
this
.
version
=
plus
.
runtime
.
version
// #endif
// #endif
},
},
computed
:{
computed
:
{
uniStarterConfig
(){
uniStarterConfig
()
{
console
.
log
(
getApp
());
console
.
log
(
getApp
());
return
getApp
().
globalData
.
config
return
getApp
().
globalData
.
config
}
}
},
},
data
()
{
data
()
{
return
{
return
{
version
:
"
V1.0.0
"
,
version
:
"
V1.0.0
"
,
year
:
"
2020
"
,
year
:
"
2020
"
,
about
:{}
about
:
{}
};
};
},
},
created
()
{
created
()
{
this
.
about
=
this
.
uniStarterConfig
.
about
this
.
about
=
this
.
uniStarterConfig
.
about
uni
.
setNavigationBarTitle
({
uni
.
setNavigationBarTitle
({
title
:
'
关于
'
+
this
.
about
.
appName
title
:
'
关于
'
+
this
.
about
.
appName
})
})
this
.
year
=
(
new
Date
).
getFullYear
()
this
.
year
=
(
new
Date
).
getFullYear
()
},
},
onNavigationBarButtonTap
()
{
onNavigationBarButtonTap
()
{
let
{
download
,
appName
,
slogan
,
logo
}
=
this
.
about
let
{
uniShare
({
download
,
content
:
{
//公共的分享类型(type)、链接(herf)、标题(title)、summary(描述)、imageUrl(缩略图)
appName
,
type
:
0
,
slogan
,
href
:
download
,
logo
title
:
appName
,
}
=
this
.
about
summary
:
slogan
,
uniShare
({
imageUrl
:
logo
+
'
?x-oss-process=image/resize,m_fill,h_100,w_100
'
//压缩图片解决,在ios端分享图过大导致的图片失效问题
content
:
{
//公共的分享类型(type)、链接(herf)、标题(title)、summary(描述)、imageUrl(缩略图)
},
type
:
0
,
menus
:
[{
href
:
download
,
"
img
"
:
"
/static/app-plus/sharemenu/wechatfriend.png
"
,
title
:
appName
,
"
text
"
:
"
微信好友
"
,
summary
:
slogan
,
"
share
"
:
{
imageUrl
:
logo
+
'
?x-oss-process=image/resize,m_fill,h_100,w_100
'
//压缩图片解决,在ios端分享图过大导致的图片失效问题
"
provider
"
:
"
weixin
"
,
},
"
scene
"
:
"
WXSceneSession
"
menus
:
[{
}
"
img
"
:
"
/static/app-plus/sharemenu/wechatfriend.png
"
,
},
"
text
"
:
"
微信好友
"
,
{
"
share
"
:
{
"
img
"
:
"
/static/app-plus/sharemenu/wechatmoments.png
"
,
"
provider
"
:
"
weixin
"
,
"
text
"
:
"
微信朋友圈
"
,
"
scene
"
:
"
WXSceneSession
"
"
share
"
:
{
}
"
provider
"
:
"
weixin
"
,
},
"
scene
"
:
"
WXSenceTimeline
"
{
}
"
img
"
:
"
/static/app-plus/sharemenu/wechatmoments.png
"
,
},
"
text
"
:
"
微信朋友圈
"
,
{
"
share
"
:
{
"
img
"
:
"
/static/app-plus/sharemenu/weibo.png
"
,
"
provider
"
:
"
weixin
"
,
"
text
"
:
"
微博
"
,
"
scene
"
:
"
WXSenceTimeline
"
"
share
"
:
{
}
"
provider
"
:
"
sinaweibo
"
},
}
{
},
"
img
"
:
"
/static/app-plus/sharemenu/weibo.png
"
,
{
"
text
"
:
"
微博
"
,
"
img
"
:
"
/static/app-plus/sharemenu/qq.png
"
,
"
share
"
:
{
"
text
"
:
"
QQ
"
,
"
provider
"
:
"
sinaweibo
"
"
share
"
:
{
}
"
provider
"
:
"
qq
"
},
}
{
},
"
img
"
:
"
/static/app-plus/sharemenu/qq.png
"
,
{
"
text
"
:
"
QQ
"
,
"
img
"
:
"
/static/app-plus/sharemenu/copyurl.png
"
,
"
share
"
:
{
"
text
"
:
"
复制
"
,
"
provider
"
:
"
qq
"
"
share
"
:
"
copyurl
"
}
},
},
{
{
"
img
"
:
"
/static/app-plus/sharemenu/more.png
"
,
"
img
"
:
"
/static/app-plus/sharemenu/copyurl.png
"
,
"
text
"
:
"
更多
"
,
"
text
"
:
"
复制
"
,
"
share
"
:
"
shareSystem
"
"
share
"
:
"
copyurl
"
}
},
],
{
cancelText
:
"
取消分享
"
,
"
img
"
:
"
/static/app-plus/sharemenu/more.png
"
,
},
e
=>
{
//callback
"
text
"
:
"
更多
"
,
console
.
log
(
e
);
"
share
"
:
"
shareSystem
"
})
}
},
],
methods
:{
cancelText
:
"
取消分享
"
,
navigateTo
({
url
,
title
}){
},
e
=>
{
//callback
uni
.
navigateTo
({
console
.
log
(
e
);
url
:
'
/pages/common/webview/webview?url=
'
+
url
+
'
&title=
'
+
title
,
})
success
:
res
=>
{},
},
fail
:
()
=>
{},
methods
:
{
complete
:
()
=>
{}
navigateTo
({
});
url
,
}
title
}
})
{
}
uni
.
navigateTo
({
</
script
>
url
:
'
/pages/common/webview/webview?url=
'
+
url
+
'
&title=
'
+
title
,
<
style
lang=
"scss"
scoped
>
success
:
res
=>
{},
@import
'@/common/all-flex.css'
;
fail
:
()
=>
{},
.about
{
complete
:
()
=>
{}
width
:
750upx
;
});
flex-direction
:
column
;
}
}
}
.box
{
}
margin-top
:
100px
;
</
script
>
flex-direction
:
column
;
<
style
lang=
"scss"
scoped
>
justify-content
:
center
;
/* #ifndef APP-NVUE */
align-items
:
center
;
view
{
}
display
:
flex
;
.logoImg
{
box-sizing
:
border-box
;
margin-bottom
:
10upx
;
flex-direction
:
column
;
width
:
160upx
;
}
height
:
160upx
;
border-radius
:
15px
;
/* #endif */
}
.about
{
.tip
{
width
:
750upx
;
font-size
:
24rpx
;
flex-direction
:
column
;
margin-top
:
10px
;
}
}
.appName
{
.box
{
margin-top
:
20px
;
margin-top
:
100px
;
font-size
:
42rpx
;
flex-direction
:
column
;
font-weight
:
500
;
justify-content
:
center
;
}
align-items
:
center
;
.qrcode
{
}
margin-top
:
50px
;
}
.logoImg
{
.copyright
{
margin-bottom
:
10upx
;
width
:
750upx
;
width
:
160upx
;
font-size
:
32rpx
;
height
:
160upx
;
flex-direction
:
column
;
border-radius
:
15px
;
justify-content
:
center
;
}
align-items
:
center
;
bottom
:
20px
;
.tip
{
left
:
0
;
font-size
:
24rpx
;
position
:
fixed
;
margin-top
:
10px
;
}
}
.agreement-box
{
justify-content
:
center
;
.appName
{
}
margin-top
:
20px
;
.agreement
{
font-size
:
42rpx
;
color
:
#2285ff
;
font-weight
:
500
;
font-size
:
26rpx
;
}
}
.hint
{
.qrcode
{
text-align
:
center
;
margin-top
:
50px
;
color
:
#999999
;
}
font-size
:
26rpx
;
}
.copyright
{
</
style
>
width
:
750upx
;
\ No newline at end of file
font-size
:
32rpx
;
flex-direction
:
column
;
justify-content
:
center
;
align-items
:
center
;
bottom
:
20px
;
left
:
0
;
position
:
fixed
;
}
.agreement-box
{
justify-content
:
center
;
}
.agreement
{
color
:
#2285ff
;
font-size
:
26rpx
;
}
.hint
{
text-align
:
center
;
color
:
#999999
;
font-size
:
26rpx
;
}
</
style
>
pages/ucenter/login-page/common/login-page.css
浏览文件 @
78a1788c
@import
'@/common/all-flex.css'
;
/* #ifndef APP-NVUE */
view
{
.content
{
display
:
flex
;
padding
:
0
50
rpx
;
box-sizing
:
border-box
;
width
:
750
rpx
;
flex-direction
:
column
;
flex
:
1
;
}
}
/* #endif */
.input-box
{
padding
:
0
15px
;
.content
{
margin-bottom
:
10px
;
padding
:
0
50
rpx
;
background-color
:
#F8F8F8
;
width
:
750
rpx
;
border-radius
:
6px
;
flex
:
1
;
font-size
:
28
rpx
;
}
}
.input-box
{
.get-code
{
padding
:
0
15px
;
margin
:
0
;
margin-bottom
:
10px
;
margin-top
:
15px
;
background-color
:
#F8F8F8
;
background-color
:
#007aff
;
border-radius
:
6px
;
color
:
#FFFFFF
;
font-size
:
28
rpx
;
}
}
.input-box
,
.get-code
{
.get-code
{
margin
:
0
;
height
:
45px
;
margin-top
:
15px
;
line-height
:
45px
;
background-color
:
#007aff
;
}
color
:
#FFFFFF
;
}
.title
{
text-align
:
center
;
.input-box
,
padding-bottom
:
5px
;
.get-code
{
}
height
:
45px
;
line-height
:
45px
;
.tip
{
}
color
:
#666666
;
font-size
:
26
rpx
;
.title
{
margin
:
6px
0
;
text-align
:
center
;
}
padding-bottom
:
5px
;
}
.easyinput
{
background-color
:
#F8F8F8
;
.tip
{
border-radius
:
6
rpx
;
color
:
#666666
;
}
font-size
:
26
rpx
;
margin
:
6px
0
;
.send-btn
{
}
width
:
100%
;
margin-top
:
15px
;
.easyinput
{
border-radius
:
6
rpx
;
background-color
:
#F8F8F8
;
}
border-radius
:
6
rpx
;
}
.link
{
color
:
#04498c
;
.send-btn
{
}
width
:
100%
;
margin-top
:
15px
;
border-radius
:
6
rpx
;
}
.link
{
color
:
#04498c
;
}
pages/ucenter/login-page/index/index.vue
浏览文件 @
78a1788c
...
@@ -109,7 +109,13 @@
...
@@ -109,7 +109,13 @@
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
'@/common/all-flex.css'
;
/* #ifndef APP-NVUE */
view
{
display
:
flex
;
box-sizing
:
border-box
;
flex-direction
:
column
;
}
/* #endif */
@import
url("../common/login-page.css")
;
@import
url("../common/login-page.css")
;
.quickLogin
{
.quickLogin
{
width
:
650rpx
;
width
:
650rpx
;
...
@@ -122,4 +128,4 @@
...
@@ -122,4 +128,4 @@
margin
:
20px
0
;
margin
:
20px
0
;
width
:
450rpx
;
width
:
450rpx
;
}
}
</
style
>
</
style
>
pages/ucenter/login-page/phone-code/phone-code.vue
浏览文件 @
78a1788c
...
@@ -2,11 +2,12 @@
...
@@ -2,11 +2,12 @@
<view
class=
"content"
>
<view
class=
"content"
>
<!-- 顶部文字 -->
<!-- 顶部文字 -->
<text
class=
"tit"
>
请输入验证码
</text>
<text
class=
"tit"
>
请输入验证码
</text>
<text
class=
"tip"
>
{{
tipText
}}
</text>
<text
class=
"tip"
>
{{
tipText
}}
</text>
<uni-forms>
<!-- 登录框 (选择手机号所属国家和地区需要另行实现) -->
<!-- 登录框 (选择手机号所属国家和地区需要另行实现) -->
<uni-easyinput
type=
"number"
class=
"easyinput"
:inputBorder=
"false"
<uni-easyinput
type=
"number"
class=
"easyinput"
:inputBorder=
"false"
v-model=
"code"
maxlength=
"6"
placeholder=
"请输入验证码"
>
v-model=
"code"
maxlength=
"6"
placeholder=
"请输入验证码"
>
<template
slot=
"right"
>
<template
v-slot:right
>
<uni-send-sms-code
:phone=
"phone"
ref=
"sendSmsCode"
></uni-send-sms-code>
<uni-send-sms-code
:phone=
"phone"
ref=
"sendSmsCode"
></uni-send-sms-code>
</
template
>
</
template
>
</uni-easyinput>
</uni-easyinput>
...
@@ -37,8 +38,8 @@
...
@@ -37,8 +38,8 @@
onLoad
({
phoneNumber
,
phoneArea
})
{
onLoad
({
phoneNumber
,
phoneArea
})
{
this
.
phone
=
phoneNumber
;
this
.
phone
=
phoneNumber
;
},
},
onReady
()
{
onReady
()
{
this
.
$refs
.
sendSmsCode
.
start
();
this
.
$refs
.
sendSmsCode
.
start
();
},
},
methods
:
{
methods
:
{
submit
(){
//完成并提交
submit
(){
//完成并提交
...
...
pages/ucenter/settings/settings.vue
浏览文件 @
78a1788c
...
@@ -240,7 +240,6 @@
...
@@ -240,7 +240,6 @@
border
:
none
;
border
:
none
;
border-radius
:
0
;
border-radius
:
0
;
}
}
/* #endif */
/* #endif */
.content
{
.content
{
/* #ifndef APP-NVUE */
/* #ifndef APP-NVUE */
...
...
pages/ucenter/ucenter.vue
浏览文件 @
78a1788c
<
template
>
<
template
>
<view
class=
"center"
>
<view
class=
"center"
>
<uni-sign-in
ref=
"signIn"
></uni-sign-in>
<uni-sign-in
ref=
"signIn"
></uni-sign-in>
<view
class=
"userInfo"
@
click.capture=
"toUserInfo"
>
<view
class=
"userInfo"
@
click.capture=
"toUserInfo"
>
<uni-file-picker
v-if=
"userInfo.avatar_file&&userInfo.avatar_file.url"
v-model=
"userInfo.avatar_file"
<uni-file-picker
v-if=
"userInfo.avatar_file&&userInfo.avatar_file.url"
v-model=
"userInfo.avatar_file"
fileMediatype=
"image"
:del-icon=
"false"
return-type=
"object"
:image-styles=
"listStyles"
disablePreview
fileMediatype=
"image"
:del-icon=
"false"
return-type=
"object"
:image-styles=
"listStyles"
disablePreview
disabled
/>
disabled
/>
...
@@ -60,8 +60,7 @@
...
@@ -60,8 +60,7 @@
}
}
],
],
ucenterList
:
[
ucenterList
:
[
[
[{
{
"
title
"
:
'
签到有奖
'
,
"
title
"
:
'
签到有奖
'
,
"
event
"
:
'
signIn
'
,
"
event
"
:
'
signIn
'
,
"
icon
"
:
"
compose
"
"
icon
"
:
"
compose
"
...
@@ -85,7 +84,7 @@
...
@@ -85,7 +84,7 @@
"
icon
"
:
"
paperplane
"
"
icon
"
:
"
paperplane
"
}
}
// #ifdef APP-PLUS
// #ifdef APP-PLUS
,{
,
{
"
title
"
:
'
分销推荐
'
,
"
title
"
:
'
分销推荐
'
,
"
event
"
:
'
share
'
,
"
event
"
:
'
share
'
,
"
icon
"
:
"
redo
"
"
icon
"
:
"
redo
"
...
@@ -155,7 +154,7 @@
...
@@ -155,7 +154,7 @@
url
:
"
/pages/ucenter/settings/settings
"
url
:
"
/pages/ucenter/settings/settings
"
})
})
},
},
signIn
()
{
//签到
signIn
()
{
//签到
this
.
$refs
.
signIn
.
open
()
this
.
$refs
.
signIn
.
open
()
},
},
/**
/**
...
@@ -233,7 +232,9 @@
...
@@ -233,7 +232,9 @@
})
})
},
},
async
share
()
{
async
share
()
{
let
{
result
}
=
await
uniCloud
.
callFunction
({
let
{
result
}
=
await
uniCloud
.
callFunction
({
name
:
'
uni-id-cf
'
,
name
:
'
uni-id-cf
'
,
data
:
{
data
:
{
action
:
'
getUserInviteCode
'
action
:
'
getUserInviteCode
'
...
@@ -256,7 +257,8 @@
...
@@ -256,7 +257,8 @@
`/#/pages/ucenter/invite/invite?code=uniInvitationCode:
${
myInviteCode
}
`
,
`/#/pages/ucenter/invite/invite?code=uniInvitationCode:
${
myInviteCode
}
`
,
title
:
appName
,
title
:
appName
,
summary
:
slogan
,
summary
:
slogan
,
imageUrl
:
logo
+
'
?x-oss-process=image/resize,m_fill,h_100,w_100
'
//压缩图片解决,在ios端分享图过大导致的图片失效问题
imageUrl
:
logo
+
'
?x-oss-process=image/resize,m_fill,h_100,w_100
'
//压缩图片解决,在ios端分享图过大导致的图片失效问题
},
},
menus
:
[{
menus
:
[{
"
img
"
:
"
/static/app-plus/sharemenu/wechatfriend.png
"
,
"
img
"
:
"
/static/app-plus/sharemenu/wechatfriend.png
"
,
...
@@ -310,8 +312,13 @@
...
@@ -310,8 +312,13 @@
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
'@/common/all-flex.css'
;
/* #ifndef APP-NVUE */
/* #ifndef APP-PLUS-NVUE */
view
{
display
:
flex
;
box-sizing
:
border-box
;
flex-direction
:
column
;
}
page
{
page
{
background-color
:
#f8f8f8
;
background-color
:
#f8f8f8
;
}
}
...
@@ -418,4 +425,4 @@
...
@@ -418,4 +425,4 @@
/* #endif */
/* #endif */
background-color
:
#DD524D
;
background-color
:
#DD524D
;
}
}
</
style
>
</
style
>
pages/ucenter/userinfo/userinfo.vue
浏览文件 @
78a1788c
<
template
>
<
template
>
<view>
<view>
<uni-list>
<uni-list>
<uni-list-item
class=
"item"
>
<uni-list-item
class=
"item"
>
<template
v-slot:body
>
<template
v-slot:body
>
<view
class=
"item"
>
<view
class=
"item"
>
<text>
头像
</text>
<text>
头像
</text>
<uni-file-picker
@
click.native=
"uploadAvatarImg"
@
delete=
"removeAvatar"
v-model=
"avatar_file"
<uni-file-picker
@
click.native=
"uploadAvatarImg"
@
delete=
"removeAvatar"
v-model=
"avatar_file"
fileMediatype=
"image"
return-type=
"object"
:image-styles=
"listStyles"
disabled
/>
fileMediatype=
"image"
return-type=
"object"
:image-styles=
"listStyles"
disabled
/>
</view>
</view>
</
template
>
</
template
>
</uni-list-item>
</uni-list-item>
<uni-list-item
class=
"item"
@
click=
"setNickname('')"
title=
"昵称"
:rightText=
"userInfo.nickname||'未设置'"
link
>
<uni-list-item
class=
"item"
@
click=
"setNickname('')"
title=
"昵称"
:rightText=
"userInfo.nickname||'未设置'"
link
>
...
@@ -266,7 +266,13 @@
...
@@ -266,7 +266,13 @@
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
'@/common/all-flex.css'
;
/* #ifndef APP-NVUE */
view
{
display
:
flex
;
box-sizing
:
border-box
;
flex-direction
:
column
;
}
/* #endif */
.item
{
.item
{
width
:
750rpx
;
width
:
750rpx
;
flex-direction
:
row
;
flex-direction
:
row
;
...
...
uni_modules/uni-config-center/uniCloud/cloudfunctions/common/uni-config-center/uni-id/config.json
0 → 100644
浏览文件 @
78a1788c
{
"passwordSecret"
:
"passwordSecret-demo"
,
"tokenSecret"
:
"tokenSecret-demo"
,
"tokenExpiresIn"
:
7200
,
"tokenExpiresThreshold"
:
600
,
"passwordErrorLimit"
:
6
,
"bindTokenToDevice"
:
false
,
"passwordErrorRetryTime"
:
3600
,
"autoSetInviteCode"
:
false
,
"forceInviteCode"
:
false
,
"app-plus"
:
{
"tokenExpiresIn"
:
2592000
,
"oauth"
:
{
"weixin"
:
{
"appid"
:
"填写来源微信开放平台https://open.weixin.qq.com/创建的应用的appid"
,
"appsecret"
:
"填写来源微信开放平台https://open.weixin.qq.com/创建的应用的appsecret"
},
"apple"
:
{
"bundleId"
:
"苹果开发者后台获取的bundleId"
}
}
},
"mp-weixin"
:
{
"oauth"
:
{
"weixin"
:
{
"appid"
:
"微信小程序登录所用的appid、appsecret需要在对应的小程序管理控制台获取"
,
"appsecret"
:
"微信小程序后台获取的appsecret"
}
}
},
"mp-alipay"
:
{
"oauth"
:
{
"alipay"
:
{
"appid"
:
"支付宝小程序登录用到的appid、privateKey请参考支付宝小程序的文档进行设置或者获取,https://opendocs.alipay.com/open/291/105971#LDsXr"
,
"privateKey"
:
"支付宝小程序登录用到的appid、privateKey请参考支付宝小程序的文档进行设置或者获取,https://opendocs.alipay.com/open/291/105971#LDsXr"
}
}
},
"service"
:
{
"sms"
:
{
"name"
:
"应用名称,对应短信模版的name"
,
"codeExpiresIn"
:
300
,
"smsKey"
:
"短信密钥key,开通短信服务处可以看到"
,
"smsSecret"
:
"短信密钥secret,开通短信服务处可以看到"
},
"univerify"
:
{
"appid"
:
"当前应用的appid,使用云函数URL化,此项必须配置"
,
"apiKey"
:
"apiKey 和 apiSecret 在开发者中心获取,开发者中心:https://dev.dcloud.net.cn/uniLogin/index?type=0,文档:https://ask.dcloud.net.cn/article/37965"
,
"apiSecret"
:
""
}
}
}
\ No newline at end of file
uni_modules/uni-file-picker/components/uni-file-picker/uni-file-picker.vue
浏览文件 @
78a1788c
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
<view
v-if=
"title"
class=
"uni-file-picker__header"
>
<view
v-if=
"title"
class=
"uni-file-picker__header"
>
<text
class=
"file-title"
>
{{
title
}}
</text>
<text
class=
"file-title"
>
{{
title
}}
</text>
<text
class=
"file-count"
>
{{
filesList
.
length
}}
/
{{
limitLength
}}
</text>
<text
class=
"file-count"
>
{{
filesList
.
length
}}
/
{{
limitLength
}}
</text>
</view>
</view>
<upload-image
<upload-image
v-if=
"fileMediatype === 'image' && showType === 'grid'"
v-if=
"fileMediatype === 'image' && showType === 'grid'"
:readonly=
"readonly"
:readonly=
"readonly"
...
@@ -39,10 +39,10 @@
...
@@ -39,10 +39,10 @@
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
import
{
chooseAndUploadFile
}
from
'
./choose-and-upload-file.js
'
import
{
chooseAndUploadFile
}
from
'
./choose-and-upload-file.js
'
import
uploadImage
from
'
./upload-image.vue
'
import
uploadImage
from
'
./upload-image.vue
'
import
uploadFile
from
'
./upload-file.vue
'
import
uploadFile
from
'
./upload-file.vue
'
let
fileInput
=
null
let
fileInput
=
null
/**
/**
* FilePicker 文件选择上传
* FilePicker 文件选择上传
...
@@ -92,18 +92,24 @@ export default {
...
@@ -92,18 +92,24 @@ export default {
uploadFile
uploadFile
},
},
props
:
{
props
:
{
// #ifdef VUE3
modelValue
:
{
type
:
[
Array
,
Object
],
default
()
{
return
[]
}
},
// #endif
// #ifndef VUE3
value
:
{
value
:
{
type
:
[
Array
,
Object
],
type
:
[
Array
,
Object
],
default
()
{
default
()
{
return
[]
return
[]
}
}
},
modelValue
:
{
type
:
[
Array
,
Object
],
default
()
{
return
[]
}
},
},
// #endif
disabled
:
{
disabled
:
{
type
:
Boolean
,
type
:
Boolean
,
default
:
false
default
:
false
...
@@ -131,10 +137,6 @@ export default {
...
@@ -131,10 +137,6 @@ export default {
type
:
String
,
type
:
String
,
default
:
'
grid
'
default
:
'
grid
'
},
},
// inputUrl: {
// type: Boolean,
// default: false
// },
// 选择文件类型 image/video/all
// 选择文件类型 image/video/all
fileMediatype
:
{
fileMediatype
:
{
type
:
String
,
type
:
String
,
...
@@ -180,27 +182,32 @@ export default {
...
@@ -180,27 +182,32 @@ export default {
returnType
:
{
returnType
:
{
type
:
String
,
type
:
String
,
default
:
'
array
'
default
:
'
array
'
},
},
sizeType
:{
sizeType
:{
type
:
Array
,
type
:
Array
,
default
(){
default
(){
return
[
'
original
'
,
'
compressed
'
]
return
[
'
original
'
,
'
compressed
'
]
}
}
}
}
},
},
watch
:
{
watch
:
{
// #ifndef VUE3
value
:
{
value
:
{
handler
(
newVal
)
{
handler
(
newVal
)
{
this
.
setValue
(
newVal
)
this
.
setValue
(
newVal
)
},
},
immediate
:
true
immediate
:
true
},
},
modelValue
:{
// #endif
handler
(
newVal
)
{
// #ifdef VUE3
this
.
setValue
(
newVal
)
modelValue
:{
},
handler
(
newVal
)
{
immediate
:
true
this
.
setValue
(
newVal
)
}
},
immediate
:
true
},
// #endif
},
},
data
()
{
data
()
{
return
{
return
{
...
@@ -232,18 +239,18 @@ export default {
...
@@ -232,18 +239,18 @@ export default {
return
9
return
9
}
}
return
this
.
limit
return
this
.
limit
},
},
extname
(){
extname
(){
if
(
!
Array
.
isArray
(
this
.
fileExtname
))
{
if
(
!
Array
.
isArray
(
this
.
fileExtname
))
{
let
extname
=
this
.
fileExtname
.
replace
(
/
(\[
|
\])
/g
,
''
)
let
extname
=
this
.
fileExtname
.
replace
(
/
(\[
|
\])
/g
,
''
)
return
extname
.
split
(
'
,
'
)
return
extname
.
split
(
'
,
'
)
}
else
{
}
else
{
return
this
.
fileExtname
return
this
.
fileExtname
}
}
return
[]
return
[]
}
}
},
},
created
()
{
created
()
{
// TODO 兼容不开通服务空间的情况
// TODO 兼容不开通服务空间的情况
if
(
!
(
uniCloud
.
config
&&
uniCloud
.
config
.
provider
)){
if
(
!
(
uniCloud
.
config
&&
uniCloud
.
config
.
provider
)){
this
.
noSpace
=
true
this
.
noSpace
=
true
...
@@ -251,37 +258,39 @@ export default {
...
@@ -251,37 +258,39 @@ export default {
}
}
this
.
tempData
=
{}
this
.
tempData
=
{}
this
.
form
=
this
.
getForm
(
'
uniForms
'
)
this
.
form
=
this
.
getForm
(
'
uniForms
'
)
this
.
formItem
=
this
.
getForm
(
'
uniFormsItem
'
)
this
.
formItem
=
this
.
getForm
(
'
uniFormsItem
'
)
if
(
this
.
form
&&
this
.
formItem
)
{
if
(
this
.
form
&&
this
.
formItem
)
{
if
(
this
.
formItem
.
name
)
{
if
(
this
.
formItem
.
name
)
{
this
.
rename
=
this
.
formItem
.
name
this
.
rename
=
this
.
formItem
.
name
this
.
form
.
inputChildrens
.
push
(
this
)
this
.
form
.
inputChildrens
.
push
(
this
)
}
}
}
}
},
},
methods
:
{
methods
:
{
setValue
(
newVal
){
setValue
(
newVal
){
let
newFils
=
[]
let
newFils
=
[]
let
newData
=
[].
concat
(
newVal
||
[])
let
newData
=
[].
concat
(
newVal
||
[])
newData
.
forEach
(
v
=>
{
newData
.
forEach
(
v
=>
{
const
files
=
this
.
files
.
find
(
i
=>
i
.
url
===
v
.
url
)
const
files
=
this
.
files
.
find
(
i
=>
i
.
url
===
v
.
url
)
const
reg
=
/cloud:
\/\/([\w
.
]
+
\/?)\S
*/
const
reg
=
/cloud:
\/\/([\w
.
]
+
\/?)\S
*/
if
(
!
v
.
path
)
{
if
(
!
v
.
path
)
{
v
.
path
=
v
.
url
v
.
path
=
v
.
url
}
}
if
(
reg
.
test
(
v
.
url
))
{
if
(
reg
.
test
(
v
.
url
))
{
this
.
getTempFileURL
(
v
,
v
.
url
)
this
.
getTempFileURL
(
v
,
v
.
url
)
}
}
newFils
.
push
(
files
?
files
:
v
)
newFils
.
push
(
files
?
files
:
v
)
})
})
let
data
=
null
let
data
=
null
if
(
this
.
returnType
===
'
object
'
)
{
if
(
this
.
returnType
===
'
object
'
)
{
data
=
this
.
backObject
(
newFils
)[
0
]
data
=
this
.
backObject
(
newFils
)[
0
]
}
else
{
}
else
{
data
=
this
.
backObject
(
newFils
)
data
=
this
.
backObject
(
newFils
)
}
}
this
.
formItem
&&
this
.
formItem
.
setValue
(
data
)
this
.
formItem
&&
this
.
formItem
.
setValue
(
data
)
if
(
newFils
.
length
)
this
.
files
=
newFils
if
(
newFils
.
length
){
this
.
files
=
newFils
}
},
},
/**
/**
* 获取父元素实例
* 获取父元素实例
...
@@ -351,7 +360,7 @@ export default {
...
@@ -351,7 +360,7 @@ export default {
uniCloud
uniCloud
.
chooseAndUploadFile
({
.
chooseAndUploadFile
({
type
:
this
.
fileMediatype
,
type
:
this
.
fileMediatype
,
compressed
:
false
,
compressed
:
false
,
sizeType
:
this
.
sizeType
,
sizeType
:
this
.
sizeType
,
// TODO 如果为空,video 有问题
// TODO 如果为空,video 有问题
extension
:
this
.
extname
.
length
>
0
?
this
.
extname
:
undefined
,
extension
:
this
.
extname
.
length
>
0
?
this
.
extname
:
undefined
,
...
@@ -382,17 +391,16 @@ export default {
...
@@ -382,17 +391,16 @@ export default {
filePaths
=
res
.
tempFilePaths
filePaths
=
res
.
tempFilePaths
files
=
res
.
tempFiles
files
=
res
.
tempFiles
}
}
let
currentData
=
[]
let
currentData
=
[]
for
(
let
i
=
0
;
i
<
files
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
files
.
length
;
i
++
)
{
if
(
this
.
limitLength
-
this
.
files
.
length
<=
0
)
break
if
(
this
.
limitLength
-
this
.
files
.
length
<=
0
)
break
files
[
i
].
uuid
=
Date
.
now
()
files
[
i
].
uuid
=
Date
.
now
()
let
filedata
=
await
this
.
getFileData
(
files
[
i
],
this
.
fileMediatype
)
let
filedata
=
await
this
.
getFileData
(
files
[
i
],
this
.
fileMediatype
)
filedata
.
file
=
files
[
i
]
filedata
.
progress
=
0
filedata
.
progress
=
0
filedata
.
status
=
'
ready
'
filedata
.
status
=
'
ready
'
this
.
files
.
push
(
filedata
)
this
.
files
.
push
(
filedata
)
currentData
.
push
(
filedata
)
currentData
.
push
(
{...
filedata
,
file
:
files
[
i
]}
)
}
}
this
.
$emit
(
'
select
'
,
{
this
.
$emit
(
'
select
'
,
{
tempFiles
:
currentData
,
tempFiles
:
currentData
,
...
@@ -415,7 +423,7 @@ export default {
...
@@ -415,7 +423,7 @@ export default {
this
.
setProgress
(
progressEvent
,
progressEvent
.
index
)
this
.
setProgress
(
progressEvent
,
progressEvent
.
index
)
}
}
})
})
.
then
(
result
=>
{
.
then
(
result
=>
{
this
.
setSuccessAndError
(
result
.
tempFiles
)
this
.
setSuccessAndError
(
result
.
tempFiles
)
})
})
.
catch
(
err
=>
{
.
catch
(
err
=>
{
...
@@ -522,8 +530,8 @@ export default {
...
@@ -522,8 +530,8 @@ export default {
tempFilePath
:
this
.
files
[
index
].
url
tempFilePath
:
this
.
files
[
index
].
url
})
})
this
.
files
.
splice
(
index
,
1
)
this
.
files
.
splice
(
index
,
1
)
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
this
.
setEmit
()
this
.
setEmit
()
})
})
},
},
...
@@ -570,7 +578,6 @@ export default {
...
@@ -570,7 +578,6 @@ export default {
uuid
:
files
.
uuid
,
uuid
:
files
.
uuid
,
extname
:
extname
||
''
,
extname
:
extname
||
''
,
cloudPath
:
files
.
cloudPath
,
cloudPath
:
files
.
cloudPath
,
file
:
files
.
file
,
fileType
:
files
.
fileType
,
fileType
:
files
.
fileType
,
url
:
files
.
path
||
files
.
path
,
url
:
files
.
path
||
files
.
path
,
size
:
files
.
size
,
//单位是字节
size
:
files
.
size
,
//单位是字节
...
@@ -648,7 +655,12 @@ export default {
...
@@ -648,7 +655,12 @@ export default {
}
else
{
}
else
{
data
=
this
.
backObject
(
this
.
files
)
data
=
this
.
backObject
(
this
.
files
)
}
}
// #ifdef VUE3
this
.
$emit
(
'
update:modelValue
'
,
data
)
// #endif
// #ifndef VUE3
this
.
$emit
(
'
input
'
,
data
)
this
.
$emit
(
'
input
'
,
data
)
// #endif
},
},
backObject
(
files
)
{
backObject
(
files
)
{
let
newFilesData
=
JSON
.
parse
(
JSON
.
stringify
(
files
))
let
newFilesData
=
JSON
.
parse
(
JSON
.
stringify
(
files
))
...
@@ -725,4 +737,4 @@ export default {
...
@@ -725,4 +737,4 @@ export default {
position
:
absolute
;
position
:
absolute
;
transform
:
rotate
(
90deg
);
transform
:
rotate
(
90deg
);
}
}
</
style
>
</
style
>
\ No newline at end of file
uni_modules/uni-id-cf/uniCloud/cloudfunctions/uni-id-cf/index.js
浏览文件 @
78a1788c
...
@@ -248,11 +248,11 @@ exports.main = async (event, context) => {
...
@@ -248,11 +248,11 @@ exports.main = async (event, context) => {
break
;
break
;
case
'
sendSmsCode
'
:
case
'
sendSmsCode
'
:
/* -开始- 测试期间,为节约资源。统一虚拟短信验证码为: 123456;开启以下代码块即可 */
/* -开始- 测试期间,为节约资源。统一虚拟短信验证码为: 123456;开启以下代码块即可 */
//
return uniID.setVerifyCode({
return
uniID
.
setVerifyCode
({
//
mobile: params.mobile,
mobile
:
params
.
mobile
,
//
code: '123456',
code
:
'
123456
'
,
//
type: params.type
type
:
params
.
type
//
})
})
/* -结束- */
/* -结束- */
// 简单限制一下客户端调用频率
// 简单限制一下客户端调用频率
...
...
uni_modules/uni-sign-in/components/uni-sign-in/uni-sign-in.vue
浏览文件 @
78a1788c
...
@@ -188,7 +188,7 @@
...
@@ -188,7 +188,7 @@
border-radius
:
100px
;
border-radius
:
100px
;
height
:
50rpx
;
height
:
50rpx
;
line-height
:
50rpx
;
line-height
:
50rpx
;
justify-content
:
center
;
text-align
:
center
;
width
:
50rpx
;
width
:
50rpx
;
margin-bottom
:
6rpx
;
margin-bottom
:
6rpx
;
}
}
...
...
uni_modules_tools/config.js
浏览文件 @
78a1788c
...
@@ -4,7 +4,9 @@
...
@@ -4,7 +4,9 @@
"
appid
"
:
"
请点击重新获取
"
,
//清空appid
"
appid
"
:
"
请点击重新获取
"
,
//清空appid
"
mp-weixin
"
:
{
"
mp-weixin
"
:
{
"
appid
"
:
""
"
appid
"
:
""
}
},
"
_spaceID
"
:
""
,
"
vueVersion
"
:
"
2
"
},
},
"
/uni_modules/uni-config-center/uniCloud/cloudfunctions/common/uni-config-center/uni-id/config.json
"
:
{
"
/uni_modules/uni-config-center/uniCloud/cloudfunctions/common/uni-config-center/uni-id/config.json
"
:
{
"
tokenExpiresIn
"
:
7200
,
"
tokenExpiresIn
"
:
7200
,
...
...
uni_modules_tools/copy/manifest.json
浏览文件 @
78a1788c
...
@@ -115,5 +115,6 @@
...
@@ -115,5 +115,6 @@
"h5"
:
{
"h5"
:
{
"template"
:
""
"template"
:
""
},
},
"_spaceID"
:
"76ce2c5e-31c7-4d81-8fcf-ed1541ecbc6e"
"_spaceID"
:
"76ce2c5e-31c7-4d81-8fcf-ed1541ecbc6e"
,
"vueVersion"
:
"2"
}
}
uni_modules_tools/copy/uni_modules/uni-config-center/uniCloud/cloudfunctions/common/uni-config-center/uni-id/config.json
浏览文件 @
78a1788c
...
@@ -44,9 +44,9 @@
...
@@ -44,9 +44,9 @@
"smsSecret"
:
"短信密钥secret,开通短信服务处可以看到"
"smsSecret"
:
"短信密钥secret,开通短信服务处可以看到"
},
},
"univerify"
:
{
"univerify"
:
{
"appid"
:
"
__UNI__03B096E
"
,
"appid"
:
"
当前应用的appid,使用云函数URL化,此项必须配置
"
,
"apiKey"
:
"
3fc28519d90d74173bcecf2daf4ffcc4
"
,
"apiKey"
:
"
apiKey 和 apiSecret 在开发者中心获取,开发者中心:https://dev.dcloud.net.cn/uniLogin/index?type=0,文档:https://ask.dcloud.net.cn/article/37965
"
,
"apiSecret"
:
"
dd793e5bc4b372ce932f35bbb4c5d61b
"
"apiSecret"
:
""
}
}
}
}
}
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录