【类 型】:fix
【主 题】:table.js写上了参数的详细注释 更改两个执行任务 取消任务bug 【描 述】: [原因]:数据库status字段修改以前是数字表示状态 现改为枚举类型 [过程]: [影响]: 【结 束】 # 类型 包含: # feat:新功能(feature) # fix:修补bug # docs:文档(documentation) # style: 格式(不影响代码运行的变动) # refactor:重构(即不是新增功能,也不是修改bug的代码变动) # test:增加测试 # chore:构建过程或辅助工具的变动
This commit is contained in:
parent
85a46cc161
commit
fcdf5958f6
@ -398,7 +398,7 @@ export default {
|
|||||||
/* 插入日志 */
|
/* 插入日志 */
|
||||||
this.$store.dispatch('fetchLog', { content: `${this.plane.name} 开始执行 订单ID:${item.id}、叫餐号:${item.food_sn}号。` })
|
this.$store.dispatch('fetchLog', { content: `${this.plane.name} 开始执行 订单ID:${item.id}、叫餐号:${item.food_sn}号。` })
|
||||||
/* 执行写在这里 */
|
/* 执行写在这里 */
|
||||||
if (item.bind_route === null) { // 判断站点是否已经绑定站点 中断操作
|
if (item.bind_route === null) { // 判断站点是否已经绑定站点 未绑定 中断操作
|
||||||
this.$message.error('此站点,未绑定任务航点')
|
this.$message.error('此站点,未绑定任务航点')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -420,7 +420,7 @@ export default {
|
|||||||
this.$message.error('操作失败,请重新尝试')
|
this.$message.error('操作失败,请重新尝试')
|
||||||
}
|
}
|
||||||
this.publishFun(`{"questAss":${routeData}}`)// 发送航点信息主题
|
this.publishFun(`{"questAss":${routeData}}`)// 发送航点信息主题
|
||||||
this.questAss(item.id, 'status', '30')// 订单改为发货状态
|
this.questAss(item.id, 'status', 'shipped')// 订单改为发货状态
|
||||||
this.$store.dispatch('fetchLockSite', { id: item.receive_site_id, runing: this.plane.id })// 航线注册飞机 锁定送餐点
|
this.$store.dispatch('fetchLockSite', { id: item.receive_site_id, runing: this.plane.id })// 航线注册飞机 锁定送餐点
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -464,7 +464,7 @@ export default {
|
|||||||
* @description: 取消任务
|
* @description: 取消任务
|
||||||
*/
|
*/
|
||||||
reQuest () {
|
reQuest () {
|
||||||
if (!this.airLock) { // 只有飞机锁定状态 才向量下执行 "取消"操作
|
if (!this.airLock) { // 只有飞机锁定状态 才向下执行 "取消"操作
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.$confirm('确认复位飞机状态,并清除航线的锁定?', '取消任务', {
|
this.$confirm('确认复位飞机状态,并清除航线的锁定?', '取消任务', {
|
||||||
@ -478,7 +478,8 @@ export default {
|
|||||||
this.$store.dispatch('fetchLog', { content: `订单ID:${item.id},送餐任务取消。` })
|
this.$store.dispatch('fetchLog', { content: `订单ID:${item.id},送餐任务取消。` })
|
||||||
/* 执行写在这里 */
|
/* 执行写在这里 */
|
||||||
this.publishFun('{"resetState":1}')// 发送设置飞机状态主题 状态设为闲置
|
this.publishFun('{"resetState":1}')// 发送设置飞机状态主题 状态设为闲置
|
||||||
this.questAss(item.id, 'status', '20')// 订单改回到发货状态之前 既“已付款状态”
|
this.questAss(item.id, 'status', 'pending')// 订单改回到发货状态之前 既“已付款状态”
|
||||||
|
console.log('hi')
|
||||||
this.$store.dispatch('fetchLockSite', { id: item.receive_site_id, runing: 'null' })// 解锁航线
|
this.$store.dispatch('fetchLockSite', { id: item.receive_site_id, runing: 'null' })// 解锁航线
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -505,7 +506,7 @@ export default {
|
|||||||
this.$store.dispatch('fetchLog', { content: `订单ID:${item.id} 送餐任务已完成。` })
|
this.$store.dispatch('fetchLog', { content: `订单ID:${item.id} 送餐任务已完成。` })
|
||||||
/* 执行写在这里 */
|
/* 执行写在这里 */
|
||||||
this.publishFun('{"resetState":1}')// 发送设置飞机状态主题 状态设为闲置
|
this.publishFun('{"resetState":1}')// 发送设置飞机状态主题 状态设为闲置
|
||||||
this.questAss(item.id, 'status', '40')// 订单改为已完成状态
|
this.questAss(item.id, 'status', 'completed')// 订单改为已完成状态
|
||||||
this.$store.dispatch('fetchLockSite', { id: item.receive_site_id, runing: 'null' })// 解锁航线
|
this.$store.dispatch('fetchLockSite', { id: item.receive_site_id, runing: 'null' })// 解锁航线
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -536,9 +537,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
setTimeout(() => {
|
console.log(this.questList)
|
||||||
console.log(this.$store.state.orderList)
|
|
||||||
}, 3000)
|
|
||||||
if (this.siteList && this.routeList) {
|
if (this.siteList && this.routeList) {
|
||||||
this.airLock = this.siteList.some(item => item.runing === this.planesId)
|
this.airLock = this.siteList.some(item => item.runing === this.planesId)
|
||||||
}
|
}
|
||||||
|
@ -22,6 +22,20 @@ export async function apiCrosFrequency (params) {
|
|||||||
* @description: 向改变订单承接任务api 提交数据 ()
|
* @description: 向改变订单承接任务api 提交数据 ()
|
||||||
* @param {*} id 订单id
|
* @param {*} id 订单id
|
||||||
* @param {*} state "status"修改status字段 "back"修改back字段
|
* @param {*} state "status"修改status字段 "back"修改back字段
|
||||||
|
* @param {*} val 修改字段的值 status包括
|
||||||
|
* canceled:交易取消
|
||||||
|
* unpaid:未付款
|
||||||
|
* pending:处理中(已付款)
|
||||||
|
* processing:备货中
|
||||||
|
* shipped:已发货
|
||||||
|
* completed:已完成
|
||||||
|
* closed:交易关闭
|
||||||
|
* back包括
|
||||||
|
* normal:未申请
|
||||||
|
* requested:申请退款
|
||||||
|
* refunded:已经退款
|
||||||
|
* rejected:拒绝退款
|
||||||
|
* actively:商家主动取消订单并退款
|
||||||
*/
|
*/
|
||||||
export function questAss (id, state, val) {
|
export function questAss (id, state, val) {
|
||||||
const data = new URLSearchParams()// post对象参数 转成 字符串连接
|
const data = new URLSearchParams()// post对象参数 转成 字符串连接
|
||||||
|
Loading…
Reference in New Issue
Block a user