【类 型】:factor

【主	题】:飞机订单操作
【描	述】:
	[原因]:防止不能进入 飞机航线注册状态
	[过程]:先注册 注销航线 确认返回 再改订单状态
	[影响]:
【结	束】

# 类型 包含:
# feat:新功能(feature)
# fix:修补bug
# docs:文档(documentation)
# style: 格式(不影响代码运行的变动)
# refactor:重构(即不是新增功能,也不是修改bug的代码变动)
# test:增加测试
# chore:构建过程或辅助工具的变动
This commit is contained in:
szdot 2024-07-12 06:16:26 +08:00
parent ebc8880d26
commit 34180d722b

View File

@ -465,7 +465,8 @@ export default {
/* 站点正在执行任务runing 注册 */ /* 站点正在执行任务runing 注册 */
const runing = (this.currentOrder.runing ?? '').split(',') const runing = (this.currentOrder.runing ?? '').split(',')
let foundEmpty = false let foundEmpty = false
let selIndex // 使线 let selIndex // 使线
runing.some((item, index, arr) => { runing.some((item, index, arr) => {
if (item === '') { if (item === '') {
arr[index] = this.plane.id arr[index] = this.plane.id
@ -474,6 +475,7 @@ export default {
return true // 退 return true // 退
} }
}) })
newRuning = runing.join(',') newRuning = runing.join(',')
if (!foundEmpty) { if (!foundEmpty) {
this.$message({ this.$message({
@ -499,9 +501,9 @@ export default {
this.$message.error('操作失败,航线异常') this.$message.error('操作失败,航线异常')
return return
} }
let res = await this.questAss(this.currentOrder.id, 'shipment_status', '已发货')// let res = await this.$store.dispatch('fetchLockSite', { id: this.currentOrder.receive_site_id, shop_id: this.plane.shop_id, runing: newRuning })// 线
if (res.data.status === 1) { if (res.data.status === 1) {
res = await this.$store.dispatch('fetchLockSite', { id: this.currentOrder.receive_site_id, shop_id: this.plane.shop_id, runing: newRuning })// 线 res = await this.questAss(this.currentOrder.id, 'shipment_status', '已发货')//
if (res.data.status === 1) { if (res.data.status === 1) {
this.publishFun(`{"questAss":${routeData}}`)// this.publishFun(`{"questAss":${routeData}}`)//
this.speakText('提交任务,注册航线。') this.speakText('提交任务,注册航线。')
@ -574,9 +576,9 @@ export default {
}) })
/* 确认 把订单从发货退回到已接单 站点runing字段飞机航线注销 重置飞机状态 */ /* 确认 把订单从发货退回到已接单 站点runing字段飞机航线注销 重置飞机状态 */
if (found) { if (found) {
this.questAss(orderId, 'shipment_status', '已接单').then(res => { // 退 this.$store.dispatch('fetchLockSite', { id: receiveSiteId, shop_id: this.plane.shop_id, runing: newRuning }).then(res => { // 退
if (res.data.status === 1) { if (res.data.status === 1) {
this.$store.dispatch('fetchLockSite', { id: receiveSiteId, shop_id: this.plane.shop_id, runing: newRuning }).then(res => { // 线 this.questAss(orderId, 'shipment_status', '已接单').then(res => { // 线
if (res.data.status === 1) { if (res.data.status === 1) {
this.publishFun('{"resetState":1}')// this.publishFun('{"resetState":1}')//
} }
@ -619,9 +621,9 @@ export default {
}) })
/* 确认 把订单从发货退回到已接单 站点runing字段飞机航线注销 重置飞机状态 */ /* 确认 把订单从发货退回到已接单 站点runing字段飞机航线注销 重置飞机状态 */
if (found) { if (found) {
this.questAss(orderId, 'shipment_status', '已送达').then(res => { // this.$store.dispatch('fetchLockSite', { id: receiveSiteId, shop_id: this.plane.shop_id, runing: newRuning }).then(res => { //
if (res.data.status === 1) { if (res.data.status === 1) {
this.$store.dispatch('fetchLockSite', { id: receiveSiteId, shop_id: this.plane.shop_id, runing: newRuning }).then(res => { // 线 this.questAss(orderId, 'shipment_status', '已送达').then(res => { // 线
if (res.data.status === 1) { if (res.data.status === 1) {
this.publishFun('{"resetState":1}')// this.publishFun('{"resetState":1}')//
} }
@ -722,7 +724,7 @@ export default {
this.publishFun('{getPlaneState:1}') this.publishFun('{getPlaneState:1}')
}, },
ShippedList (val) { ShippedList (val) {
console.log(val) // console.log(val)
} }
} }