|
@@ -113,7 +113,7 @@
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
- <div v-if="item.caution" class="itme_r">备注:{{ item.caution }}</div>
|
|
|
|
|
|
+ <!-- <div v-if="item.caution" class="itme_r">备注:{{ item.caution }}</div> -->
|
|
</div>
|
|
</div>
|
|
</el-col>
|
|
</el-col>
|
|
<!-- 订单追踪、订单详情 -->
|
|
<!-- 订单追踪、订单详情 -->
|
|
@@ -184,13 +184,13 @@
|
|
</el-col>
|
|
</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
<!-- 发起配送 -->
|
|
<!-- 发起配送 -->
|
|
- <send-order-popup ref="sendOrderPopup"></send-order-popup>
|
|
|
|
|
|
+ <send-order-popup :tabNum="tabNum" ref="sendOrderPopup"></send-order-popup>
|
|
<!-- 骑手、商家、发件人地图 -->
|
|
<!-- 骑手、商家、发件人地图 -->
|
|
<order-map ref="orderMap"></order-map>
|
|
<order-map ref="orderMap"></order-map>
|
|
<!-- 备注弹出层 -->
|
|
<!-- 备注弹出层 -->
|
|
<el-dialog width="580px" center title="新增备注" destroy-on-close :visible.sync="dialogTableVisible">
|
|
<el-dialog width="580px" center title="新增备注" destroy-on-close :visible.sync="dialogTableVisible">
|
|
<div>
|
|
<div>
|
|
- <el-input placeholder="请添加备注信息,最多输入20个字!" v-model="remark" :maxlength="20" />
|
|
|
|
|
|
+ <el-input placeholder="请添加备注信息,最多输入20个字!" v-model="remark" clearable :maxlength="20" />
|
|
</div>
|
|
</div>
|
|
<div style="text-align: center; margin-top: 20px">
|
|
<div style="text-align: center; margin-top: 20px">
|
|
<el-button @click.stop="dialogTableVisible = false">取消</el-button>
|
|
<el-button @click.stop="dialogTableVisible = false">取消</el-button>
|
|
@@ -207,11 +207,11 @@
|
|
<span>小时</span>
|
|
<span>小时</span>
|
|
</div>
|
|
</div>
|
|
<p style="color: #f74141">
|
|
<p style="color: #f74141">
|
|
- 提示:设置后系统将根据您设置的提前时间自动发单。
|
|
|
|
|
|
+ 提示:设置后系统将根据您设置的提前时间自动发单。{{delayTime ? '' : '如需骑手立即取件请点击立即配送!'}}
|
|
</p>
|
|
</p>
|
|
<div style="text-align: center; margin-top: 20px">
|
|
<div style="text-align: center; margin-top: 20px">
|
|
- <el-button @click.stop="settingTimeStatus = false">取消预约发单</el-button>
|
|
|
|
- <el-button type="primary" class="submit-btn" @click.stop="commitTimeValue(orderId)">确定修改</el-button>
|
|
|
|
|
|
+ <el-button v-if="delayTime" @click.stop="cancalSettingTime">取消预约发单</el-button>
|
|
|
|
+ <el-button type="primary" class="submit-btn" @click.stop="commitTimeValue(orderId)">{{delayTime ? '确定修改' : '保存'}}</el-button>
|
|
</div>
|
|
</div>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
<!-- 取消订单弹出层 -->
|
|
<!-- 取消订单弹出层 -->
|
|
@@ -354,6 +354,7 @@ export default {
|
|
buttonStatus: 0,
|
|
buttonStatus: 0,
|
|
exceptTime: "",
|
|
exceptTime: "",
|
|
hasLocation: false, // 是否有骑手位置
|
|
hasLocation: false, // 是否有骑手位置
|
|
|
|
+ delayTime: "", // 预约延迟时间
|
|
};
|
|
};
|
|
},
|
|
},
|
|
props: {
|
|
props: {
|
|
@@ -369,13 +370,6 @@ export default {
|
|
},
|
|
},
|
|
watch: {
|
|
watch: {
|
|
tabNum(newVal, oldVal) {
|
|
tabNum(newVal, oldVal) {
|
|
- if (newVal === 0 || newVal === 1) {
|
|
|
|
- this.needTrack = false;
|
|
|
|
- this.orderDetailStutus = 1;
|
|
|
|
- } else {
|
|
|
|
- this.needTrack = true;
|
|
|
|
- this.orderDetailStutus = 0;
|
|
|
|
- }
|
|
|
|
this.curIdx = 0;
|
|
this.curIdx = 0;
|
|
},
|
|
},
|
|
list(newVal, oldVal) {
|
|
list(newVal, oldVal) {
|
|
@@ -399,6 +393,7 @@ export default {
|
|
this.showCode = false;
|
|
this.showCode = false;
|
|
this.addTipStatus = false;
|
|
this.addTipStatus = false;
|
|
bus.$emit("refreshData");
|
|
bus.$emit("refreshData");
|
|
|
|
+ bus.$emit("refreshData2");
|
|
},
|
|
},
|
|
richMoney() {
|
|
richMoney() {
|
|
let reg = /(^[1-9]\d*$)/g;
|
|
let reg = /(^[1-9]\d*$)/g;
|
|
@@ -426,6 +421,7 @@ export default {
|
|
type: "success",
|
|
type: "success",
|
|
});
|
|
});
|
|
bus.$emit("refreshData");
|
|
bus.$emit("refreshData");
|
|
|
|
+ bus.$emit("refreshData2");
|
|
this.addTipStatus = false;
|
|
this.addTipStatus = false;
|
|
this.tipAmount = "";
|
|
this.tipAmount = "";
|
|
} else if (this.paymentType == 1 || this.paymentType == 2) {
|
|
} else if (this.paymentType == 1 || this.paymentType == 2) {
|
|
@@ -471,7 +467,6 @@ export default {
|
|
cancelReason:
|
|
cancelReason:
|
|
this.reasonIndex != 8 ? this.chooseReason : this.cancelReason,
|
|
this.reasonIndex != 8 ? this.chooseReason : this.cancelReason,
|
|
}).then((res) => {
|
|
}).then((res) => {
|
|
- this.cancelStatus = false;
|
|
|
|
if (res.code == 200) {
|
|
if (res.code == 200) {
|
|
this.$message({
|
|
this.$message({
|
|
message: "取消订单成功",
|
|
message: "取消订单成功",
|
|
@@ -482,6 +477,8 @@ export default {
|
|
this.chooseReason = "";
|
|
this.chooseReason = "";
|
|
this.reasonIndex = null;
|
|
this.reasonIndex = null;
|
|
bus.$emit("refreshData");
|
|
bus.$emit("refreshData");
|
|
|
|
+ bus.$emit("refreshData2");
|
|
|
|
+ this.cancelStatus = false;
|
|
} else {
|
|
} else {
|
|
this.$message({
|
|
this.$message({
|
|
message: res.msg,
|
|
message: res.msg,
|
|
@@ -490,8 +487,9 @@ export default {
|
|
}
|
|
}
|
|
});
|
|
});
|
|
},
|
|
},
|
|
|
|
+ // 取消定时发单
|
|
cancalSettingTime() {
|
|
cancalSettingTime() {
|
|
- cancelTimingPublish({ orderId: this.item.orderId }).then((res) => {
|
|
|
|
|
|
+ cancelTimingPublish({ orderId: this.item.id }).then((res) => {
|
|
this.settingTimeStatus = false;
|
|
this.settingTimeStatus = false;
|
|
if (res.code == 200) {
|
|
if (res.code == 200) {
|
|
this.$message({
|
|
this.$message({
|
|
@@ -500,6 +498,7 @@ export default {
|
|
});
|
|
});
|
|
this.item = {};
|
|
this.item = {};
|
|
bus.$emit("refreshData");
|
|
bus.$emit("refreshData");
|
|
|
|
+ bus.$emit("refreshData2");
|
|
} else {
|
|
} else {
|
|
this.$message({
|
|
this.$message({
|
|
message: res.msg,
|
|
message: res.msg,
|
|
@@ -534,6 +533,7 @@ export default {
|
|
});
|
|
});
|
|
this.item = {};
|
|
this.item = {};
|
|
bus.$emit("refreshData");
|
|
bus.$emit("refreshData");
|
|
|
|
+ bus.$emit("refreshData2");
|
|
} else {
|
|
} else {
|
|
this.$message({
|
|
this.$message({
|
|
message: res.msg,
|
|
message: res.msg,
|
|
@@ -546,6 +546,7 @@ export default {
|
|
settingTime(item) {
|
|
settingTime(item) {
|
|
this.item = item;
|
|
this.item = item;
|
|
this.settingTimeStatus = true;
|
|
this.settingTimeStatus = true;
|
|
|
|
+ this.delayTime = item.delayTime;
|
|
this.timeValue = item.delayTime ? item.delayTime : 1;
|
|
this.timeValue = item.delayTime ? item.delayTime : 1;
|
|
this.exceptTime = `预约期望${item.exceptTime.slice(5)}送达`;
|
|
this.exceptTime = `预约期望${item.exceptTime.slice(5)}送达`;
|
|
},
|
|
},
|
|
@@ -584,6 +585,7 @@ export default {
|
|
message: "已忽略!",
|
|
message: "已忽略!",
|
|
});
|
|
});
|
|
bus.$emit("refreshData");
|
|
bus.$emit("refreshData");
|
|
|
|
+ bus.$emit("refreshData2");
|
|
} else {
|
|
} else {
|
|
this.$message({
|
|
this.$message({
|
|
message: res.msg,
|
|
message: res.msg,
|
|
@@ -607,6 +609,12 @@ export default {
|
|
},
|
|
},
|
|
// 一键发单备注
|
|
// 一键发单备注
|
|
commitRemark(orderId, item) {
|
|
commitRemark(orderId, item) {
|
|
|
|
+ // if(!this.remark.trim()){
|
|
|
|
+ // return this.$message({
|
|
|
|
+ // message: '请输入发单备注再确认!',
|
|
|
|
+ // type: "error",
|
|
|
|
+ // });
|
|
|
|
+ // }
|
|
let params = {
|
|
let params = {
|
|
orderId,
|
|
orderId,
|
|
remark: this.remark.trim(),
|
|
remark: this.remark.trim(),
|
|
@@ -618,14 +626,16 @@ export default {
|
|
message: "添加备注成功",
|
|
message: "添加备注成功",
|
|
type: "success",
|
|
type: "success",
|
|
});
|
|
});
|
|
- this.$set(
|
|
|
|
- this.list.find((v) => {
|
|
|
|
- return item.id == v.id;
|
|
|
|
- }),
|
|
|
|
- "takeRemark",
|
|
|
|
- this.remark
|
|
|
|
- );
|
|
|
|
- this.$forceUpdate();
|
|
|
|
|
|
+ bus.$emit("refreshData");
|
|
|
|
+ bus.$emit("refreshData2");
|
|
|
|
+ // this.$set(
|
|
|
|
+ // this.list.find((v) => {
|
|
|
|
+ // return item.id == v.id;
|
|
|
|
+ // }),
|
|
|
|
+ // "takeRemark",
|
|
|
|
+ // this.remark
|
|
|
|
+ // );
|
|
|
|
+ // this.$forceUpdate();
|
|
} else {
|
|
} else {
|
|
this.$message({
|
|
this.$message({
|
|
message: res.msg,
|
|
message: res.msg,
|
|
@@ -660,6 +670,7 @@ export default {
|
|
type: "success",
|
|
type: "success",
|
|
});
|
|
});
|
|
bus.$emit("refreshData");
|
|
bus.$emit("refreshData");
|
|
|
|
+ bus.$emit("refreshData2");
|
|
} else {
|
|
} else {
|
|
this.$message({
|
|
this.$message({
|
|
message: res.msg,
|
|
message: res.msg,
|