|
|
@ -55,12 +55,6 @@ Page({ |
|
|
activityNo: options.activityNo == undefined ? "" : options.activityNo, |
|
|
activityNo: options.activityNo == undefined ? "" : options.activityNo, |
|
|
groupNo: options.groupNo == undefined ? "" : options.groupNo, |
|
|
groupNo: options.groupNo == undefined ? "" : options.groupNo, |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
}, |
|
|
|
|
|
/** |
|
|
|
|
|
* 生命周期函数--监听页面初次渲染完成 |
|
|
|
|
|
*/ |
|
|
|
|
|
onReady: function () { |
|
|
|
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
@ -81,7 +75,7 @@ Page({ |
|
|
} else { |
|
|
} else { |
|
|
url = "/mall/wxa/activity/detail"; |
|
|
url = "/mall/wxa/activity/detail"; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
console.log('msg>>>' + that.data.activityNo + ',' + that.data.groupNo); |
|
|
wx.request({ |
|
|
wx.request({ |
|
|
url: app.gw.hostUrl + url, |
|
|
url: app.gw.hostUrl + url, |
|
|
method: 'get', |
|
|
method: 'get', |
|
|
@ -94,11 +88,11 @@ Page({ |
|
|
'sessionId': wx.getStorageSync('sessionId') |
|
|
'sessionId': wx.getStorageSync('sessionId') |
|
|
}, |
|
|
}, |
|
|
success: function (res) { |
|
|
success: function (res) { |
|
|
|
|
|
console.log(res); |
|
|
var data = res.data; |
|
|
var data = res.data; |
|
|
var status = data.code; |
|
|
var status = data.code; |
|
|
console.log(res); |
|
|
console.log(res); |
|
|
if (status == 0) { |
|
|
if (status == 0) { |
|
|
|
|
|
|
|
|
that.setData({ |
|
|
that.setData({ |
|
|
activityDetail: data.response, |
|
|
activityDetail: data.response, |
|
|
activityNo: data.response.activityNo, |
|
|
activityNo: data.response.activityNo, |
|
|
@ -110,7 +104,6 @@ Page({ |
|
|
}); |
|
|
}); |
|
|
let activityContent = data.response.activityContent; |
|
|
let activityContent = data.response.activityContent; |
|
|
WxParse.wxParse('activityContent', 'html', activityContent, that); |
|
|
WxParse.wxParse('activityContent', 'html', activityContent, that); |
|
|
console.log("currentMemberType:" + data.response.currentMemberType + "&&status:" + that.data.groupStatus + "&&groupNo" + that.data.groupNo); |
|
|
|
|
|
//根据状态切换样式
|
|
|
//根据状态切换样式
|
|
|
if (that.data.groupNo !=""){ |
|
|
if (that.data.groupNo !=""){ |
|
|
//开团后页面变化
|
|
|
//开团后页面变化
|
|
|
@ -292,7 +285,6 @@ Page({ |
|
|
groupTap: function (e) { |
|
|
groupTap: function (e) { |
|
|
let that = this; |
|
|
let that = this; |
|
|
var url = ""; |
|
|
var url = ""; |
|
|
console.log("groupNo:" + that.data.groupNo + "¤tMemberType:" + that.data.currentMemberType + "&groupStatus:" + that.data.groupStatus); |
|
|
|
|
|
if (that.data.groupNo == ""){ |
|
|
if (that.data.groupNo == ""){ |
|
|
url = '/mall/wxa/activity/group/open'; |
|
|
url = '/mall/wxa/activity/group/open'; |
|
|
//首次开团
|
|
|
//首次开团
|
|
|
@ -387,9 +379,9 @@ Page({ |
|
|
icon: 'success', |
|
|
icon: 'success', |
|
|
duration: 2000 |
|
|
duration: 2000 |
|
|
}) |
|
|
}) |
|
|
var json = JSON.stringify(that.data.activityDetail); |
|
|
|
|
|
|
|
|
console.log(that.data.activityDetail) |
|
|
wx.navigateTo({ |
|
|
wx.navigateTo({ |
|
|
url: '../pay_result/pay_result?json=' + json |
|
|
|
|
|
|
|
|
url: '../pay_result/pay_result?activityNo=' + that.data.activityNo + '&groupNo=' + that.data.groupNo + '&shareTitle=' + that.data.activityDetail.shareTitle + '&sharePhoto=' + that.data.activityDetail.sharePhoto |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
"fail": function (res) { |
|
|
"fail": function (res) { |
|
|
@ -412,7 +404,7 @@ Page({ |
|
|
}, |
|
|
}, |
|
|
fail: function (e) { |
|
|
fail: function (e) { |
|
|
wx.showToast({ |
|
|
wx.showToast({ |
|
|
title: '网络异常!err:authlogin', |
|
|
|
|
|
|
|
|
title: '网络异常!', |
|
|
icon: 'none', |
|
|
icon: 'none', |
|
|
duration: 2000 |
|
|
duration: 2000 |
|
|
}) |
|
|
}) |
|
|
|