| | |
| | | import offIcon from '@/static/imgs/icons/off.png' |
| | | import leftIcon from '@/static/imgs/icons/left.png' |
| | | import kkIcon from '@/static/imgs/icons/kk.png' |
| | | import addAddress from "./components/addAddress"; |
| | | import agreement from "./components/agreement"; |
| | | import addAddress from "@/pages/quanyi/components/addAddress"; |
| | | import agreement from "@/pages/quanyi/components/agreement"; |
| | | export default { |
| | | name: "add", |
| | | components: { |
| | |
| | | uni.request({ |
| | | url: _this.$webHost+'/api/v2/customer/getCstAddress', |
| | | data:{ |
| | | customerId: uni.getStorageSync('ygxLogin').customerId, |
| | | sourceId: uni.getStorageSync('ygxLogin').appId |
| | | customerId: uni.getStorageSync('qxgLogin').customerId, |
| | | sourceId: uni.getStorageSync('qxgLogin').appId |
| | | }, |
| | | success: function (res) { |
| | | _this.addressDetail = res.data.data; |
| | |
| | | |
| | | |
| | | uni.request({ |
| | | url: _this.$webHost+'/api/v2/xinheyuan/bank/list/fake/'+uni.getStorageSync('ygxLogin').customerId, |
| | | url: _this.$webHost+'/api/v2/xinheyuan/bank/list/fake/'+uni.getStorageSync('qxgLogin').customerId, |
| | | success(res){ |
| | | console.log(res.data.data); |
| | | this.bankList = res.data.data; |
| | |
| | | uni.setStorageSync('windowHeight',uni.getSystemInfoSync().windowHeight) |
| | | |
| | | uni.request({ |
| | | url:_this.$webHost+`/api/v2/pay/getPayBindCardInfo/${uni.getStorageSync('ygxLogin').customerId}`, |
| | | url:_this.$webHost+`/api/v2/pay/getPayBindCardInfo/${uni.getStorageSync('qxgLogin').customerId}`, |
| | | method:'get', |
| | | success:function(res){ |
| | | const dy = res.data.data[0]; |
| | |
| | | |
| | | |
| | | uni.request({ |
| | | url: _this.$webHost+'/api/v2/sign/signed/'+uni.getStorageSync('ygxLogin').customerId, |
| | | url: _this.$webHost+'/api/v2/sign/signed/'+uni.getStorageSync('qxgLogin').customerId, |
| | | method:'POST', |
| | | }) |
| | | |
| | |
| | | url: _this.$webHost+'/api/v2/pay/memberPurchaseBenefitsPays', |
| | | method:'POST', |
| | | data:{ |
| | | customerId: uni.getStorageSync('ygxLogin').customerId, |
| | | customerId: uni.getStorageSync('qxgLogin').customerId, |
| | | memberPeriodConfigId: uni.getStorageSync('memberPeriodConfigInfo').id |
| | | }, |
| | | success(){ |
| | |
| | | |
| | | |
| | | uni.request({ |
| | | url:_this.$webHost+`/api/v2/pay/getPayBindCardInfo/${uni.getStorageSync('ygxLogin').customerId}`, |
| | | url:_this.$webHost+`/api/v2/pay/getPayBindCardInfo/${uni.getStorageSync('qxgLogin').customerId}`, |
| | | method:'get', |
| | | success:function(res){ |
| | | _this.getPayBindCardInfo = res.data.data; |
| | |
| | | data:{ |
| | | ..._this.bindCardId, |
| | | |
| | | "customerId": uni.getStorageSync('ygxLogin').customerId, |
| | | "customerId": uni.getStorageSync('qxgLogin').customerId, |
| | | "cardPhone" : _this.cardPhone, //手机号 |
| | | |
| | | "cardNumber": _this.cardNumber, //卡号 |
| | |
| | | }, |
| | | success(e){ |
| | | if(e.data.code!==200){ |
| | | |
| | | uni.showTips({ |
| | | _this.$util.Tips({ |
| | | title: e.data.data |
| | | }); |
| | | } |
| | | uni.request({ |
| | | url:_this.$webHost+`/api/v2/pay/getPayBindCardInfo/${uni.getStorageSync('ygxLogin').customerId}`, |
| | | url:_this.$webHost+`/api/v2/pay/getPayBindCardInfo/${uni.getStorageSync('qxgLogin').customerId}`, |
| | | method:'get', |
| | | success:function(res){ |
| | | const ls = res.data.data; |
| | |
| | | |
| | | |
| | | |
| | | if(ls.length && !ls[1].bindStatus){ |
| | | if(ls.length>1 && !ls[1].bindStatus){ |
| | | _this.$refs.codeUi.open() |
| | | _this.isCounting = false; |
| | | _this.countText = ''; |
| | | return; |
| | | } |
| | | if(ls.length && !ls[2].bindStatus){ |
| | | if(ls.length>2 && !ls[2].bindStatus){ |
| | | _this.$refs.setUi.open(); |
| | | _this.isCounting = false; |
| | | _this.countText = ''; |
| | |
| | | if(!ls || !ls.some(item => item.bindStatus == 0)) {_this.kk();return;} |
| | | |
| | | |
| | | |
| | | _this.kk() |
| | | |
| | | |
| | | |
| | |
| | | return |
| | | } |
| | | |
| | | if (!/^1(3|4|5|7|8|9|6)\d{9}$/i.test(that.cardPhone)) return uni.showToast({title: '请输入正确的手机号码', icon: 'none'}); |
| | | if (!/^1(3|4|5|7|8|9|6)\d{9}$/i.test(that.cardPhone)) return that.$util.Tips({ |
| | | title: '请输入正确的手机号码' |
| | | }); |
| | | |
| | | |
| | | that.isCounting = true; |
| | |
| | | url: that.$webHost+'/api/v2/xinheyuan/bankcard/save', |
| | | method:'POST', |
| | | data:{ |
| | | "customerId": uni.getStorageSync('ygxLogin').customerId, |
| | | "customerId": uni.getStorageSync('qxgLogin').customerId, |
| | | "nameReal": that.cardName, // 名字 |
| | | "cardNo":that.cardNumber, |
| | | "idCard": that.idCardNo, |
| | |
| | | url: that.$webHost+'/api/v2/pay/bindCardToCodes', |
| | | method:'POST', |
| | | data:{ |
| | | "customerId": uni.getStorageSync('ygxLogin').customerId, |
| | | "customerId": uni.getStorageSync('qxgLogin').customerId, |
| | | "cardName": that.cardName, // 名字 |
| | | "cardIdNo": that.idCardNo, |
| | | |
| | |
| | | } |
| | | const paymentMethod = this.getPayBindCardInfo[1]['paymentMethod']; |
| | | const _this = this; |
| | | const pro = uni.getStorageSync('ygxLogin') |
| | | const pro = uni.getStorageSync('qxgLogin') |
| | | pro['userName'] = _this.cardName; |
| | | uni.request({ |
| | | url: _this.$webHost+'/api/v2/pay/bindCardToCodes', |
| | |
| | | data:{ |
| | | ...callbackData, |
| | | |
| | | "customerId": uni.getStorageSync('ygxLogin').customerId, |
| | | "customerId": uni.getStorageSync('qxgLogin').customerId, |
| | | "cardPhone" : _this.cardPhone, //手机号 |
| | | |
| | | "cardNumber": _this.cardNumber, //卡号 |
| | |
| | | }, |
| | | success(dts){ |
| | | if(dts.data.code!==200){ |
| | | |
| | | uni.showTips({ |
| | | title: dts.data.data |
| | | }); |
| | | return |
| | | } |
| | | |
| | | uni.request({ |
| | | url:_this.$webHost+`/api/v2/pay/getPayBindCardInfo/${uni.getStorageSync('ygxLogin').customerId}`, |
| | | url:_this.$webHost+`/api/v2/pay/getPayBindCardInfo/${uni.getStorageSync('qxgLogin').customerId}`, |
| | | method:'get', |
| | | success:function(res){ |
| | | const ls = res.data.data; |
| | |
| | | _this.countText_A = ''; |
| | | _this.$refs.codeUi.close() |
| | | _this.$refs.setUi.open() |
| | | return; |
| | | } |
| | | |
| | | if(!ls || !ls.some(item => item.bindStatus == 0)) {_this.kk();return;} |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | | |
| | |
| | | } |
| | | const paymentMethod = this.getPayBindCardInfo[2]['paymentMethod']; |
| | | const _this = this; |
| | | const pro = uni.getStorageSync('ygxLogin') |
| | | const pro = uni.getStorageSync('qxgLogin') |
| | | pro['userName'] = _this.cardName; |
| | | uni.request({ |
| | | url: _this.$webHost+'/api/v2/pay/bindCardToCodes', |
| | |
| | | data:{ |
| | | ...callbackData, |
| | | |
| | | "customerId": uni.getStorageSync('ygxLogin').customerId, |
| | | "customerId": uni.getStorageSync('qxgLogin').customerId, |
| | | "cardPhone" : _this.cardPhone, //手机号 |
| | | |
| | | "cardNumber": _this.cardNumber, //卡号 |
| | |
| | | }, |
| | | success(dts){ |
| | | if(dts.data.code!==200){ |
| | | uni.showTitle({ |
| | | _this.showToast({ |
| | | title: dts.data.data |
| | | }); |
| | | |
| | | } |
| | | |
| | | uni.request({ |
| | | url:_this.$webHost+`/api/v2/pay/getPayBindCardInfo/${uni.getStorageSync('ygxLogin').customerId}`, |
| | | url:_this.$webHost+`/api/v2/pay/getPayBindCardInfo/${uni.getStorageSync('qxgLogin').customerId}`, |
| | | method:'get', |
| | | success:function(res){ |
| | | const ls = res.data.data; |
| | |
| | | |
| | | getUserInfo() { |
| | | |
| | | const data = uni.getStorageSync('LOGING_DATA') |
| | | console.log(data); |
| | | this.$store.commit("LOGIN", { |
| | | 'token': data.token |
| | | }); |
| | | this.$store.commit('UPDATE_USERINFO', { |
| | | avatar: data.avatar, |
| | | nickname: data.nickname, |
| | | phone: data.phone |
| | | }); |
| | | this.$store.commit("SETUID", data.id) |
| | | |
| | | |
| | | uni.reLaunch({ |
| | | url: '/pages/index/index' |