|
@@ -51,20 +51,6 @@ Page({
|
|
|
title: '',
|
|
|
status: false
|
|
|
},
|
|
|
- stepList:[
|
|
|
- {
|
|
|
- name:"下单时间",
|
|
|
- status:"0"
|
|
|
- },
|
|
|
- {
|
|
|
- name:"支付时间",
|
|
|
- status:"0"
|
|
|
- },
|
|
|
- {
|
|
|
- name:"降锁时间",
|
|
|
- status:"1"//status步骤条状态。=1表示最后一条渲染不同样式
|
|
|
- }
|
|
|
- ]
|
|
|
},
|
|
|
|
|
|
/**
|
|
@@ -78,7 +64,6 @@ Page({
|
|
|
setPhone: getMobileCache(),
|
|
|
mobile: getMobileCache(),
|
|
|
})
|
|
|
- this.step = this.selectComponent("#step");
|
|
|
},
|
|
|
|
|
|
/**
|
|
@@ -93,9 +78,31 @@ Page({
|
|
|
*/
|
|
|
onShow: function () {
|
|
|
this.getBannerList()
|
|
|
- this.getCouponList()
|
|
|
if(getMobileCache() != ''){
|
|
|
- this.getphoneClick()
|
|
|
+ Integralinfo.getBalance({
|
|
|
+ mobile: '13816922995',
|
|
|
+ callbackUrl: '../integral/integral.wxml',
|
|
|
+ fingerprint: '',
|
|
|
+ sessionid: '',
|
|
|
+ shopid: 2,
|
|
|
+ type: 'wx',
|
|
|
+ }).then(arr => {
|
|
|
+ if (arr.code === '0000') {
|
|
|
+ var reg = /^(\d{3})\d{4}(\d{4})$/;
|
|
|
+ this.setData({
|
|
|
+ isLogin: getMobileCache() != '',
|
|
|
+ phone: getMobileCache() == ''?'********':getMobileCache().replace(reg, "$1****$2"),
|
|
|
+ setPhone: getMobileCache(),
|
|
|
+ mobile: getMobileCache(),
|
|
|
+ integralNum: arr.data,
|
|
|
+ })
|
|
|
+ // 获取优惠券列表
|
|
|
+ this.getCouponList()
|
|
|
+ }
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ // 获取优惠券列表
|
|
|
+ this.getCouponList()
|
|
|
}
|
|
|
},
|
|
|
|
|
@@ -171,6 +178,7 @@ couponListView: function(data) {
|
|
|
v.quantity = 0
|
|
|
v.integral = v.price * v.ratio
|
|
|
})
|
|
|
+ if (this.data.mobile != '********') {
|
|
|
let num = this.data.integralNum > 20000 ? 19999 : this.data.integralNum
|
|
|
const arr = []
|
|
|
for (let i = 0; i < data.length; i++) {
|
|
@@ -189,7 +197,12 @@ couponListView: function(data) {
|
|
|
this.setData({
|
|
|
couponList: [...arr, ...data]
|
|
|
})
|
|
|
- console.log(this.data.couponList)
|
|
|
+ } else {
|
|
|
+ this.setData({
|
|
|
+ couponList: data
|
|
|
+ })
|
|
|
+ }
|
|
|
+ console.log(this.data.total)
|
|
|
},
|
|
|
// 点击标识点触发
|
|
|
detailsClick(row) {
|