Browse Source

no message

feature/v2.3
xpz2018 4 years ago
parent
commit
90760e03df
3 changed files with 23 additions and 4 deletions
  1. 13
      pages/process/order-info/index.js
  2. 6
      pages/process/order-info/index.wxml
  3. 8
      pages/process/payment/index.js

13
pages/process/order-info/index.js

@ -17,7 +17,8 @@ Scene({
form: null,
agent: 0,
title: '过磅详情',
imageList: []
imageList: [],
paymentImageList: null
},
/**
* 生命周期函数--监听页面加载
@ -65,13 +66,21 @@ Scene({
this.data.imageList.push({ url: element })
}
}
if(result.data.paymentImageList && result.data.paymentImageList.length){
this.data.paymentImageList = []
for (let index = 0; index < result.data.paymentImageList.length; index++) {
const element = result.data.paymentImageList[index]
this.data.paymentImageList.push({ url: element })
}
}
this.setData({
safeBottom: app.globalData.safeBottom,
form: result.data,
title: this.data.title,
admin: app.userInfo.type && app.userInfo.type.indexOf('ADMIN') >= 0,
agent: this.data.agent,
imageList: this.data.imageList
imageList: this.data.imageList,
paymentImageList: this.data.paymentImageList
})
}).catch(err => {
wx.hideLoading()

6
pages/process/order-info/index.wxml

@ -175,6 +175,12 @@
<view class="text-gray">{{form.id}}</view>
</view>
</van-cell>
<view class="bg-white" style="padding: 24rpx 32rpx 20rpx 32rpx" wx:if="{{paymentImageList}}">
<view class="flex flex-justify" style="padding-bottom: 24rpx">
<view class="flex flex-center text-black">支付凭证</view>
</view>
<van-uploader file-list="{{ paymentImageList }}" deletable="{{false}}" show-upload="{{false}}" />
</view>
</view>
<view style="height:16rpx"></view>

8
pages/process/payment/index.js

@ -103,7 +103,11 @@ Scene({
if (orderList && orderList.length) {
for (let index = 0; index < orderList.length; index++) {
const element = orderList[index]
amount = math.plus(amount, element.adjustedPrice)
if(element.adjustedPrice){
amount = math.plus(amount, element.adjustedPrice)
} else {
amount = math.plus(amount, element.settleWeight)
}
this.data.params.ids.push(element.id)
if(!util.isEmpty(element.bankCardNo)){
this.data.params.bankCardNo = element.bankCardNo
@ -114,10 +118,10 @@ Scene({
if(settleType){
this.data.settleType = String(settleType)
}
this.data.orderStatus = orderList[0].status
if(this.data.orderStatus == 42 && this.data.settleType == '3'){
this.data.settleType = '1'
}
this.data.orderStatus = orderList[0].status
this.setData({
height: app.globalData.fragmentHeight,
safeBottom: app.globalData.safeBottom,

Loading…
Cancel
Save