Browse Source

商品推荐, 无库存状态

master
caichunsheng 3 years ago
parent
commit
5311e594aa
  1. 78
      pages/component/proRec/proRec.js
  2. 4
      pages/component/proRec/proRec.json
  3. 17
      pages/component/proRec/proRec.wxml
  4. 53
      pages/component/proRec/proRec.wxss
  5. 3
      pages/info/sceneProductInfo/index.js
  6. 8
      pages/info/sceneProductInfo/index.wxml
  7. 287
      pages/user/cartlist/list.js
  8. 12
      pages/user/cartlist/list.wxml
  9. 17
      pages/user/cartlist/list.wxss
  10. 4
      pages/user/order/hotelOrderInfo/index.json
  11. 1
      pages/user/order/hotelOrderInfo/index.wxml
  12. 1
      pages/user/order/hotelOrderInfo/index.wxss
  13. 3
      pages/user/order/lineOrderInfo/index.json
  14. 3
      pages/user/order/lineOrderInfo/index.wxml
  15. 4
      pages/user/order/museumOrderInfo/index.json
  16. 2
      pages/user/order/museumOrderInfo/index.wxml
  17. 3
      pages/user/order/postOrderInfo/index.json
  18. 18
      pages/user/order/postOrderInfo/index.wxml
  19. 4
      pages/user/order/sceneOrderInfo/index.json
  20. 4
      pages/user/order/sceneOrderInfo/index.wxml

78
pages/component/proRec/proRec.js

@ -0,0 +1,78 @@
// pages/component/TitleHeader.js
import commonApi from "../../../utils/https/common.js"
import util from '../../../utils/util'
var app = getApp()
Component({
options: {
styleIsolation: 'apply-shared',
addGlobalClass: true
},
/**
* 组件的属性列表
*/
properties: {
title: {
type: String,
value: ""
},
transparent: {
type: String,
value: "0"
},
clickid: {
type: String,
value: ""
}
},
lifetimes: {
created() {
commonApi._post("product/get_product_by_type", {
offset: 0,
limit: 6,
rand: true,
type: "venue,post,line,ticket"
}).then(res => {
this.setData({
showLoading: false
})
try {
this.setData({
tjList: res.data.list
})
} catch (error) {
console.log(error);
}
})
}
},
/**
* 组件的初始数据
*/
data: {
tjList: [],
},
/**
* 组件的方法列表
*/
methods: {
gotoDetail: function (e) {
let item = e.currentTarget.dataset.item;
util.pagePoint({
event: 'recommend_click',
param: {
id: item.id,
type: item.type
}
}, 1)
if (item.type == 'travels') {
// 游记做特殊处理 其他都按照原来的来
wx.navigateTo({
url: '/pages/info/strategyInfo/index?id=' + item.s_id,
})
} else {
util.gotoDetail(item);
}
},
}
})

4
pages/component/proRec/proRec.json

@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}

17
pages/component/proRec/proRec.wxml

@ -0,0 +1,17 @@
<view class="box">
<view class="tj-title">商品推荐</view>
<view wx:if="{{showLoading}}">加载中...</view>
<view class="tj-list" wx:else>
<view class="proitem" wx:for="{{tjList}}" bindtap="gotoDetail" data-item="{{item}}">
<view class="item-hd">
<image src="{{item.headimg}}"></image>
</view>
<view class="item-bm">
<view class="protitle textOver">{{item.title}}</view>
<view class="pro-price">
{{item.price/100}}
</view>
</view>
</view>
</view>
</view>

53
pages/component/proRec/proRec.wxss

@ -0,0 +1,53 @@
.tj-title{
font-size: 30rpx;
font-family: PingFang SC;
font-weight: 500;
color: #333333;
}
.tj-list{
display: flex;
align-items: center;
overflow-x: scroll;
overflow-y: hidden;
}
.proitem{
width: 226rpx;
height: 234rpx;
background: #F5F5F5;
border-radius: 10rpx;
margin-top: 20rpx;
margin-right: 20rpx;
}
.item-hd image{
width: 226rpx;
height: 130rpx;
border-radius: 10rpx 10rpx 0px 0px;
}
.item-bm{
padding: 8rpx 12rpx;
}
.protitle{
font-size: 28rpx;
font-family: PingFang SC;
font-weight: 400;
color: #000000;
}
.pro-price{
color: #D62828;
font-weight: 500;
font-size: 30rpx;
}
.pro-price:before {
display: inline-block;
content:"¥";
color: #D62828;
font-size: 20rpx;
}
.pro-price:after {
display: inline-block;
content:'起';
color: #999999;
font-size: 10px;
}

3
pages/info/sceneProductInfo/index.js

@ -25,7 +25,7 @@ Page({
allowance_data: null, allowance_data: null,
//购物车数量 //购物车数量
producNum: 1, producNum: 1,
skuIndex: 0, skuIndex:null,
aniSkuIndex: -1, aniSkuIndex: -1,
cartCount: 0, cartCount: 0,
cartImgInfo: null, cartImgInfo: null,
@ -256,7 +256,6 @@ Page({
icon: 'none' icon: 'none'
}) })
return return
} }
let index = e.currentTarget.dataset.index; let index = e.currentTarget.dataset.index;
this.setData({ this.setData({

8
pages/info/sceneProductInfo/index.wxml

@ -115,17 +115,17 @@
<view class="mask-content"> <view class="mask-content">
<view class="iconfont icon-close" bindtap="hideSku"></view> <view class="iconfont icon-close" bindtap="hideSku"></view>
<view class="sku-info-box"> <view class="sku-info-box">
<image id="skuImg" src="{{skuList[skuIndex].headimg}}" mode="aspectFill"></image> <image id="skuImg" src="{{skuList[skuIndex].headimg||skuList[0].headimg}}" mode="aspectFill"></image>
<view class="sku-info"> <view class="sku-info">
<view class="sku-price">{{tool.toFix(skuList[skuIndex].price)}} <view class="sku-price">{{ isNaN(tool.toFix(skuList[skuIndex].price))?tool.toFix(skuList[skuIndex].price):tool.toFix(skuList[0].price) }}
<view class="allowance" wx:if="{{allowance_data}}"> <view class="allowance" wx:if="{{allowance_data}}">
补贴价:¥{{ (1 - allowance_data.discount_rate / 100) * info.sku[skuIndex].price / 100 }}</view> 补贴价:¥{{ (1 - allowance_data.discount_rate / 100) * info.sku[skuIndex].price / 100 }}</view>
</view> </view>
<view class="sku-name">已选择:{{skuList[skuIndex].sku_name}}</view> <view class="sku-name">已选择:{{skuList[skuIndex].sku_name || skuList[0].sku_name}}</view>
</view> </view>
</view> </view>
<view class="sku-names"> <view class="sku-names">
<view bindtap="selectSku" data-index="{{index}}" data-item="{{item}}" class="sku-name-item textOver{{index==skuIndex?' active':''}}" wx:for="{{skuList}}">{{item.sku_name}}</view> <view bindtap="selectSku" data-index="{{index}}" data-item="{{item}}" class="sku-name-item textOver{{index==skuIndex?' active':''}} {{item.stock==0&&item.is_third_stock!=1?' disable':''}}" wx:for="{{skuList}}">{{item.sku_name}}</view>
</view> </view>
<view class="number-box"> <view class="number-box">
<text>数量</text> <text>数量</text>

287
pages/user/cartlist/list.js

@ -1,5 +1,6 @@
// pages/user/cartlist/list.js // pages/user/cartlist/list.js
const device = wx.getSystemInfoSync(),rect = wx.getMenuButtonBoundingClientRect(); // 获取设备信息 const device = wx.getSystemInfoSync(),
rect = wx.getMenuButtonBoundingClientRect(); // 获取设备信息
const ratio = 750 / device.windowWidth; const ratio = 750 / device.windowWidth;
console.log(rect) console.log(rect)
const width = device.windowWidth // 示例为一个与屏幕等宽的正方形裁剪框 const width = device.windowWidth // 示例为一个与屏幕等宽的正方形裁剪框
@ -13,12 +14,13 @@ Page({
* 页面的初始数据 * 页面的初始数据
*/ */
data: { data: {
menuWidth:width - rect.right + rect.width + 6, menuWidth: width - rect.right + rect.width + 6,
list:[], list: [],
allChecked:false, allChecked: false,
allPrice:0, allPrice: 0,
productType:'', productType: '',
flag:false,//判断订单是否同时有商品和票 manageFlag: false,
flag: false, //判断订单是否同时有商品和票
}, },
/** /**
@ -27,145 +29,164 @@ Page({
onLoad: function (options) { onLoad: function (options) {
this.getList(); this.getList();
}, },
gotoDetail:function(e){ manage: function () {
console.log(e) let list = this.data.list;
list.map(item => {
item.checked = 0;
})
this.setData({
manageFlag: !this.data.manageFlag,
allChecked: 0,
list: list,
allPrice: 0
})
},
gotoDetail: function (e) {
console.log(e)
let item = e.currentTarget.dataset.item.product; let item = e.currentTarget.dataset.item.product;
util.gotoDetail(item,1); util.gotoDetail(item, 1);
}, },
getList:function(){ getList: function () {
commonApi.user_post("cart/get_list",{ commonApi.user_post("cart/get_list", {
// type: '1' // type: '1'
}).then(res=>{ }).then(res => {
this.setData({ this.setData({
list:res.data list: res.data
}) })
}) })
}, },
minus:function(e){ minus: function (e) {
let index = e.currentTarget.dataset.index,list = this.data.list; let index = e.currentTarget.dataset.index,
list = this.data.list;
let num = list[index].num; let num = list[index].num;
if(num<=1) return; if (num <= 1) return;
num = num - 1; num = num - 1;
list[index].num = num; list[index].num = num;
this.setData({ this.setData({
list:list list: list
}) })
this.changeNumber(list[index]) this.changeNumber(list[index])
this.updatePrice() this.updatePrice()
}, },
add:function(e){ add: function (e) {
let index = e.currentTarget.dataset.index,list = this.data.list; let index = e.currentTarget.dataset.index,
let num = list[index].num+1; list = this.data.list;
let num = list[index].num + 1;
list[index].num = num; list[index].num = num;
this.setData({ this.setData({
list:list list: list
}) })
this.changeNumber(list[index]) this.changeNumber(list[index])
this.updatePrice() this.updatePrice()
}, },
select:function(e){ select: function (e) {
let index = e.currentTarget.dataset.index,list = this.data.list; let index = e.currentTarget.dataset.index,
if(list[index].product.flag!=1 || list[index].sku.flag!='on'){ list = this.data.list;
if (list[index].product.flag != 1 || list[index].sku.flag != 'on') {
wx.showToast({ wx.showToast({
title: '产品已下架', title: '产品已下架',
icon:'none' icon: 'none'
}) })
return; return;
} }
list[index].checked = list[index].checked?false:true; list[index].checked = list[index].checked ? false : true;
this.setData({ this.setData({
list:list list: list
}) })
this.updatePrice() this.updatePrice()
}, },
selectAll:function(){ selectAll: function () {
let list = this.data.list,allChecked = this.data.allChecked?false:true; let list = this.data.list,
list.map(item=>{ allChecked = this.data.allChecked ? false : true;
if(item.sku.flag=='on' && item.product.flag==1){ list.map(item => {
if (item.sku.flag == 'on' && item.product.flag == 1) {
item.checked = allChecked; item.checked = allChecked;
} }
}) })
this.setData({ this.setData({
allChecked:allChecked, allChecked: allChecked,
list:list list: list
}) })
this.updatePrice() this.updatePrice()
}, },
changeNumber(item){ changeNumber(item) {
commonApi.user_post("cart/update_sku",{ commonApi.user_post("cart/update_sku", {
sku_id:item.sku.id, sku_id: item.sku.id,
num:item.num num: item.num
}).then(res=>{ }).then(res => {})
})
}, },
updatePrice:function(){ updatePrice: function () {
let list = this.data.list,price=0; let list = this.data.list,
list.map(item=>{ price = 0;
if(item.checked){ list.map(item => {
if (item.checked) {
price = price + item.sku.price * item.num; price = price + item.sku.price * item.num;
} }
}) })
this.setData({ this.setData({
allPrice:price allPrice: price
}) })
}, },
order:function(){ order: function () {
app.globalData.couponInfo = null; app.globalData.couponInfo = null;
util.pagePoint({ util.pagePoint({
event:'cart_order' event: 'cart_order'
},1) }, 1)
let list = this.data.list,price=0,product=[],product1=[] let list = this.data.list,
list.map(item=>{ price = 0,
if(item.checked){ product = [],
product1 = []
list.map(item => {
if (item.checked) {
// item.product.type="post"; // item.product.type="post";
if(item.product.type == 'post'){ if (item.product.type == 'post') {
product.push({ product.push({
product:item.product, product: item.product,
sku:item.sku, sku: item.sku,
productNum:item.num productNum: item.num
}) })
}else{ } else {
product1.push(item) product1.push(item)
app.globalData.list = product1 app.globalData.list = product1
} }
if(item.product.type.includes('post')){ if (item.product.type.includes('post')) {
this.data.productType = 'post' this.data.productType = 'post'
} }
} }
}) })
if(product.length==0 && product1.length==0) { if (product.length == 0 && product1.length == 0) {
wx.showToast({ wx.showToast({
title: '请先选择产品', title: '请先选择产品',
icon: 'none' icon: 'none'
}) })
return; return;
} }
if (product.length>0 && product1.length>0) { if (product.length > 0 && product1.length > 0) {
this.setData({ this.setData({
flag: 'mix' flag: 'mix'
}) })
} }
app.globalData.postProduct = product; app.globalData.postProduct = product;
if(app.globalData.list){ if (app.globalData.list) {
app.globalData.product = app.globalData.list[app.globalData.index] app.globalData.product = app.globalData.list[app.globalData.index]
} }
if(this.data.productType == 'post'){ if (this.data.productType == 'post') {
console.log(this.data.flag); console.log(this.data.flag);
wx.navigateTo({ wx.navigateTo({
url: '/pages/order/postOrder/index?from=cart&flag='+this.data.flag, url: '/pages/order/postOrder/index?from=cart&flag=' + this.data.flag,
}) })
}else{ } else {
wx.navigateTo({ wx.navigateTo({
url: '/pages/order/scene/index', url: '/pages/order/scene/index',
}) })
} }
}, },
touchStart(e){//移动前点击的位置 touchStart(e) { //移动前点击的位置
console.log(e) console.log(e)
// 在开始触摸时将所有startTouchMove设置为flase,对当前的为true // 在开始触摸时将所有startTouchMove设置为flase,对当前的为true
this.data.list.forEach(cart =>{ this.data.list.forEach(cart => {
if(cart.isTouchMove)//当istouchMove为true if (cart.isTouchMove) //当istouchMove为true
cart.isTouchMove = false;//其它的对象都为false cart.isTouchMove = false; //其它的对象都为false
}) })
this.setData({ this.setData({
startX: e.changedTouches[0].clientX, startX: e.changedTouches[0].clientX,
@ -173,61 +194,101 @@ Page({
list: this.data.list list: this.data.list
}) })
}, },
touchmove(e){//移动的位置,用于计算用户滑动的弧度向左还是向右,移动了多少,可以确定删除功能的显示和隐藏 touchmove(e) { //移动的位置,用于计算用户滑动的弧度向左还是向右,移动了多少,可以确定删除功能的显示和隐藏
let index = e.currentTarget.dataset.index; let index = e.currentTarget.dataset.index;
// 获取开始的x,y坐标 // 获取开始的x,y坐标
let startX = this.data.startX, let startX = this.data.startX,
startY = this.data.startY; startY = this.data.startY;
// 获取移动的x,x坐标 // 获取移动的x,x坐标
let touchMoveX = e.changedTouches[0].clientX, let touchMoveX = e.changedTouches[0].clientX,
touchMoveY = e.changedTouches[0].clientY; touchMoveY = e.changedTouches[0].clientY;
// 调用计算角度的方法,获取角度 // 调用计算角度的方法,获取角度
var angel = this.angel({ X: startX, Y: startY }, { X: touchMoveX, Y: touchMoveY }) var angel = this.angel({
X: startX,
Y: startY
}, {
X: touchMoveX,
Y: touchMoveY
})
// 遍历cartArray // 遍历cartArray
this.data.list.forEach((cart, i ) =>{ this.data.list.forEach((cart, i) => {
cart.isTouchMove = false; cart.isTouchMove = false;
// 滑动角度大于30,直接return 视为非滑动意思 // 滑动角度大于30,直接return 视为非滑动意思
if(Math.abs(angel) > 30) return; if (Math.abs(angel) > 30) return;
// 匹配当前所点击的list和滑动的list // 匹配当前所点击的list和滑动的list
if(i == index){ if (i == index) {
// 匹配上后判断滑动方向 // 匹配上后判断滑动方向
if (touchMoveX > startX){//左滑动隐藏删除 if (touchMoveX > startX) { //左滑动隐藏删除
cart.isTouchMove = false; cart.isTouchMove = false;
}else{ } else {
cart.isTouchMove = true; cart.isTouchMove = true;
} }
} }
}) })
// 更新数据 // 更新数据
this.setData({ this.setData({
list:this.data.list list: this.data.list
}) })
}, },
angel(start,end){//计算滑动的角度 angel(start, end) { //计算滑动的角度
// console.log(start,end) // console.log(start,end)
// 移动坐标减去对应的开始坐标 // 移动坐标减去对应的开始坐标
var _X = end.X - start.X, var _X = end.X - start.X,
_Y = end.Y - start.Y; _Y = end.Y - start.Y;
// 返回角度 Math.atan() 返回数字的正切值 // 返回角度 Math.atan() 返回数字的正切值
return 360 * Math.atan(_Y / _X) / (2 * Math.PI) return 360 * Math.atan(_Y / _X) / (2 * Math.PI)
}, },
del:function(e){ del: function (e) {
let index = e.currentTarget.dataset.index,list = this.data.list; let index = e.currentTarget.dataset.index,
commonApi.user_post("cart/del_sku",{ list = this.data.list;
sku_id:list[index].sku_id commonApi.user_post("cart/del_sku", {
}).then(res=>{ sku_id: list[index].sku_id
if(res.code==1){ }).then(res => {
if (res.code == 1) {
wx.showToast({ wx.showToast({
title: '删除成功', title: '删除成功',
icon:"success" icon: "success"
}) })
list.splice(index,1); list.splice(index, 1);
this.setData({ this.setData({
list:list list: list
}) })
} }
}) })
}, },
delM() {
let that = this
let arr = this.data.list
let suid = []
arr.forEach(item => {
if (item.checked) {
suid.push(item.sku_id)
}
});
let skuids = suid.join(',')
wx.showModal({
title: '提示',
content: '确定要删除选定的产品?',
success: function (res) {
if (res.confirm) {
commonApi.user_post("cart/del_sku", {
sku_id:skuids
}).then(res => {
if (res.code == 1) {
wx.showToast({
title: '删除成功',
icon: "success"
})
that.getList();
}
})
} else {
console.log('取消')
}
}
})
},
/** /**
* 生命周期函数--监听页面初次渲染完成 * 生命周期函数--监听页面初次渲染完成
*/ */
@ -240,14 +301,14 @@ Page({
*/ */
onShow: function () { onShow: function () {
util.pagePoint({ util.pagePoint({
event:'cart_view' event: 'cart_view'
},1) }, 1)
app.globalData.list = null app.globalData.list = null
app.globalData.createDate = null app.globalData.createDate = null
app.globalData.index = 0 app.globalData.index = 0
app.globalData.productPrice = 0 app.globalData.productPrice = 0
app.globalData.ticketPrice = 0 app.globalData.ticketPrice = 0
this.data.productType = '' this.data.productType = ''
}, },
/** /**

12
pages/user/cartlist/list.wxml

@ -1,11 +1,11 @@
<!--pages/user/cartlist/list.wxml--> <!--pages/user/cartlist/list.wxml-->
<title title="购物车"> <title title="购物车">
<!-- <view class="edit-btn" style="right:{{menuWidth}}px">管理</view> --> <view class="edit-btn" style="right:{{menuWidth}}px" wx:if="{{list.length>0}}" bindtap="manage">{{manageFlag?'关闭':'管理'}}</view>
</title> </title>
<view wx:for="{{list}}" class="goods-item {{item.isTouchMove ? 'touch-move-active' : ''}}" bindtouchstart='touchStart' bindtouchmove='touchmove' data-index="{{index}}"> <view wx:for="{{list}}" class="goods-item {{item.isTouchMove ? 'touch-move-active' : ''}}" bindtouchstart='touchStart' bindtouchmove='touchmove' data-index="{{index}}">
<view class="item{{(item.product.flag!=1 || item.sku.flag!='on')?' disable':''}}"> <view class="item{{(item.product.flag!=1 || item.sku.flag!='on')?' disable':''}}">
<view class="iconfont{{item.checked?' icon-gou':' icon-quan'}}" bindtap="select" data-index="{{index}}"></view> <view class="iconfont{{item.checked?' icon-gou':' icon-quan'}}" bindtap="select" data-index="{{index}}"></view>
<image src="{{item.sku.headimg}}" mode="aspectFill" bindtap="gotoDetail" data-item="{{item}}"></image> <image src="{{item.sku.headimg}}" mode="aspectFill" bindtap="gotoDetail" data-item="{{item}}"></image>
<view class="item-info textOver"> <view class="item-info textOver">
<view class="title textOver">{{item.product.title}}</view> <view class="title textOver">{{item.product.title}}</view>
<view class="sku-title textOver"> <view class="sku-title textOver">
@ -28,7 +28,7 @@
<view>暂无内容</view> <view>暂无内容</view>
</view> </view>
<view style="height:113rpx"></view> <view style="height:113rpx"></view>
<view class="fixed-bottom" wx:if="{{list.length>0}}"> <view class="fixed-bottom" wx:if="{{list.length>0&&manageFlag===false}}">
<view bindtap="selectAll" class="iconfont{{allChecked?' icon-gou':' icon-quan'}}"></view> <view bindtap="selectAll" class="iconfont{{allChecked?' icon-gou':' icon-quan'}}"></view>
<view class="tip">合计:</view> <view class="tip">合计:</view>
<view class="bottom-price">¥{{allPrice/100}} </view> <view class="bottom-price">¥{{allPrice/100}} </view>
@ -36,3 +36,9 @@
<view style="flex:1"></view> <view style="flex:1"></view>
<view class="btn" bindtap="order">去下单</view> <view class="btn" bindtap="order">去下单</view>
</view> </view>
<view class="fixed-bottom" wx:if="{{list.length>0&&manageFlag===true}}">
<view class="iconfont{{allChecked?' icon-gou':' icon-quan'}}" bindtap="selectAll"></view>
<text style="color:#666;font-size:26rpx;flex-shrink:0;margin-left:10rpx;flex:1">全选</text>
<view class="fixed-btn del-btn" bindtap="delM">删除</view>
</view>

17
pages/user/cartlist/list.wxss

@ -158,3 +158,20 @@ page {
.icon-gou { .icon-gou {
color: #D62828; color: #D62828;
} }
.fixed-btn {
width: 202rpx;
line-height: 84rpx;
background: #FB6E4D;
border-radius: 42rpx;
font-size: 36rpx;
font-weight: 500;
color: #fff;
text-align: center;
}
.del-btn {
box-sizing: border-box;
border: 1rpx solid #FB6E4D;
color: #FB6E4D;
background: white;
margin-right:40rpx ;
}

4
pages/user/order/hotelOrderInfo/index.json

@ -1,5 +1,7 @@
{ {
"usingComponents": { "usingComponents": {
"title":"/pages/component/TitleHeader" "title":"/pages/component/TitleHeader",
"sptj":"/pages/component/proRec/proRec"
} }
} }

1
pages/user/order/hotelOrderInfo/index.wxml

@ -40,6 +40,7 @@
<navigator url="/pages/order/pay/index?id={{id}}" class="btn active" wx:if="{{info.state=='UNPAID'}}">立即支付</navigator> <navigator url="/pages/order/pay/index?id={{id}}" class="btn active" wx:if="{{info.state=='UNPAID'}}">立即支付</navigator>
</view> </view>
</view> </view>
<sptj></sptj>
<navigator url="/pages/info/hotelProductInfo/index?id={{item.scene_detail.id}}" class="box" wx:if='{{info}}' wx:for="{{info.order_product_list}}" style="padding-bottom:0"> <navigator url="/pages/info/hotelProductInfo/index?id={{item.scene_detail.id}}" class="box" wx:if='{{info}}' wx:for="{{info.order_product_list}}" style="padding-bottom:0">
<view class="scene-box" style="align-items:center"> <view class="scene-box" style="align-items:center">
<view class="scene-box-left"> <view class="scene-box-left">

1
pages/user/order/hotelOrderInfo/index.wxss

@ -282,3 +282,4 @@ page {
color: #999; color: #999;
margin-top: 30rpx; margin-top: 30rpx;
} }

3
pages/user/order/lineOrderInfo/index.json

@ -1,5 +1,6 @@
{ {
"usingComponents": { "usingComponents": {
"title":"/pages/component/TitleHeader" "title":"/pages/component/TitleHeader",
"sptj":"/pages/component/proRec/proRec"
} }
} }

3
pages/user/order/lineOrderInfo/index.wxml

@ -44,6 +44,9 @@
<!-- <view class="scene-btn active" wx:if="{{info.state=='UNPAID'}}">立即支付</view> --> <!-- <view class="scene-btn active" wx:if="{{info.state=='UNPAID'}}">立即支付</view> -->
</view> </view>
</view> </view>
<sptj></sptj>
<!--景点订单详情需要这个 --> <!--景点订单详情需要这个 -->
<navigator url="/pages/info/roadInfo/index?id={{info.order_product_list[0].product_id}}" class="box" wx:if='{{info}}'> <navigator url="/pages/info/roadInfo/index?id={{info.order_product_list[0].product_id}}" class="box" wx:if='{{info}}'>
<view class="scene-box" style="align-items:center"> <view class="scene-box" style="align-items:center">

4
pages/user/order/museumOrderInfo/index.json

@ -1,5 +1,7 @@
{ {
"usingComponents": { "usingComponents": {
"title":"/pages/component/TitleHeader" "title":"/pages/component/TitleHeader",
"sptj":"/pages/component/proRec/proRec"
} }
} }

2
pages/user/order/museumOrderInfo/index.wxml

@ -55,6 +55,8 @@
<!-- <view class="btn active" wx:if="{{info.state=='UNPAID'}}">立即支付</view> --> <!-- <view class="btn active" wx:if="{{info.state=='UNPAID'}}">立即支付</view> -->
</view> </view>
</view> </view>
<sptj></sptj>
<view class="box" wx:if="{{info}}"> <view class="box" wx:if="{{info}}">
<view class="box-title">{{info.order_product_list[0].scene_detail.title}}</view> <view class="box-title">{{info.order_product_list[0].scene_detail.title}}</view>
<view class="detail-item"> <view class="detail-item">

3
pages/user/order/postOrderInfo/index.json

@ -1,5 +1,6 @@
{ {
"usingComponents": { "usingComponents": {
"title":"/pages/component/TitleHeader" "title":"/pages/component/TitleHeader",
"sptj":"/pages/component/proRec/proRec"
} }
} }

18
pages/user/order/postOrderInfo/index.wxml

@ -12,23 +12,7 @@
<view class="box-title" style="margin-top:15rpx"><text style="margin-right:20rpx">{{info.order_product_list[0].consignee_info.name}}</text><text>{{info.order_product_list[0].consignee_info.tel}}</text></view> <view class="box-title" style="margin-top:15rpx"><text style="margin-right:20rpx">{{info.order_product_list[0].consignee_info.name}}</text><text>{{info.order_product_list[0].consignee_info.tel}}</text></view>
<view style="font-size:26rpx;color:#333;line-height:50rpx"><text style="color:#0B898E;margin-right:10rpx" class="iconfont icon-location"></text>{{info.order_product_list[0].consignee_info.address}}</view> <view style="font-size:26rpx;color:#333;line-height:50rpx"><text style="color:#0B898E;margin-right:10rpx" class="iconfont icon-location"></text>{{info.order_product_list[0].consignee_info.address}}</view>
</view> </view>
<view class="box"> <sptj></sptj>
<view class="tj-title">商品推荐</view>
<view wx:if="{{showLoading}}">加载中...</view>
<view class="tj-list" wx:else>
<view class="proitem" wx:for="{{tjList}}" bindtap="gotoDetail" data-item="{{item}}">
<view class="item-hd">
<image src="{{item.headimg}}"></image>
</view>
<view class="item-bm">
<view class="protitle textOver">{{item.title}}</view>
<view class="pro-price">
{{item.price/100}}
</view>
</view>
</view>
</view>
</view>
<view class="box" wx:if="{{info}}" style="padding-bottom:0"> <view class="box" wx:if="{{info}}" style="padding-bottom:0">
<view wx:if="{{info.order_product_list && info.order_product_list.length>0}}" class="product-info" wx:for="{{info.order_product_list}}"> <view wx:if="{{info.order_product_list && info.order_product_list.length>0}}" class="product-info" wx:for="{{info.order_product_list}}">
<view class="product-info-top"> <view class="product-info-top">

4
pages/user/order/sceneOrderInfo/index.json

@ -1,5 +1,7 @@
{ {
"usingComponents": { "usingComponents": {
"title":"/pages/component/TitleHeader" "title":"/pages/component/TitleHeader",
"sptj":"/pages/component/proRec/proRec"
} }
} }

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

@ -16,6 +16,9 @@
<view class="code-state">{{info.order_product_list[0].qrcode[codeIndex].stateText}} {{codeIndex+1}}/{{codeImgs.length}}</view> <view class="code-state">{{info.order_product_list[0].qrcode[codeIndex].stateText}} {{codeIndex+1}}/{{codeImgs.length}}</view>
<!-- <view bindtap="gotoSku" class="code-btn">查看苏康码</view> --> <!-- <view bindtap="gotoSku" class="code-btn">查看苏康码</view> -->
</view> </view>
<sptj></sptj>
<!-- 景点订单详情需要这个 --> <!-- 景点订单详情需要这个 -->
<view class="box" wx:if='{{product_model=="ticket"}}'> <view class="box" wx:if='{{product_model=="ticket"}}'>
<view class="scene-box"> <view class="scene-box">
@ -100,7 +103,6 @@
<view bindtap="leadRoad" data-url="{{item.btnUrl}}" class="btn" wx:if="{{item.state!='UNPAID' && item.product_model=='ticket'}}">行程规划</view> <view bindtap="leadRoad" data-url="{{item.btnUrl}}" class="btn" wx:if="{{item.state!='UNPAID' && item.product_model=='ticket'}}">行程规划</view>
</view> </view>
</view> </view>
</view> </view>
<!-- <view class="box" wx:if="{{product_model=='ticket'}}"> <!-- <view class="box" wx:if="{{product_model=='ticket'}}">
<view class="box-title">使用说明</view> <view class="box-title">使用说明</view>

Loading…
Cancel
Save