|
|
@@ -10,6 +10,11 @@
|
|
|
</view>
|
|
|
<view class="order-item">
|
|
|
|
|
|
+ <view v-if="beginCount > 0 && orderInfo.fromType == 4" style="min-height:35upx;height:auto;">
|
|
|
+ <text class="left">开始制作</text>
|
|
|
+ <text class="right" style="color:red;font-weight:bold;font-size:20upx;">{{beginCount}} 秒后</text>
|
|
|
+ </view>
|
|
|
+
|
|
|
<view v-if="orderInfo.hasReachTime == 1"><text class="left">配送</text>
|
|
|
<text class="right" style="color:red;font-weight:bold;">
|
|
|
<text v-if="orderInfo.reachDate == orderInfo.today">今天</text>
|
|
|
@@ -168,7 +173,9 @@ export default {
|
|
|
customData:{},
|
|
|
workItemId:0,
|
|
|
currentJobType:'modify',
|
|
|
- currentJobId:0
|
|
|
+ currentJobId:0,
|
|
|
+ beginCount:0,
|
|
|
+ INT:null
|
|
|
}
|
|
|
},
|
|
|
props: {
|
|
|
@@ -196,11 +203,15 @@ export default {
|
|
|
// #endif
|
|
|
},
|
|
|
destroyed(){
|
|
|
+
|
|
|
+ clearInterval(this.INT)
|
|
|
+
|
|
|
// #ifdef APP-PLUS
|
|
|
//避免重复,每次进来先移除全局自定义事件监听器
|
|
|
uni.$off('listenGetScanCode')
|
|
|
// #endif
|
|
|
- this.removeFromSaveDirect()
|
|
|
+ this.removeFromSaveDirect()
|
|
|
+
|
|
|
},
|
|
|
methods:{
|
|
|
previewImage(url){
|
|
|
@@ -325,6 +336,19 @@ export default {
|
|
|
getFullInfo({id}).then(res=>{
|
|
|
if(res.code == 1){
|
|
|
this.orderInfo = res.data.info
|
|
|
+
|
|
|
+ let that = this
|
|
|
+ this.beginCount = Number(this.orderInfo.beginCount)
|
|
|
+ if(this.beginCount > 0 && this.orderInfo.fromType ==4){
|
|
|
+ clearInterval(this.INT)
|
|
|
+ that.INT = setInterval(function(){
|
|
|
+ that.beginCount--
|
|
|
+ if(that.beginCount <= 0){
|
|
|
+ clearInterval(that.INT)
|
|
|
+ }
|
|
|
+ },1000)
|
|
|
+ }
|
|
|
+
|
|
|
let bigNum = 0
|
|
|
let smallNum = 0
|
|
|
this.orderItem = res.data.item
|