确认兑换
This commit is contained in:
@@ -16,9 +16,12 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="order-item__footer">
|
<div class="order-item__footer">
|
||||||
<span :style="{color: $dict.getColor('integralOrderStatus', item.orderStatus)}">
|
<div style="display:flex;justify-content: space-between;">
|
||||||
{{$dict.getLabel('integralOrderStatus', item.orderStatus) }}</span>
|
<span :style="{color: $dict.getColor('integralOrderStatus', item.orderStatus)}">{{$dict.getLabel('integralOrderStatus', item.orderStatus) }}</span>
|
||||||
<div class="order-item__footer--btn" v-if="item.orderStatus === '0'" @click.stop="cancel(item.id)">取消订单</div>
|
<div class="order-item__footer--btn" v-if="item.orderStatus === '0'" @click.stop="cancel(item.id)">取消订单</div>
|
||||||
|
<div class="order-item__footer--btn" v-if="item.orderStatus == '3'" @click.stop="confirm(item.id)">确认兑换</div>
|
||||||
|
</div>
|
||||||
|
<p v-if="item.orderStatus == '3'" style="margin-top:8px;color:#f46;font-size:14px;">商品兑换后,如不确认兑换,系统将于72小时后自动确认,如有疑问请联系客服。</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<AiEmpty v-if="!list.length"/>
|
<AiEmpty v-if="!list.length"/>
|
||||||
@@ -71,6 +74,16 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
confirm(id) {
|
||||||
|
this.$loading()
|
||||||
|
this.$instance.post(`/app/appvillagerintegralshoporder/finishOrder?orderId=${id}`).then(res => {
|
||||||
|
if (res.code === 0) {
|
||||||
|
this.$toast('确认成功')
|
||||||
|
this.reset()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
getTotal(arr) {
|
getTotal(arr) {
|
||||||
let total = 0
|
let total = 0
|
||||||
arr.forEach(item => {
|
arr.forEach(item => {
|
||||||
@@ -159,11 +172,7 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.order-item__footer {
|
.order-item__footer {
|
||||||
display: flex;
|
padding: 24px;
|
||||||
align-items: center;
|
|
||||||
justify-content: space-between;
|
|
||||||
height: 112px;
|
|
||||||
padding: 024px;
|
|
||||||
span {
|
span {
|
||||||
color: #3078E1;
|
color: #3078E1;
|
||||||
font-size: 28px;
|
font-size: 28px;
|
||||||
|
|||||||
@@ -33,6 +33,11 @@
|
|||||||
<div></div>
|
<div></div>
|
||||||
<span class="cancelBtn" @click="cancel">取消订单</span>
|
<span class="cancelBtn" @click="cancel">取消订单</span>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="order-bottom__bottom" v-if="info.orderStatus == '3'">
|
||||||
|
<div></div>
|
||||||
|
<span class="cancelBtn" @click="confirm">确认兑换</span>
|
||||||
|
</div>
|
||||||
|
<p v-if="info.orderStatus == '3'" style="margin-top:8px;color:#f46;font-size:14px;padding-bottom:32px;">商品兑换后,如不确认兑换,系统将于72小时后自动确认,如有疑问请联系客服。</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -89,7 +94,17 @@ export default {
|
|||||||
this.getInfo()
|
this.getInfo()
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
},
|
||||||
|
confirm() {
|
||||||
|
this.$loading()
|
||||||
|
this.$instance.post(`/app/appvillagerintegralshoporder/finishOrder?orderId=${this.id}`).then(res => {
|
||||||
|
if (res.code === 0) {
|
||||||
|
this.$toast('确认成功')
|
||||||
|
uni.$emit('update')
|
||||||
|
this.getInfo()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in New Issue
Block a user