Commit 27f19e38 by 林翔

Merge branch 'lx_wallet_20190423' of http://119.23.72.7/liangjianmin/h5 into lx_wallet_20190423

# Conflicts:
#	view/1.js
#	view/24.js
#	view/26.js
#	view/27.js
#	view/app.js
parents 96488664 757a96bf
...@@ -654,7 +654,7 @@ ...@@ -654,7 +654,7 @@
background: #1080d0; background: #1080d0;
color: #ffffff; color: #ffffff;
font-size: 16px; font-size: 16px;
z-index: 999999999999; z-index: 999;
transition: all 0.2s ease; transition: all 0.2s ease;
} }
......
...@@ -340,13 +340,13 @@ const actions = { ...@@ -340,13 +340,13 @@ const actions = {
type: 'walletListLog', type: 'walletListLog',
data: data.data.list data: data.data.list
}); });
Toast.clear();
} else { } else {
Toast({ Toast({
message: data.err_msg, message: data.err_msg,
duration: 3000 duration: 3000
}); });
} }
Toast.clear();
}).catch(function (err) { }).catch(function (err) {
Toast.clear(); Toast.clear();
}); });
...@@ -367,13 +367,13 @@ const actions = { ...@@ -367,13 +367,13 @@ const actions = {
type: 'walletRecordList', type: 'walletRecordList',
data: data.data.list data: data.data.list
}); });
Toast.clear();
} else { } else {
Toast({ Toast({
message: data.err_msg, message: data.err_msg,
duration: 3000 duration: 3000
}); });
} }
Toast.clear();
}).catch(function (err) { }).catch(function (err) {
Toast.clear(); Toast.clear();
}); });
......
...@@ -24,16 +24,14 @@ ...@@ -24,16 +24,14 @@
</template> </template>
<template v-else> <template v-else>
<li class="no-data"> <li class="no-data">
<p style="color: #333;width: 80%;margin: 0 auto;font-size: 13px;margin-top: 28px;">您的钱包当前还没有记录哦,去看看商品吧~ <a style="color: #1080d0;" href="/v3/s">去搜索</a></p> <i class="iconfont icon-zanwushuju" style="color: #999;margin: 0 auto;display: block;text-align: center;font-size: 90px;padding-top: 60px;"></i>
</li> <p style="color: #333;width: 80%;margin: 0 auto;font-size: 13px;margin-top: 28px;">您的钱包当前还没有记录哦,去看看商品吧~ <a style="color: #1080d0;" href="/v3/s">去搜索</a></p> </li>
</template> </template>
</ul> </ul>
<van-popup v-model="dateShow" position="bottom" :overlay="true"> <van-popup v-model="dateShow" position="bottom" :overlay="true">
<van-datetime-picker v-model="currentDate" type="year-month" :formatter="formatter" @cancel="onDateCancel" @confirm="onDateConfirm" @change="dateChange"/> <van-datetime-picker v-model="currentDate" type="year-month" :formatter="formatter" @cancel="onDateCancel" @confirm="onDateConfirm" @change="dateChange"/>
</van-popup> </van-popup>
<van-popup v-model="typeShow" position="bottom" :overlay="true">
<van-picker show-toolbar title="交易类型" :columns="columns" @cancel="onTypeCancel" @confirm="onTypeConfirm"/>
</van-popup>
</div> </div>
<!--记录类型弹出框--> <!--记录类型弹出框-->
<div class="dialog-layer-shade" v-if="dialog"> <div class="dialog-layer-shade" v-if="dialog">
...@@ -209,15 +207,13 @@ ...@@ -209,15 +207,13 @@
}) })
}, },
onTypeConfirm(value, index) { onTypeConfirm(value, index) {
this.dialog = false; this.dialog = false;
this.active=index; this.active=index;
this.text=this.columns[index].text; this.text=this.columns[index].text;
this.typeCheckedkeyId = value.keyId; this.typeCheckedkeyId = value;
this.typeCheckedText = value.text;
this.recordYear = this.updateYear || this.recordYear; this.recordYear = this.updateYear || this.recordYear;
this.recordMonth = this.updateMonth || this.recordMonth; this.recordMonth = this.updateMonth || this.recordMonth;
......
...@@ -214,8 +214,7 @@ ...@@ -214,8 +214,7 @@
this.active=index; this.active=index;
this.text=this.columns[index].text; this.text=this.columns[index].text;
this.typeCheckedkeyId = value.keyId; this.typeCheckedkeyId = value;
this.typeCheckedText = value.text;
this.dateYear = this.updateYear || this.dateYear; this.dateYear = this.updateYear || this.dateYear;
this.dateMonth = this.updateMonth || this.dateMonth; this.dateMonth = this.updateMonth || this.dateMonth;
......
...@@ -13,17 +13,17 @@ ...@@ -13,17 +13,17 @@
</p> </p>
<div class="withdraw-amount"> <div class="withdraw-amount">
<p><em>*</em> 提现金额</p> <p><em>*</em> 提现金额</p>
<span></span><input type="number" class="money" v-model="withdrawNum"/> <span></span><input type="text" readonly="readonly" @touchstart.stop="moneyBtn = true" class="money" v-model="withdrawNum"/>
<div v-if="amountNum" class="withdraw-money">可提现金额 {{walletInfoData.wallet_usable_format}}<span @click="withdraw">全部提现</span></div> <div v-if="amountNum" class="withdraw-money">可提现金额 {{walletInfoData.wallet_usable_format}}<span @click="withdraw">全部提现</span></div>
<div v-else class="amount-tips">输入金额超过可提现金额</div> <div v-else class="amount-tips">输入金额超过可提现金额</div>
</div> </div>
<div class="withdraw-password"> <div class="withdraw-password">
<p><em>*</em> 支付密码</p> <p><em>*</em> 支付密码</p>
<template v-if="showPassword"> <template v-if="showPassword">
<input type="password" placeholder="请输入支付密码" class="va-m inp password" v-model="password"/> <input type="password" readonly="readonly" @touchstart.stop="passwdBtn = true" placeholder="请输入支付密码" class="va-m inp password" v-model="password"/>
</template> </template>
<template v-else> <template v-else>
<input type="text" placeholder="请输入支付密码" class="va-m inp password" v-model="password"/> <input type="text" readonly="readonly" @touchstart.stop="passwdBtn = true" placeholder="请输入支付密码" class="va-m inp password" v-model="password"/>
</template> </template>
<van-icon v-if="showPassword" name="closed-eye" class="va-m f-r" @click="changeShow"/> <van-icon v-if="showPassword" name="closed-eye" class="va-m f-r" @click="changeShow"/>
<van-icon v-else name="eye-o" class="va-m f-r" @click="changeShow"/> <van-icon v-else name="eye-o" class="va-m f-r" @click="changeShow"/>
...@@ -31,6 +31,9 @@ ...@@ -31,6 +31,9 @@
<button :disabled="amountWithdrawFlag" class="submit" :class="withdrawNum == '' || amountWithdrawFlag ? 'submitNO' : ''" @click="submit">提交</button> <button :disabled="amountWithdrawFlag" class="submit" :class="withdrawNum == '' || amountWithdrawFlag ? 'submitNO' : ''" @click="submit">提交</button>
</div> </div>
<van-number-keyboard :show="moneyBtn" theme="custom" extra-key="." close-button-text="完成" @blur="moneyBtn = false;passwdBtn=false;" @input="onInput" @delete="onDelete" :zIndex="zIndex"/>
<van-number-keyboard :show="passwdBtn" theme="custom" extra-key="." close-button-text="完成" @blur="passwdBtn = false;passwdBtn=false;" @input="onInputPwd" @delete="onDeletePwd" :zIndex="zIndex"/>
</section> </section>
</template> </template>
...@@ -38,9 +41,9 @@ ...@@ -38,9 +41,9 @@
import Vue from 'vue'; import Vue from 'vue';
import {mapState} from 'vuex' import {mapState} from 'vuex'
import Header from '@/views/common/Header.vue'; import Header from '@/views/common/Header.vue';
import {Icon, Toast} from 'vant'; import {Icon, Toast, NumberKeyboard} from 'vant';
Vue.use(Icon); Vue.use(Icon).use(NumberKeyboard);
export default { export default {
name: 'walletWithdraw', name: 'walletWithdraw',
...@@ -52,7 +55,10 @@ ...@@ -52,7 +55,10 @@
amountNum: true, amountNum: true,
password: '', password: '',
withdrawNum: '', withdrawNum: '',
clickFlag: true clickFlag: true,
moneyBtn: false,
passwdBtn:false,
zIndex: 999999
} }
}, },
computed: { computed: {
...@@ -63,8 +69,8 @@ ...@@ -63,8 +69,8 @@
}, },
watch: { watch: {
withdrawNum: function (val) { withdrawNum: function (val) {
if (val > this.walletInfoData.wallet_usable) { if (Number(val) > Number(this.walletInfoData.wallet_usable)) {
this.amountNum = !this.amountNum; this.amountNum = false;
} else { } else {
this.amountNum = true; this.amountNum = true;
} }
...@@ -98,6 +104,18 @@ ...@@ -98,6 +104,18 @@
}); });
} }
} }
},
onInput(key) {
this.withdrawNum = (this.withdrawNum + key);
},
onDelete(key) {
this.withdrawNum = this.withdrawNum.slice(0, this.withdrawNum.length - 1);
},
onInputPwd(key){
this.password = (this.password + key);
},
onDeletePwd(key){
this.password = this.password.slice(0, this.password.length - 1);
} }
}, },
components: { components: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment