|
|
@ -26,7 +26,6 @@ Page({ |
|
|
* 生命周期函数--监听页面加载 |
|
|
* 生命周期函数--监听页面加载 |
|
|
*/ |
|
|
*/ |
|
|
onLoad: function (options) { |
|
|
onLoad: function (options) { |
|
|
console.log(JSON.parse(options)); |
|
|
|
|
|
app.globalData.couponInfo = null |
|
|
app.globalData.couponInfo = null |
|
|
this.setData({ |
|
|
this.setData({ |
|
|
coupon:app.globalData.couponInfo |
|
|
coupon:app.globalData.couponInfo |
|
|
@ -36,12 +35,11 @@ Page({ |
|
|
}) |
|
|
}) |
|
|
let product = app.globalData.product,price=0,num=0,sPrice=0; |
|
|
let product = app.globalData.product,price=0,num=0,sPrice=0; |
|
|
product.info.selectSeatInfo = JSON.parse(options.selectSeatInfo) |
|
|
product.info.selectSeatInfo = JSON.parse(options.selectSeatInfo) |
|
|
product.info.selectSeatInfo.seatPriceInfo.map(item=>{ |
|
|
product.info.selectSeatInfo.price.map(item=>{ |
|
|
price =price +Math.ceil(Number(item.split('-')[1])*1.006 * 100) / 100 |
|
|
price =price +Math.ceil(Number(item)*1.006 * 100) / 100 |
|
|
num = num + 1 |
|
|
num = num + 1 |
|
|
sPrice = Math.ceil(Number(item.split('-')[1])*1.006 * 100) / 100 |
|
|
sPrice = Math.ceil(Number(item)*1.006 * 100) / 100 |
|
|
}) |
|
|
}) |
|
|
console.log(price*100); |
|
|
|
|
|
|
|
|
|
|
|
this.setData({ |
|
|
this.setData({ |
|
|
product:product, |
|
|
product:product, |
|
|
@ -49,7 +47,6 @@ Page({ |
|
|
num:num, |
|
|
num:num, |
|
|
sPrice:sPrice |
|
|
sPrice:sPrice |
|
|
}) |
|
|
}) |
|
|
console.log(this.data.price); |
|
|
|
|
|
userApi.user_post("user/getMyInfo").then(res=>{ |
|
|
userApi.user_post("user/getMyInfo").then(res=>{ |
|
|
this.setData({ |
|
|
this.setData({ |
|
|
tel:res.data.mobile |
|
|
tel:res.data.mobile |
|
|
@ -105,7 +102,8 @@ Page({ |
|
|
"seats_list": product.info.selectSeatInfo.seatInfo.join(","),//座位中文名称,多个座位逗号分隔,必填
|
|
|
"seats_list": product.info.selectSeatInfo.seatInfo.join(","),//座位中文名称,多个座位逗号分隔,必填
|
|
|
// "key": this.data.key,//锁座返回的key,必填
|
|
|
// "key": this.data.key,//锁座返回的key,必填
|
|
|
"schedules_id": product.info.schedule_id,//淘票票场次id,必填
|
|
|
"schedules_id": product.info.schedule_id,//淘票票场次id,必填
|
|
|
"seats_ids": product.info.selectSeatInfo.seatPriceInfo |
|
|
"seats_ids": product.info.selectSeatInfo.seatPriceInfo, |
|
|
|
|
|
"seatnames": product.info.selectSeatInfo.seatInfo.join("|") |
|
|
}]; |
|
|
}]; |
|
|
let data = { |
|
|
let data = { |
|
|
product_list:product_list, |
|
|
product_list:product_list, |
|
|
|