Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
C
center-shop-show-h5
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
center-shop-show-h5
Commits
eb4ce641
提交
eb4ce641
authored
6月 08, 2022
作者:
王鹏飞
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
chore: 新增URL参数控制是否显示密码登录
上级
aaf12860
隐藏空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
41 行增加
和
24 行删除
+41
-24
PhoneCodeLoginPopup.vue
src/components/PhoneCodeLoginPopup.vue
+41
-24
没有找到文件。
src/components/PhoneCodeLoginPopup.vue
浏览文件 @
eb4ce641
<
template
>
<van-popup
v-model=
"popupVisiable"
position=
"bottom"
class=
"buy-popup"
:style=
"
{ height: '60%' }"
>
<van-popup
v-model=
"popupVisiable"
position=
"bottom"
class=
"buy-popup"
:style=
"
{ height: '60%' }">
<h5>
手机号登录
</h5>
<van-form
:show-error=
"false"
@
submit=
"handleSuccess"
>
<van-field
v-model=
"form.mobile"
name=
"mobile"
label=
"手机号"
placeholder=
"请输入您的手机号"
:rules=
"[
{ required: true, message: '请输入您的手机号' }, { pattern: /^1(3[0-9]|4[01456879]|5[0-35-9]|6[2567]|7[0-8]|8[0-9]|9[0-35-9])\d{8}$/, message: '手机号格式有误' }]" clearable/>
<van-field
v-model=
"form.code"
name=
"code"
label=
"验证码"
placeholder=
"请输入手机验证码"
:rules=
"[
{ required: true, message: '请输入手机验证码' }]" maxlength="4" clearable>
<van-field
v-model=
"form.mobile"
name=
"mobile"
label=
"手机号"
placeholder=
"请输入您的手机号"
:rules=
"[
{ required: true, message: '请输入您的手机号' },
{ pattern: /^1(3[0-9]|4[01456879]|5[0-35-9]|6[2567]|7[0-8]|8[0-9]|9[0-35-9])\d{8}$/, message: '手机号格式有误' }
]"
clearable
/>
<van-field
v-model=
"form.code"
name=
"code"
label=
"验证码"
placeholder=
"请输入手机验证码"
:rules=
"[
{ required: true, message: '请输入手机验证码' }]" maxlength="4" clearable>
<template
#
button
>
<van-button
class=
"code-btn"
native-type=
"button"
size=
"small"
type=
"primary"
color=
"#F8F8F8"
:disabled=
"btnDisabled"
id=
"checkedCode"
@
click=
"sendCode"
>
获取验证码
</van-button>
</
template
>
</van-field>
<div
style=
"margin: 16px;"
>
<p
class=
"account-login"
@
click=
"goLogin"
>
账号密码登录
</p>
<p
class=
"account-login"
@
click=
"goLogin"
v-if=
"pageOptions.hasPasswordLogin"
>
账号密码登录
</p>
<van-button
type=
"primary"
round
block
color=
"#C01540"
size=
"small"
:disabled=
"payBtnDisabled"
>
登录
</van-button>
</div>
</van-form>
...
...
@@ -38,6 +48,14 @@ export default {
payBtnDisabled
:
false
}
},
computed
:
{
pageOptions
()
{
const
query
=
this
.
$route
.
query
return
{
hasPasswordLogin
:
query
.
has_password_login
!==
'0'
}
}
},
watch
:
{
value
:
{
handler
(
nv
)
{
...
...
@@ -115,30 +133,30 @@ export default {
}
</
script
>
<
style
lang=
"scss"
scoped
>
h5
{
color
:
#333333
;
font-size
:
0
.32rem
;
line-height
:
0
.8rem
;
h5
{
color
:
#333333
;
font-size
:
0
.32rem
;
line-height
:
0
.8rem
;
text-indent
:
0
.24rem
;
}
.van-field
{
::v-deep
.van-field__label
{
line-height
:
33px
;
height
:
33px
;
.van-field
{
::v-deep
.van-field__label
{
line-height
:
33px
;
height
:
33px
;
}
::v-deep
.van-field__control
{
line-height
:
33px
;
::v-deep
.van-field__control
{
line-height
:
33px
;
}
}
.account-login
{
color
:
#C
01540
;
font-size
:
12px
;
margin-bottom
:
15px
;
.account-login
{
color
:
#c
01540
;
font-size
:
12px
;
margin-bottom
:
15px
;
}
.code-btn
{
.van-button__text
{
color
:
#C
01540
;
width
:
66px
;
.code-btn
{
.van-button__text
{
color
:
#c
01540
;
width
:
66px
;
}
}
</
style
>
\ No newline at end of file
</
style
>
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论