|
@@ -1,6 +1,6 @@
|
|
|
<template>
|
|
|
<view class="orderDetail-digitalShel flex flex_column">
|
|
|
- <view class="contHead" :style="{background:state!= 'error'&&state!= 'AUDIT_REJECT'&&state!='CANCEL' ? '#066cff':'#e61100',color:'#fff'}">
|
|
|
+ <view class="contHead" :style="{background:state!= 'error'&&state!= 'AUDIT_REJECT'&&state!='CANCEL'&&state!='WAIT_PAY' ? '#066cff':'#e61100',color:'#fff'}">
|
|
|
<view class="statusH">
|
|
|
<view class="flex flex_column align_center">
|
|
|
<view class="status-row">
|
|
@@ -9,6 +9,11 @@
|
|
|
<text>{{statusText}}</text>
|
|
|
</view>
|
|
|
<view class="messageText" v-if="statusMessage"><text>{{statusMessage}}</text></view>
|
|
|
+ <view v-if="info.billStatus=='WAIT_PAY'" class="messageText">
|
|
|
+ 请尽快支付,
|
|
|
+ <u-count-down separator="zh" :separator-size="24" bg-color="none" color="#ffff7f" separator-color="#ffff7f" :timestamp="info.timestamp" :show-days="false" :show-hours="false"></u-count-down>
|
|
|
+ 后订单将自动取消。
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
@@ -167,13 +172,13 @@
|
|
|
<view :style="{height:safeAreaBottom+'px'}"></view>
|
|
|
</view>
|
|
|
<!-- 付款弹框 -->
|
|
|
- <payModal :showPopu="showPopu" :payInfo="payInfo" @close="showPopu=false" @payComplete="payComplete"></payModal>
|
|
|
+ <payModal :showPopu="showPopu" :payInfo="payInfo" :payData="payData" @close="showPopu=false" @payComplete="payComplete"></payModal>
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
import payModal from '../components/payModal.vue'
|
|
|
- import { purchaseQueryDetailPage,purchaseCancel,purchaseReceive } from '@/api/purchase.js'
|
|
|
+ import { purchaseQueryDetailPage,purchaseCancel,purchaseReceive,purchasePay } from '@/api/purchase.js'
|
|
|
export default {
|
|
|
name: 'procureDetailOrder',
|
|
|
components:{
|
|
@@ -194,6 +199,7 @@
|
|
|
purchaseSn: null,
|
|
|
showPopu: false,
|
|
|
safeAreaBottom: 0, // 底部安全区域高度
|
|
|
+ payData: null
|
|
|
}
|
|
|
},
|
|
|
onLoad(option) {
|
|
@@ -215,7 +221,7 @@
|
|
|
// 更改标题栏背景色
|
|
|
uni.setNavigationBarColor({
|
|
|
frontColor: '#ffffff',
|
|
|
- backgroundColor: this.state!= 'error'&&this.state!= 'AUDIT_REJECT'&&this.state!= 'CANCEL' ? '#066cff':'#e61100',
|
|
|
+ backgroundColor: this.state!= 'error'&&this.state!= 'AUDIT_REJECT'&&this.state!= 'CANCEL'&&this.state!= 'WAIT_PAY' ? '#066cff':'#e61100',
|
|
|
})
|
|
|
}
|
|
|
},
|
|
@@ -293,13 +299,20 @@
|
|
|
},
|
|
|
// 立即支付
|
|
|
payOrder(item){
|
|
|
- this.showPopu = true
|
|
|
+ purchasePay({
|
|
|
+ bizSn:item.purchaseSn,
|
|
|
+ bizNo:item.purchaseNo,
|
|
|
+ bizType:'PURCHASE',
|
|
|
+ }).then(res=>{
|
|
|
+ this.showPopu = true
|
|
|
+ this.payData = res.data?res.data.payRequestRest:null
|
|
|
+ })
|
|
|
},
|
|
|
// 付款成功,isOk: false 取消支付或支付失败,true 支付完成
|
|
|
payComplete(item,isOk){
|
|
|
this.showPopu = false
|
|
|
if(isOk){
|
|
|
- uni.$emit('refreshPurcaOrder',item,'payOk')
|
|
|
+ uni.$emit('refreshPurcaOrder',item,'WAIT_AUDIT')
|
|
|
uni.navigateBack()
|
|
|
}
|
|
|
},
|