bindCard.vue
5.21 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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
<template>
<v-layout id="BindCard" column justify-center align-center>
<v-flex>
<v-card id="CardInfoBlock" flat height="19rem">
<div class="NameBlock FormLine">
<div class="labelBlock">
<span>持卡人</span>
</div>
<v-text-field
v-model="form.name"
color="light-gold"
class="BindCardInput "
name="PhoneInput"
placeholder="请输入持卡人姓名"
id='NameInput'
single-line
></v-text-field>
</div>
<div class="IdBlock FormLine">
<div class="labelBlock">
<span>身份证号</span>
</div>
<v-text-field
v-model="form.idNo"
color="light-gold"
class="BindCardInput "
name="IdInput"
placeholder="请输入身份证号"
id='IdInput'
single-line
></v-text-field>
</div>
<div class="CardNoBlock FormLine">
<div class="labelBlock">
<span>银行卡号</span>
</div>
<v-text-field
v-model="form.cardNo"
color="light-gold"
class="BindCardInput "
name="CardNoInput"
placeholder="请输入银行卡号"
id='CardNoInput'
single-line
></v-text-field>
</div>
<div class="BankBlock FormLine" @click="pickerDisplay = true">
<div class="labelBlock">
<span>选择银行</span>
</div>
<div class="pickerValueBlock" v-if="!form.bank">{{'请选择'}}
<v-icon class="addCardIcon">keyboard_arrow_right</v-icon>
</div>
<div class="pickerValueBlockValue" v-if="!!form.bank" >
{{form.bank}}
</div>
<Picker
:data="banks"
title="请选择银行"
@pickerClose="pickerDisplay = false"
@select="pickerValueChange"
:display="pickerDisplay"/>
</div>
<div class="PhoneBlock FormLine">
<div class="labelBlock">
<span>预留手机号</span>
</div>
<v-text-field
v-model="form.phone"
color="light-gold"
class="BindCardInput "
name="PhoneInput"
placeholder="务必输入预留手机号"
id='PhoneInput'
single-line
></v-text-field>
</div>
<div class="HintLine">
注意:请您避免绑定<span>银行卡、结算卡</span>
</div>
</v-card>
<div class="ConfirmButtonBlock">
<v-btn depressed id="ConfirmButton">确 定</v-btn>
</div>
</v-flex>
</v-layout>
</template>
<script>
import {wechatShareSetting} from '@/helper'
import Picker from '@/components/Picker'
export default {
layout: 'lightGold',
data:() => ({
form: {
phone: '',
verificationCode: '',
bank: ''
},
banks: [[{ text: '招商银行' },
{ text: '建设银行' },
{ text: '工商银行' },
{ text: '农业银行' },
{ text: '中国银行' }]],
pickerDisplay: false,
}),
components: {
Picker
},
mounted() {
wechatShareSetting(this.$axios, this.$store)
},
methods: {
pickerValueChange(val, index, text) {
this.form.bank = text[0]
}
}
}
</script>
<style lang="scss" scoped>
#BindCard {
#CardInfoBlock {
width: 90vw;
margin-top: 2rem;
background: #FFFFFF;
border-radius: 2px;
padding: 0 1.3rem;
.FormLine {
height: 3.5rem;
position: relative;
.labelBlock {
line-height: 3.5rem;
height: 3.5rem;
position: absolute;
font-size: 1rem;
font-weight: bold;
}
.BindCardInput {
padding-top: 0.75rem;
}
.pickerValueBlock {
padding-top: 0.75rem;
text-align: right;
font-size: 1rem;
}
.pickerValueBlockValue {
padding-top: 0.75rem;
padding-left: 6.7rem;
font-size: 1rem;
}
}
/deep/ #NameInput {
margin-left: 6.7rem;
}
/deep/ #IdInput {
margin-left: 6.7rem;
}
/deep/ #CardNoInput {
margin-left: 6.7rem;
}
/deep/ #PhoneInput {
margin-left: 6.7rem;
}
/deep/ input#BankInput {
margin-left: 6.7rem;
}
.BankBlock {
border-bottom: 1px solid rgba(0, 0, 0, .4);
}
.HintLine {
font-size: 0.9rem;
text-align: center;
color: #9D9D9D;
span {
color: $light-gold;
}
}
::-moz-placeholder { color: #9D9D9D; }
::-webkit-input-placeholder { color:#9D9D9D; }
:-ms-input-placeholder { color:#9D9D9D; }
}
.ConfirmButtonBlock {
width: 90vw;
margin: 4.5rem auto 2.5rem auto;
#ConfirmButton {
color: #484646;
background-image: linear-gradient(-213deg, #DAB269 0%, #E7C78C 92%);
border-radius: 2px;
width: 100%;
height: 2.8rem;
font-size: 18px;
margin: auto;
}
}
}
</style>