@@ -70,6 +70,9 @@ Page({ | |||||
* 跳转到门店列表的详情页面 | * 跳转到门店列表的详情页面 | ||||
*/ | */ | ||||
gotoDetail(e) { | gotoDetail(e) { | ||||
if (e.currentTarget.dataset.id == undefined) { | |||||
return | |||||
} | |||||
wx.navigateTo({ | wx.navigateTo({ | ||||
url: `/pages/index/searchbar/detail/index?id=${e.currentTarget.dataset.id}` | url: `/pages/index/searchbar/detail/index?id=${e.currentTarget.dataset.id}` | ||||
}) | }) | ||||
@@ -128,9 +131,12 @@ Page({ | |||||
}, | }, | ||||
onLoad(options) { | onLoad(options) { | ||||
let that = this; | let that = this; | ||||
console.log(options.cardId) | |||||
that.cardpayList(options.cardId); | |||||
that.cardDetail(options.cardId); | |||||
if (options.cardId){ | |||||
that.cardpayList(options.cardId); | |||||
that.cardDetail(options.cardId); | |||||
} | |||||
if (options.from){ | if (options.from){ | ||||
this.setData({ | this.setData({ | ||||
showIndexReuturn:true | showIndexReuturn:true | ||||
@@ -117,9 +117,11 @@ Page({ | |||||
}, | }, | ||||
// 跳转到详情 | // 跳转到详情 | ||||
gotoConsumeDetail: function(e) { | gotoConsumeDetail: function(e) { | ||||
wx.navigateTo({ | |||||
url: `/pages/ConsumeDetail/ConsumeDetail?cardId=${e.currentTarget.dataset.id}`, | |||||
}) | |||||
if (e.currentTarget.dataset.id){ | |||||
wx.navigateTo({ | |||||
url: `/pages/ConsumeDetail/ConsumeDetail?cardId=${e.currentTarget.dataset.id}`, | |||||
}) | |||||
} | |||||
}, | }, | ||||
//点击跳转到券详情页面 | //点击跳转到券详情页面 | ||||
gotouse: function(e) { | gotouse: function(e) { | ||||
@@ -128,10 +130,12 @@ Page({ | |||||
} else { | } else { | ||||
var mystatus = this.data.mystatus; | var mystatus = this.data.mystatus; | ||||
} | } | ||||
wx.navigateTo({ | |||||
url: `/pages/couponorder/detail/index?quancode=${ | |||||
e.currentTarget.dataset.quancode}&couponorderstatus=${mystatus}` | |||||
}); | |||||
if (e.currentTarget.dataset.quancode) { | |||||
wx.navigateTo({ | |||||
url: `/pages/couponorder/detail/index?quancode=${ | |||||
e.currentTarget.dataset.quancode}&couponorderstatus=${mystatus}` | |||||
}); | |||||
} | |||||
}, | }, | ||||
gotoBuy: function() { | gotoBuy: function() { | ||||
wx.navigateTo({ | wx.navigateTo({ | ||||
@@ -36,6 +36,10 @@ Page({ | |||||
frommd: options.frommd | frommd: options.frommd | ||||
}) | }) | ||||
} | } | ||||
// that.setData({ | |||||
// optionData: null | |||||
// }) | |||||
console.log(wx.getStorageSync('options'),6666) | |||||
that.setData({ | that.setData({ | ||||
optionData: wx.getStorageSync('options') ? JSON.parse(wx.getStorageSync('options')):null | optionData: wx.getStorageSync('options') ? JSON.parse(wx.getStorageSync('options')):null | ||||
}) | }) | ||||
@@ -173,7 +173,7 @@ Page({ | |||||
} | } | ||||
} | } | ||||
// 拼团详情页(只有通过扫码进入才可能进入拼团详情页面,只有这一个入口) | // 拼团详情页(只有通过扫码进入才可能进入拼团详情页面,只有这一个入口) | ||||
else if (options && options.couponChannelId && app.globalData.type == 'sd' || options && options.couponChannelId && options.spellGroup) { | |||||
else if ((options && options.couponChannelId && app.globalData.type == 'sd') || (options && options.couponChannelId && options.spellGroup) ){ | |||||
wx.redirectTo({ | wx.redirectTo({ | ||||
url: `/pages/spellGroup/mySpellGroup/index?couponChannelId=${options.couponChannelId}`, | url: `/pages/spellGroup/mySpellGroup/index?couponChannelId=${options.couponChannelId}`, | ||||
}) | }) | ||||
@@ -181,11 +181,6 @@ Page({ | |||||
/** | /** | ||||
* 获取多商铺列表 | * 获取多商铺列表 | ||||
*/ | */ | ||||
// shopList: function(e) { | |||||
// wx.navigateTo({ | |||||
// url: `/pages/index/merchantList/index?id=${e.currentTarget.dataset.id}` | |||||
// }) | |||||
// }, | |||||
onShareAppMessage: function(res) { | onShareAppMessage: function(res) { | ||||
let that = this; | let that = this; | ||||
let shareObj = { | let shareObj = { | ||||
@@ -13,7 +13,7 @@ Page({ | |||||
erweima: imgurl.erweima.url, | erweima: imgurl.erweima.url, | ||||
bannerUrl: imgurl.banner.url, | bannerUrl: imgurl.banner.url, | ||||
loadingUrl: imgurl.loading.url, | loadingUrl: imgurl.loading.url, | ||||
nodata: imgurl.nodata.url, | |||||
nodata: imgurl.noCoupon.url, | |||||
wmhome: imgurl.wmhome.url, | wmhome: imgurl.wmhome.url, | ||||
barcode: imgurl.barcode.url, | barcode: imgurl.barcode.url, | ||||
list: [], | list: [], | ||||
@@ -8,16 +8,18 @@ | |||||
<open-data class="open" type="userAvatarUrl"></open-data> | <open-data class="open" type="userAvatarUrl"></open-data> | ||||
</view> | </view> | ||||
</view> | </view> | ||||
<view class='myName'> | |||||
<open-data class="name" type="userNickName"></open-data> | |||||
<view class=' usre_level'> | |||||
<text class='chengzhang '>{{levelName}}</text> | |||||
<view class='bot'> | |||||
<view class='myName'> | |||||
<open-data class="name" type="userNickName"></open-data> | |||||
<view class=' usre_level'> | |||||
<text class='chengzhang '>{{levelName}}</text> | |||||
</view> | |||||
</view> | </view> | ||||
<view class="view"> | <view class="view"> | ||||
<progress percent="{{upgradePercent}}" stroke-width="6" activeColor="#FFB287" /> | <progress percent="{{upgradePercent}}" stroke-width="6" activeColor="#FFB287" /> | ||||
<view class='msg'>还需{{upgradeScore}}成长值升级</view> | |||||
</view> | </view> | ||||
</view> | </view> | ||||
<view class='msg'>还需{{upgradeScore}}成长值升级</view> | |||||
</view> | </view> | ||||
<view class='topbg-btom' mode='widthFix'> | <view class='topbg-btom' mode='widthFix'> | ||||
<view class='btoml'bindtap='gotojifen'> | <view class='btoml'bindtap='gotojifen'> | ||||
@@ -62,15 +62,19 @@ | |||||
.myName{ | .myName{ | ||||
float: left; | float: left; | ||||
font-size: 32rpx; | font-size: 32rpx; | ||||
height: 100%; | |||||
width:35%; | |||||
margin-top:36rpx; | margin-top:36rpx; | ||||
} | } | ||||
.bot{ | |||||
display: flex; | |||||
flex-direction: column; | |||||
} | |||||
.view{ | .view{ | ||||
height: 40rpx; | |||||
display: block; | display: block; | ||||
margin: 60rpx 0 0 20rpx; | |||||
} | } | ||||
progress{ | progress{ | ||||
margin: 14rpx 8rpx 0 20rpx; | |||||
float: left; | |||||
width:230rpx; | width:230rpx; | ||||
border-radius:60rpx; | border-radius:60rpx; | ||||
overflow:hidden; | overflow:hidden; | ||||
@@ -81,7 +85,6 @@ progress{ | |||||
font-family:PingFangSC-Regular; | font-family:PingFangSC-Regular; | ||||
font-weight:400; | font-weight:400; | ||||
color:rgba(255,255,255,1); | color:rgba(255,255,255,1); | ||||
margin-top: 84rpx; | |||||
} | } | ||||
.btoml{ | .btoml{ | ||||
float: left; | float: left; | ||||
@@ -75,6 +75,9 @@ Page({ | |||||
// }, | // }, | ||||
getList(key, pageNum) { | getList(key, pageNum) { | ||||
let that = this; | let that = this; | ||||
if (key == undefined) { | |||||
key = 'all' | |||||
} | |||||
/** | /** | ||||
* key==0 | * key==0 | ||||
* 不发送该字段 | * 不发送该字段 | ||||
@@ -55,7 +55,7 @@ Page({ | |||||
onLoad: function(options) { | onLoad: function(options) { | ||||
this.setData({ | this.setData({ | ||||
couponChannelId: options.couponChannelId, | couponChannelId: options.couponChannelId, | ||||
couponId: options.couponId | |||||
couponId: options.couponId ? options.couponId:'' | |||||
}) | }) | ||||
if (options && options.couponChannelId) { | if (options && options.couponChannelId) { | ||||
this.getDetail(options.couponChannelId); | this.getDetail(options.couponChannelId); | ||||
@@ -63,6 +63,7 @@ Page({ | |||||
if (options && options.couponId) { | if (options && options.couponId) { | ||||
this.getOneSpell(options.couponId) | this.getOneSpell(options.couponId) | ||||
} | } | ||||
console.log(this.data.couponId) | |||||
this.getUserInfo(); | this.getUserInfo(); | ||||
}, | }, | ||||
/** | /** | ||||
@@ -607,14 +608,12 @@ Page({ | |||||
* | * | ||||
*/ | */ | ||||
wx.redirectTo({ | wx.redirectTo({ | ||||
url: "/pages/getphoneInfo/index?path=spell&couponChannelId=" + | |||||
that.data.couponChannelId + '&couponId=' + that.data.couponId | |||||
url: `/pages/getphoneInfo/index?path=spell&couponChannelId=${that.data.couponChannelId}&couponId=${that.data.data.couponId}` | |||||
}); | }); | ||||
} else if (err.code == 11006) { | } else if (err.code == 11006) { | ||||
// 用户手机已加密 | // 用户手机已加密 | ||||
wx.redirectTo({ | wx.redirectTo({ | ||||
url: "/pages/phoneinput/phoneinput?path=spell&couponChannelId=" + | |||||
that.data.couponChannelId + '&couponId=' + that.data.couponId | |||||
url: `/pages/phoneinput/phoneinput?path=spell&couponChannelId=${that.data.couponChannelId}&couponId=${that.data.data.couponId}` | |||||
}); | }); | ||||
} else { | } else { | ||||
wx.showToast({ | wx.showToast({ | ||||
@@ -739,6 +738,7 @@ Page({ | |||||
*/ | */ | ||||
onPullDownRefresh: function(e) { | onPullDownRefresh: function(e) { | ||||
let that = this; | let that = this; | ||||
console.log(this.data.couponId,222) | |||||
that.getDetail(that.data.couponChannelId); | that.getDetail(that.data.couponChannelId); | ||||
if (that.data.couponId) { | if (that.data.couponId) { | ||||
that.getOneSpell(that.data.couponId) | that.getOneSpell(that.data.couponId) | ||||
@@ -749,7 +749,7 @@ Page({ | |||||
var that = this; | var that = this; | ||||
var shareObj = { | var shareObj = { | ||||
title: that.data.data.title, | title: that.data.data.title, | ||||
path: `/pages/index/index?couponChannelId=${that.data.couponChannelId}&spellGroup=spellGroup`, | |||||
path: `/pages/index/index?couponChannelId=${that.data.couponChannelId}&couponId=${that.data.data.couponId}&spellGroup=spellGroup`, | |||||
success: function (res) { | success: function (res) { | ||||
if (res.errMsg == 'shareAppMessage:ok') { } | if (res.errMsg == 'shareAppMessage:ok') { } | ||||
}, | }, | ||||
@@ -760,7 +760,7 @@ Page({ | |||||
// 来自页面内的按钮的转发 | // 来自页面内的按钮的转发 | ||||
if (options.from == 'button') { | if (options.from == 'button') { | ||||
var eData = options.target.dataset.id; | var eData = options.target.dataset.id; | ||||
shareObj.path = `/pages/index/index?couponChannelId=${eData}&spellGroup=spellGroup&frommd=JC`; | |||||
shareObj.path = `/pages/index/index?couponChannelId=${eData}&couponId=${that.data.data.couponId}&spellGroup=spellGroup&frommd=JC`; | |||||
} | } | ||||
// 返回shareObj | // 返回shareObj | ||||
return shareObj; | return shareObj; | ||||
@@ -109,7 +109,7 @@ Page({ | |||||
*/ | */ | ||||
payOrderUpdate: (orderId, payOrderId, status, reason, _this, orderGroupId) => { | payOrderUpdate: (orderId, payOrderId, status, reason, _this, orderGroupId) => { | ||||
console.log(orderGroupId,7777) | console.log(orderGroupId,7777) | ||||
let that = this; | |||||
let that = _this; | |||||
// 支付成功 | // 支付成功 | ||||
Http.post({ | Http.post({ | ||||
url: config.api.payOrderUpdate, | url: config.api.payOrderUpdate, | ||||