Login.wxml
3.44 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
<view class="layout">
<view class="bg-top" wx:if="{{loginType==0}}">
<glsx-image src="/login/login-bg.png"></glsx-image>
</view>
<navigation-bar navStyle="background:transparent;" showBack page-title="登录"><text class="page-title">登录</text></navigation-bar>
<view class="content" style="margin-top: {{navHeight}}px;">
<block wx:if="{{loginType==0}}">
<view class="h1">您好</view>
<view class="h2">
欢迎使用积分会小程序
</view>
<view class="login-img">
<glsx-image src="/login/login-img.png"></glsx-image>
</view>
<view class="wx-box">
<block wx:if="{{!isAgree}}">
<button class="wx-auth-button text-center {{isAgree}}" bindtap="showModal">微信登录</button>
</block>
<block wx:else>
<button open-type="getPhoneNumber" catchgetphonenumber="getPhoneNumber" class="wx-auth-button text-center">微信登录</button>
</block>
</view>
</block>
<block wx:else>
<view class="h3">
手机号登录
</view>
<view class="box">
<view class="login-item flex">
<input maxlength="11" type="number" adjust-position="{{false}}" placeholder-class="placeholderClass" placeholder="填写手机号" bindinput="input" data-name="mobile" class="input" value="{{mobile}}" />
<view class="icon-box" wx:if="{{mobile}}" bindtap="clear" data-name="mobile">
<glsx-image src="/login/login-clear.png"></glsx-image>
</view>
</view>
<view class="login-item flex">
<input maxlength="4" type="number" adjust-position="{{false}}" placeholder-class="placeholderClass" placeholder="填写验证码" bindinput="input" data-name="captcha" class="input" value="{{captcha}}" />
<button disabled="{{!mobile}}" class="code-btn" bindtap="getSmsCode">{{count? count + 's':'获取验证码'}}</button>
</view>
</view>
<button class="wx-auth-button text-center" bindtap="phoneLogin">登录</button>
</block>
<view class="type-box flex">
<view class="title">
其他方式
</view>
<view class="type" bindtap="changeLoginType">
<view class="icon">
<glsx-image src="/login/{{loginType == 0?'phone':'wx'}}.png"></glsx-image>
</view>
{{loginType == 0?'手机号':'微信登录'}}
</view>
</view>
<view class="tips text-center" bindtap="handleChangeAgree">
<view class="check {{isAgree}}">
<glsx-image src="/login/check.png" class="icon"></glsx-image>
</view>
我已阅读并同意
<text class="txt-orange" catchtap="handleAgree" data-name="privacy">《隐私协议》</text>
<text class="txt-orange" catchtap="handleAgree" data-name="agreement">《服务使用协议》</text>
</view>
</view>
</view>
<glsx-privacy appletName="积分会"></glsx-privacy>
<Dialog show="{{ showAgreeModal }}" mask="true" bindbuttontap="dialogConfirm" buttons="{{buttons}}" title="隐私协议与用户协议">
<view class="suggest-box">
<view>为保障你的合法权益,请阅读并同意</view>
<text class="txt-orange" catchtap="handleAgree" data-name="privacy">《隐私协议》</text>
<text class="txt-orange" catchtap="handleAgree" data-name="agreement">《服务使用协议》</text>
</view>
</Dialog>
<!-- 积分来源选择 -->
<points-source show="{{showChooseSource}}" pointsSource="{{pointsSource}}" bindconfirm="pointSourceEvent"></points-source>