Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
_milo
Great Teamwork
提交
422bcf2f
Great Teamwork
项目概览
_milo
/
Great Teamwork
通知
13
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Great Teamwork
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
422bcf2f
编写于
5月 05, 2023
作者:
M
m0_74163447
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
密码判定
上级
9c05343f
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
57 addition
and
10 deletion
+57
-10
teamwork/pages/my/my-modify.vue
teamwork/pages/my/my-modify.vue
+5
-5
teamwork/pages/my/my-resetpassword.vue
teamwork/pages/my/my-resetpassword.vue
+52
-5
未找到文件。
teamwork/pages/my/my-modify.vue
浏览文件 @
422bcf2f
...
...
@@ -145,18 +145,17 @@
// })
// }
// },
savaInfo
()
{
savaInfo
()
{
uni
.
showModal
({
title
:
'
温馨提示
'
,
//提示标题
content
:
'
确认修改你的个人信息吗
'
,
//提示内容
showCancel
:
true
,
//是否显示取消按钮
success
:
function
(
res
)
{
success
:
res
=>
{
if
(
res
.
confirm
)
{
//confirm为ture,代表用户点击确定
let
that
=
this
;
let
nickname
=
that
.
nickName
;
let
mobile
=
that
.
mobile
;
// let updata = {};
if
(
!
nickname
)
{
uni
.
showToast
({
...
...
@@ -173,7 +172,7 @@
// updata.headimg = headimg;
// updata.gender = gender;
if
(
that
.
isPoneAvailable
(
mobile
))
{
updata
.
mobile
=
mobile
;
//
updata.mobile = mobile;
}
else
{
uni
.
showToast
({
title
:
'
手机号码有误,请重填
'
,
...
...
@@ -191,6 +190,7 @@
})
},
isPoneAvailable
(
poneInput
)
{
var
myreg
=
/^
[
1
][
3,4,5,7,8
][
0-9
]{9}
$/
;
if
(
!
myreg
.
test
(
poneInput
))
{
...
...
teamwork/pages/my/my-resetpassword.vue
浏览文件 @
422bcf2f
...
...
@@ -18,11 +18,13 @@
</veiw>
<veiw
class=
"password"
>
<span>
新
 
密
 
码:
</span>
<input
placeholder=
"请输入新密码"
type=
"text"
:password=
"showPassword"
name=
"input"
></input>
<input
placeholder=
"请输入新密码"
type=
"text"
@
input=
"bindNewPassword"
:password=
"showPassword"
name=
"input"
></input>
</veiw>
<veiw
class=
"password"
>
<span>
确认密码:
</span>
<input
placeholder=
"请确认密码"
type=
"text"
:password=
"showPassword"
name=
"input"
></input>
<input
placeholder=
"请确认密码"
type=
"text"
@
input=
"bindConfirmPassword"
:password=
"showPassword"
name=
"input"
></input>
</veiw>
</view>
<view
class=
"confirm"
>
...
...
@@ -36,9 +38,17 @@
data
()
{
return
{
showPassword
:
true
,
newPassword
:
''
,
confirmPassword
:
''
,
}
},
methods
:
{
bindNewPassword
(
e
)
{
this
.
newPassword
=
e
.
detail
.
value
;
},
bindConfirmPassword
(
e
)
{
this
.
confirmPassword
=
e
.
detail
.
value
;
},
// showPwd: function() {
// this.showPassword = !this.showPassword;
// },
...
...
@@ -48,21 +58,58 @@
title
:
'
温馨提示
'
,
//提示标题
content
:
'
确认修改密码吗
'
,
//提示内容
showCancel
:
true
,
//是否显示取消按钮
success
:
function
(
res
)
{
success
:
res
=>
{
if
(
res
.
confirm
)
{
//confirm为ture,代表用户点击确定
console
.
log
(
'
点击了确定按钮
'
);
let
that
=
this
;
let
newPassword
=
that
.
newPassword
;
let
confirmPassword
=
that
.
confirmPassword
;
if
(
!
that
.
isPasswordAvailable
(
newPassword
))
{
uni
.
showToast
({
title
:
'
密码长度在8-20位!
'
,
icon
:
'
none
'
,
duration
:
2000
});
return
;
}
else
if
(
!
that
.
isConfirmPasswordAvailable
(
newPassword
,
confirmPassword
))
{
uni
.
showToast
({
title
:
'
两次密码不一致
'
,
icon
:
'
none
'
,
duration
:
2000
});
return
;
}
else
{
// updata.mobile = mobile;
//return;
}
}
else
if
(
res
.
cancel
)
{
//cancel为ture,代表用户点击取消
console
.
log
(
'
点击了取消按钮
'
);
}
}
})
},
isPasswordAvailable
(
newPassword
)
{
if
(
newPassword
.
length
>
20
||
newPassword
.
length
<
8
)
{
return
false
;
}
else
{
return
true
;
}
},
isConfirmPasswordAvailable
(
newPassword
,
confirmPassword
)
{
if
(
newPassword
==
confirmPassword
)
{
return
true
;
}
else
{
return
false
;
}
},
goBack
()
{
uni
.
navigateBack
({
delta
:
1
,
//返回层数,2则上上页
})
},
onload
(){
onload
()
{
plus
.
navigator
.
setStatusBarBackground
(
'
#EDEEF0
'
);
}
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录