Commit eb5056fd authored by 华国豪's avatar 华国豪 🙄
parents 29784e70 44ff31fb
...@@ -118,10 +118,10 @@ Page({ ...@@ -118,10 +118,10 @@ Page({
tagID: 4, tagID: 4,
tagIndex: 0, tagIndex: 0,
}, },
// 门票跳转支付 // 签证取消订单
// 门票美食签证跳转支付
goCommonPay(e){ goCommonPay(e){
let payInfoMsg = e.currentTarget.dataset.item.payInfo; let payInfoMsg = e.currentTarget.dataset.item.payInfo;
console.log("payInfoMsg", payInfoMsg);
wx.setStorageSync('payInfoMsg', payInfoMsg) wx.setStorageSync('payInfoMsg', payInfoMsg)
wx.navigateTo({ wx.navigateTo({
url: '/pages/Pay/Pay?tagID=-1', url: '/pages/Pay/Pay?tagID=-1',
...@@ -150,8 +150,9 @@ Page({ ...@@ -150,8 +150,9 @@ Page({
} }
}) })
}, },
endPaoPao: function () { endPaoPao: function (e) {
console.log('阻止冒泡····') console.log('阻止冒泡····')
}, },
// 跳转详情页面 // 跳转详情页面
goDetails: function (e) { goDetails: function (e) {
...@@ -178,12 +179,22 @@ Page({ ...@@ -178,12 +179,22 @@ Page({
let url = 'api/b2b/user/getrecentorder', let url = 'api/b2b/user/getrecentorder',
tagID = this.data.tagID, tagID = this.data.tagID,
msg = this.data.getOrderMsg; msg = this.data.getOrderMsg;
if (tagID !== 6 && tagID !== 8 && tagID !== 4) { if (tagID !== 6 && tagID !== 8 && tagID !== 4 && tagID !== 5) {
// console.log(tagID) // console.log(tagID)
url = 'api/b2b/user/getrecentorder' url = 'api/b2b/user/getrecentorder'
} else if (tagID !== 4){ // 8美食 6门票 } else if (tagID !== 4){ // 8美食 6门票
msg.status = msg.orderState msg.status = msg.orderState;
url = tagID == 8 ? 'api/b2b/food/getFoodOrder' : 'api/b2b/scenic/getTicketCouponsOrder' if (tagID == 8){
url = 'api/b2b/food/getFoodOrder'
}
else if (tagID == 6){
url = 'api/b2b/scenic/getTicketCouponsOrder';
}
else if (tagID == 5) {
console.log("url");
url = 'api/b2b/visa/getVisaOrderList';
}
// url = tagID == 8 ? 'api/b2b/food/getFoodOrder' : 'api/b2b/scenic/getTicketCouponsOrder'
} else { } else {
msg.status = msg.orderState msg.status = msg.orderState
url = 'api/b2b/user/getAirTicketOrder' url = 'api/b2b/user/getAirTicketOrder'
...@@ -196,9 +207,14 @@ Page({ ...@@ -196,9 +207,14 @@ Page({
let arr = this.data.dataList; let arr = this.data.dataList;
let arr2 = res.pageData ? res.pageData : []; let arr2 = res.pageData ? res.pageData : [];
for (let i = 0; i < arr2.length; i++) { for (let i = 0; i < arr2.length; i++) {
if (tagID !== 6 && tagID !== 8) { if (tagID !== 6 && tagID !== 8 && tagID !== 5) {
arr2[i].day = arr2[i].createDate.replace(/-/g, '.').substring(0, 10) arr2[i].day = arr2[i].createDate.replace(/-/g, '.').substring(0, 10)
} else {
}
else if (tagID == 5) {
arr2[i].day = arr2[i].createTime.replace(/-/g, '.').substring(0, 10)
}
else {
arr2[i].day = arr2[i].useDate.replace(/-/g, '.') arr2[i].day = arr2[i].useDate.replace(/-/g, '.')
} }
} }
...@@ -208,7 +224,7 @@ Page({ ...@@ -208,7 +224,7 @@ Page({
arr.push(arr2[i]) arr.push(arr2[i])
} }
} else { } else {
arr = arr2 arr = arr2;
} }
this.setData({ this.setData({
dataList: arr, dataList: arr,
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
</view> </view>
<scroll-view class='data_body' scroll-y bindscrolltolower="scrollGetMore"> <scroll-view class='data_body' scroll-y bindscrolltolower="scrollGetMore">
({{tagID}}) ({{tagID}})
<view wx:if="{{tagID !== 6 && tagID !== 8 && tagID !== 4}}"> <view wx:if="{{tagID !== 6 && tagID !== 8 && tagID !== 4 && tagID !== 5}}">
<view class='list-item' wx:for="{{dataList}}" wx:for-item="item" wx:key="index" wx:for-index="index"> <view class='list-item' wx:for="{{dataList}}" wx:for-item="item" wx:key="index" wx:for-index="index">
<!-- <form bindsubmit="formSubmit" report-submit> <!-- <form bindsubmit="formSubmit" report-submit>
<button hover-class="btn-hover" form-type="submit" data-url="/pages/member/orderCenter/orderCenter" data-index='{{index}}'> --> <button hover-class="btn-hover" form-type="submit" data-url="/pages/member/orderCenter/orderCenter" data-index='{{index}}'> -->
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
<view class='list-item-btn'> <view class='list-item-btn'>
<view wx:if="{{item.orderState == 1}}">联系客服</view> <view wx:if="{{item.orderState == 1}}">联系客服</view>
<view wx:if="{{item.orderState == 3 || item.orderState == 2}}">取消订单</view> <view wx:if="{{item.orderState == 3 || item.orderState == 2}}">取消订单</view>
<view wx:if="{{item.orderState == 1 || item.orderState == 2}}" catchtap="endPaoPao" class='btn-red'>付款</view> <view catchtap="endPaoPao" data-item="{{item}}" wx:if="{{item.orderState == 1 || item.orderState == 2}}" class='btn-red'>付款</view>
<!-- <view class='btn-red'>确认收货</view> --> <!-- <view class='btn-red'>确认收货</view> -->
<view class='btn-red' wx:if="{{item.orderState == 5 || item.orderState == 4}}">再次购买</view> <view class='btn-red' wx:if="{{item.orderState == 5 || item.orderState == 4}}">再次购买</view>
</view> </view>
...@@ -52,6 +52,36 @@ ...@@ -52,6 +52,36 @@
</form> --> </form> -->
</view> </view>
</view> </view>
<!-- 签证 -->
<view wx:if="{{tagID == 5}}">
<view class='list-item' wx:for="{{dataList}}" wx:for-item="item" wx:key="index" wx:for-index="index">
<text class='list-item-tag {{tagList[tagBoxActive].Class}}'>{{tagList[tagBoxActive].name}}</text>
<view class='list-item-states'>
<text wx:if="{{item.visaOrderStatus == 1}}">正常</text>
<text wx:elif="{{item.visaOrderStatus == 2}}">取消</text>
<text wx:elif="{{item.visaOrderStatus == 3}}">待付款</text>
</view>
<view class='list-item-info' data-index='{{index}}' bindtap='formSubmit'>
<view class='list-item-name'>{{item.productName}}</view>
<view class='list-item-detail'>
<view class='list-item-detail-left'>
<text>{{item.guestList.length+'人'}}</text>
<text>{{item.day}}</text>
</view>
<view>¥{{item.totalPrice}}</view>
</view>
</view>
<view class='list-item-btn'>
<view wx:if="{{item.visaOrderStatus == 1}}">联系客服</view>
<view bindtap="exitVisa" data-item="{{item}}" wx:if="{{item.visaOrderStatus == 1 || item.visaOrderStatus == 3}}">取消订单</view>
<view bindtap="goCommonPay" data-item="{{item}}" wx:if="{{item.visaOrderStatus == 3}}" class='btn-red'>付款</view>
<!-- <view class='btn-red'>确认收货</view> -->
<!-- <view class='btn-red' wx:if="{{item.orderState == 5 || item.orderState == 4}}">再次购买</view> -->
</view>
<!-- </button>
</form> -->
</view>
</view>
<view wx:elif="{{tagID ==8}}"> <view wx:elif="{{tagID ==8}}">
<view class='list-item' wx:for="{{dataList}}" wx:for-item="item" wx:key="index" wx:for-index="index"> <view class='list-item' wx:for="{{dataList}}" wx:for-item="item" wx:key="index" wx:for-index="index">
<!-- <form bindsubmit="formSubmit" report-submit> <!-- <form bindsubmit="formSubmit" report-submit>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment