任务管理查询时间,取消任务,重新下发

master
Mr.sun 2 years ago
parent a5c41b8779
commit 96be887eec
  1. 16
      src/api/wcs/busFunctions/taskManagement.js
  2. 26
      src/views/taskManagement/index.vue

@ -9,3 +9,19 @@ export function queryTaskManagement(data) {
params:data params:data
}) })
} }
// 查询任务管理列表
export function cancelTask(data) {
return request({
url: 'wms/datatask/cancelTask',
method: 'post',
data:data
})
}
// 查询任务管理列表
export function reissueTask(data) {
return request({
url: 'wms/datatask/reissueTask',
method: 'post',
data:data
})
}

@ -267,7 +267,7 @@
<script> <script>
import { getBasePointGroup, updatePoint, addPoint } from '@/api/wcs/base/agvPoint.js' import { getBasePointGroup, updatePoint, addPoint } from '@/api/wcs/base/agvPoint.js'
import { getWcsDeviceList } from '@/api/wcs/base/wcsDevice.js' import { getWcsDeviceList } from '@/api/wcs/base/wcsDevice.js'
import { queryTaskManagement, instantlyTask } from '@/api/wcs/busFunctions/taskManagement.js' import { queryTaskManagement, reissueTask, cancelTask } from '@/api/wcs/busFunctions/taskManagement.js'
import moment from 'moment' import moment from 'moment'
// import { getTableHeader } from '@/api/wms/tableHeader/table' // import { getTableHeader } from '@/api/wms/tableHeader/table'
export default { export default {
@ -588,13 +588,13 @@ export default {
/** 查询区域列表 */ /** 查询区域列表 */
getList() { getList() {
this.loading = true this.loading = true
// if (this.value1 !== null && this.value1 !== 'null' && this.value1 !== undefined) { if (this.value1 !== null && this.value1 !== 'null' && this.value1 !== undefined) {
// this.queryParams.createTimeS = this.value1[0] this.queryParams.createTimeS = this.value1[0]
// this.queryParams.createTimeE = this.value1[1] this.queryParams.createTimeE = this.value1[1]
// } else { } else {
// this.queryParams.createTimeS = null this.queryParams.createTimeS = null
// this.queryParams.createTimeE = null this.queryParams.createTimeE = null
// } }
queryTaskManagement(this.queryParams).then((res) => { queryTaskManagement(this.queryParams).then((res) => {
this.cheshiList = res.rows this.cheshiList = res.rows
this.paging.total = res.total this.paging.total = res.total
@ -646,7 +646,12 @@ export default {
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
this.$modal.msgSuccess('取消成功') cancelTask({ taskId: row.taskId }).then((res) => {
if (res.code === 200) {
this.$message.success('取消成功')
this.reset()
}
})
}) })
}, },
@ -659,11 +664,10 @@ export default {
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
instantlyTask(row.taskId).then((res) => { reissueTask({ taskId: row.taskId }).then((res) => {
// console.log(res) // console.log(res)
if (res.code === 200) { if (res.code === 200) {
this.$message.success('立即下发成功') this.$message.success('立即下发成功')
console.log(res)
this.reset() this.reset()
} }
}) })

Loading…
Cancel
Save