|
|
@@ -76,7 +76,11 @@
|
|
|
</view>
|
|
|
<view class="order-info_box">
|
|
|
<view>订单状态:</view>
|
|
|
- <view>{{ detailInfo.status==1?'待付款':detailInfo.status==2?'待配送':detailInfo.status==3?'配送中':detailInfo.status==4?'已完成':detailInfo.status==5?'已取消':'已退款' }}</view>
|
|
|
+ <view>{{ detailInfo.status==1?'待确认':detailInfo.status==2?'待配送':detailInfo.status==3?'配送中':detailInfo.status==4?'已完成':detailInfo.status==5?'已取消':'已退款' }}</view>
|
|
|
+ </view>
|
|
|
+ <view v-if="detailInfo.status==1" class="order-info_box">
|
|
|
+ <view>过期时间:</view>
|
|
|
+ <view>{{detailInfo.deadline}}</view>
|
|
|
</view>
|
|
|
<view v-if="detailInfo.refund == 2" class="order-info_box">
|
|
|
<view>退款金额:</view>
|
|
|
@@ -128,7 +132,6 @@
|
|
|
<view class="summary-bar">
|
|
|
<view class="operate-view" ></view>
|
|
|
<view class="describe-view">
|
|
|
- <!--共{{ detailInfo.productStat.kind}}种, 共{{ detailInfo.productStat.bigNum }}扎{{detailInfo.productStat.smallNun}}支,合计 ¥<text class="price">{{ detailInfo.productStat.totalPrice }}</text>-->
|
|
|
共{{ detailInfo.productStat.kind}}种,共{{ detailInfo.productStat.bigNum }}扎{{detailInfo.productStat.smallNun}}支,合计 ¥<text class="price">{{ userPrice.toFixed(2) }}</text>
|
|
|
</view>
|
|
|
</view>
|
|
|
@@ -177,11 +180,8 @@
|
|
|
</view>
|
|
|
<div class="app-footer">
|
|
|
<template v-for="s in detailInfo.buttonList">
|
|
|
- <button :key="s.type" @click="openBt(s, detailInfo)" v-if="s.show == 1&&s.type != 'print'" :disabled="s.disable === 1" class="admin-button-com default" :class="s.disable === 1?'active':''">
|
|
|
- {{ s.type === "item" ? "改花材" : s.type === "selfGet" ? "自取" :s.type === "print" ? "打印" :s.type === "debtPay" ? "延期收款" :s.type === "hasPay" ? "已收款" : "发货" }}
|
|
|
- </button>
|
|
|
- <button :key="s.type" @click="openBt(s, detailInfo)" v-if="s.show == 1&&s.type == 'print'" :disabled="s.disable === 1" class="admin-button-com default" :class="s.disable === 1?'active':''">
|
|
|
- 打印{{detailInfo.printNum>0?`(${detailInfo.printNum})`:''}}
|
|
|
+ <button :key="s.type" @click="clickBtn(s, detailInfo)" v-if="s.show == 1" :disabled="s.disable === 1" class="admin-button-com default" :class="s.disable === 1?'active':''">
|
|
|
+ {{ s.type === "print" ? s.name+`(${detailInfo.printNum})` : s.name}}
|
|
|
</button>
|
|
|
</template>
|
|
|
</div>
|
|
|
@@ -201,7 +201,8 @@
|
|
|
<script>
|
|
|
import stepStatus from "./components/stepStatus";
|
|
|
import TuiListCell from "@/components/plugin/list-cell";
|
|
|
-import { getDetail,debtPay,hasPay, freeShipping } from "@/api/order/index";
|
|
|
+import { getDetail,debtPay,hasPay, freeShipping,confirmFinish } from "@/api/order/index";
|
|
|
+import { getOrderProduct } from "@/api/order-item/index";
|
|
|
import productMins from "@/mixins/product";
|
|
|
import { ORDER_STATUS } from "@/utils/declare";
|
|
|
import BLE from "@/mixins/BLE";
|
|
|
@@ -266,7 +267,7 @@ export default {
|
|
|
modalCancel() {
|
|
|
this.freeShipModal = false;
|
|
|
},
|
|
|
- openBt(s, item) {
|
|
|
+ clickBtn(s, item) {
|
|
|
this.orderId = item.id;
|
|
|
if (s.type === "item") {
|
|
|
// 花材
|
|
|
@@ -334,6 +335,46 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
+ }else if (s.type === "modifyProduct") {
|
|
|
+ //修改花材
|
|
|
+ let self = this;
|
|
|
+ let orderId = item.id
|
|
|
+ let customName = item.customName
|
|
|
+ let customId = item.customId
|
|
|
+ let modifyProductKey = 'modifyProduct_orderId_'+orderId
|
|
|
+
|
|
|
+ getOrderProduct({ id: orderId }).then(res => {
|
|
|
+ let productList = res.data.productList
|
|
|
+ uni.setStorageSync('selectList'+modifyProductKey, productList)
|
|
|
+ self.$util.pageTo({url: '/admin/billing/index',type:2,query: {customId: customId,customName:customName,orderId:orderId,modifyProductKey:modifyProductKey}})
|
|
|
+ })
|
|
|
+
|
|
|
+ }else if(s.type == 'confirm'){
|
|
|
+ let self = this;
|
|
|
+ uni.showActionSheet({
|
|
|
+ itemList: ['请选择结算方式:', '欠款', '已收款'],
|
|
|
+ success: function (res) {
|
|
|
+ let title = res.tapIndex == 1 ? '确认客户欠款?' : '确认已收款?'
|
|
|
+ let clearType = res.tapIndex == 1 ? 1 : 2;
|
|
|
+ uni.showModal({
|
|
|
+ title: '完成订单提示',
|
|
|
+ content: title,
|
|
|
+ success: function (res) {
|
|
|
+ if (res.confirm) {
|
|
|
+ confirmFinish({id:item.id,clearType:clearType}).then((res) => {
|
|
|
+ uni.showToast({title:res.msg,icon:'none'})
|
|
|
+ self.init();
|
|
|
+ })
|
|
|
+ } else if (res.cancel) {
|
|
|
+ console.log('用户点击取消');
|
|
|
+ }
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ fail: function (res) {
|
|
|
+ console.log(res.errMsg);
|
|
|
+ }
|
|
|
+ });
|
|
|
}
|
|
|
},
|
|
|
copy(val) {
|