Browse Source

首页推荐,期票

master
nige 3 years ago
parent
commit
a45e39aafc
  1. 2
      app.js
  2. 4
      pages/index/index.js
  3. 4
      pages/index/index.wxss
  4. 1
      pages/info/sceneProductInfo/index.js
  5. 11
      pages/order/scene/index.js
  6. 2
      pages/order/scene/index.wxml
  7. 2
      pages/user/cartlist/list.js
  8. 7
      pages/user/order/sceneOrderInfo/index.wxml

2
app.js

@ -21,7 +21,7 @@ App({
unique_key: "wechatxcx"
}).then(res => {
let data = JSON.parse(res.data);
data.isTest = data.isTest64? true : false;
data.isTest = data.isTest65? true : false;
this.globalData.configJson = data
}).then(() => {
// 获取ui配置文件

4
pages/index/index.js

@ -458,7 +458,9 @@ Page({
})
},
onReachBottom: function () {
// this.getList()
if (this.data.list.length<30) {
this.getList()
}
},
gotoDetail: function (e) {
let item = e.currentTarget.dataset.item;

4
pages/index/index.wxss

@ -473,11 +473,11 @@
}
.more-btn-text {
text-align: center;
color: #999;
color: #0b898e;
font-size: 27rpx;
width: 200rpx;
line-height: 65rpx;
border: 1px solid #999999;
border: 1px solid #0b898e;
border-radius: 33rpx;
margin: 20rpx auto;
}

1
pages/info/sceneProductInfo/index.js

@ -352,7 +352,6 @@ Page({
...sku,
...product
}
wx.navigateTo({
url: '/pages/order/scene/index',
})

11
pages/order/scene/index.js

@ -28,6 +28,7 @@ Page({
allowance_price: 0,
pIndex: 0,
flag:null,
ticket_type:1
},
/**
@ -39,7 +40,8 @@ Page({
kjId: app.globalData.kjId,
gp_id: app.globalData.gp_id || app.globalData.team_id,
prizeId: wx.getStorageSync('prizeId'),
flag:options.flag
flag:options.flag,
ticket_type:app.globalData.product.sku.ticket_type || 1
})
if (!app.globalData.product) {
util.back();
@ -198,7 +200,7 @@ Page({
// })
// return;
// }
if (!date) {
if (!date && this.data.ticket_type == 1) {
wx.showToast({
title: '请选择使用日期',
icon: 'none'
@ -265,8 +267,9 @@ Page({
if(app.globalData.list){
app.globalData.list[app.globalData.index] = this.data.product
}
app.globalData.ticketPrice += (this.data.singlePrice * this.data.productNum - (this.data.coupon?this.data.coupon.activity.money:0))/100;
if(app.globalData.list && app.globalData.list.length > app.globalData.index + 1){
app.globalData.ticketPrice += (this.data.singlePrice * this.data.productNum - (this.data.coupon?this.data.coupon.activity.money:0))/100;
console.log(app.globalData);
if(app.globalData.list.list && app.globalData.list.length > app.globalData.index + 1){
if(app.globalData.createDate){
app.globalData.createDate.product_list.push(data.product_list[0])
}else{

2
pages/order/scene/index.wxml

@ -5,7 +5,7 @@
<view class="product-title">{{product.product.title + product.isGroup==1?'(团体预约)':product.sku.sku_name}}</view>
<view class="product-price" wx:if="{{type=='museum' || type=='activity'}}">免费</view>
</view>
<date wx:if="{{isLogin && type!='activity'}}" bind:onChangeDate="changeDate" bind:onChangeTime="changeTime"
<date wx:if="{{isLogin && type!='activity' && ticket_type == 1}}" bind:onChangeDate="changeDate" bind:onChangeTime="changeTime"
product="{{product}}"></date>
<view class="box" wx:if="{{product && product.isGroup==1}}">
<view class="box-title">

2
pages/user/cartlist/list.js

@ -165,7 +165,7 @@ Page({
this.data.productType = 'post'
}
}
})
})
if (product.length == 0 && product1.length == 0) {
wx.showToast({
title: '请先选择产品',

7
pages/user/order/sceneOrderInfo/index.wxml

@ -61,10 +61,15 @@
<view class="childStatus" style="text-align: left;font-size: 30rpx; font-weight:bold;padding-bottom: 30rpx;color: #0b898e">
{{ item.state_text }}
</view>
<view class="row" wx:if="{{item.product_model == 'ticket'}}">
<view class="row" wx:if="{{item.product_model == 'ticket' && !item.order_advance.id}}">
<view>出行日期:</view>
<view>{{item.use_date}} {{ item.start_time }}-{{ item.end_time }}</view>
</view>
<view class="row" wx:if="{{item.product_model == 'ticket' && item.order_advance.id}}">
<view>使用日期:</view>
<view>{{ item.order_advance.start_time }}-{{ item.order_advance.end_time }}</view>
</view>
<view wx:if="{{item.product_model == 'ticket'}}">
<view class="box-title tflex">
<view>出行人信息</view>

Loading…
Cancel
Save