代码更新:
1.修改报错弹框样式
This commit is contained in:
parent
ca2c30eb85
commit
1326ab0b33
|
|
@ -56,9 +56,9 @@ const finishPickingAndBack = (params) => {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const changeTaskStatus = (params) => {
|
const updateTaskInfo = (params) => {
|
||||||
return request({
|
return request({
|
||||||
url: '/taskDeal/changeTaskStatus',
|
url: '/taskMonitor/updateTaskInfo',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: params
|
data: params
|
||||||
})
|
})
|
||||||
|
|
@ -199,7 +199,7 @@ export {
|
||||||
finishInventoryTask,
|
finishInventoryTask,
|
||||||
getTasks,
|
getTasks,
|
||||||
finishPickingAndBack,
|
finishPickingAndBack,
|
||||||
changeTaskStatus,
|
updateTaskInfo,
|
||||||
getWorkByStandAndGoods,
|
getWorkByStandAndGoods,
|
||||||
confirmFinishedWork,
|
confirmFinishedWork,
|
||||||
confirmFinishWork,
|
confirmFinishWork,
|
||||||
|
|
|
||||||
|
|
@ -90,8 +90,8 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { callEmptyVehicle } from '@/api/task'
|
import { callEmptyVehicle } from '@/api/task'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { reactive, ref } from 'vue'
|
import { reactive, ref } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
@ -216,17 +216,11 @@ export default {
|
||||||
},
|
},
|
||||||
confirmTask() {
|
confirmTask() {
|
||||||
if (this.workFormEntity.vehicleType2 == '') {
|
if (this.workFormEntity.vehicleType2 == '') {
|
||||||
ElMessage({
|
errorBox('请选择物料种类')
|
||||||
message: '请选择物料种类',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (this.workFormEntity.needNum <= 0) {
|
if (this.workFormEntity.needNum <= 0) {
|
||||||
ElMessage({
|
errorBox('料箱数量必须为大于0的整数')
|
||||||
message: '料箱数量必须为大于0的整数',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const request = {
|
const request = {
|
||||||
|
|
@ -239,17 +233,14 @@ export default {
|
||||||
callEmptyVehicle(request).then(res => {
|
callEmptyVehicle(request).then(res => {
|
||||||
const response = res.data
|
const response = res.data
|
||||||
if (response.code == 0) {
|
if (response.code == 0) {
|
||||||
ElMessage({
|
successBox(response.message)
|
||||||
message: response.message,
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('出空箱异常')
|
errorBox('出空箱异常')
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -235,8 +235,8 @@ import store from '@/store'
|
||||||
import { getClcKanbanRequirement } from '@/api/kateWork'
|
import { getClcKanbanRequirement } from '@/api/kateWork'
|
||||||
import { downloadClcKanbanRequirementExcel } from '@/api/excel'
|
import { downloadClcKanbanRequirementExcel } from '@/api/excel'
|
||||||
import { dateFormatter } from '@/utils/formatter.js'
|
import { dateFormatter } from '@/utils/formatter.js'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { reactive, ref } from 'vue'
|
import { reactive, ref } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
@ -300,15 +300,15 @@ export default {
|
||||||
this.workFormEntity.NumOfBoxOf811 = response.returnData.NumOfBoxOf811
|
this.workFormEntity.NumOfBoxOf811 = response.returnData.NumOfBoxOf811
|
||||||
this.workFormEntity.NumOfBoxOf911 = response.returnData.NumOfBoxOf911
|
this.workFormEntity.NumOfBoxOf911 = response.returnData.NumOfBoxOf911
|
||||||
this.workFormEntity.NumOfBoxOf822 = response.returnData.NumOfBoxOf822
|
this.workFormEntity.NumOfBoxOf822 = response.returnData.NumOfBoxOf822
|
||||||
ElMessage.success("获取CLC看板需求成功。")
|
successBox("获取CLC看板需求成功。")
|
||||||
} else {
|
} else {
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
ElMessage.error('获取CLC看板需求错误')
|
errorBox('获取CLC看板需求错误')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
resetForms() {
|
resetForms() {
|
||||||
|
|
@ -353,18 +353,12 @@ export default {
|
||||||
document.body.removeChild(link)
|
document.body.removeChild(link)
|
||||||
url.revokeObjectURL(link.href)//移除url对象
|
url.revokeObjectURL(link.href)//移除url对象
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
ElMessage({
|
console.log(e)
|
||||||
message: '下载文件失败:: ' + e,
|
errorBox('下载文件失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage({
|
console.log(err)
|
||||||
message: '导出失败:: ' + err,
|
errorBox('导出失败:')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -183,6 +183,7 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { clcNoPlan, clcNoPlanConfirmBack } from '@/api/task'
|
import { clcNoPlan, clcNoPlanConfirmBack } from '@/api/task'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { getStockNumByGoodsId } from '@/api/stock'
|
import { getStockNumByGoodsId } from '@/api/stock'
|
||||||
import { reactive, ref } from 'vue'
|
import { reactive, ref } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
|
|
@ -235,12 +236,12 @@ export default {
|
||||||
this.workFormEntity.stockNum = response.returnData.remainNum
|
this.workFormEntity.stockNum = response.returnData.remainNum
|
||||||
} else {
|
} else {
|
||||||
this.workFormEntity.stockNum = 0
|
this.workFormEntity.stockNum = 0
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
this.workFormEntity.stockNum = null
|
this.workFormEntity.stockNum = null
|
||||||
ElMessage.error('查询库存余量发生错误。')
|
errorBox('查询库存余量发生错误。')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCurrentGoodsPickNumMethod() {
|
getCurrentGoodsPickNumMethod() {
|
||||||
|
|
@ -257,76 +258,75 @@ export default {
|
||||||
// 重置参数
|
// 重置参数
|
||||||
resetForms() {
|
resetForms() {
|
||||||
this.workFormEntity = reactive({
|
this.workFormEntity = reactive({
|
||||||
goodsId: '',
|
|
||||||
planPickNum: 0,
|
|
||||||
remainNumOrigin: null,
|
|
||||||
remainNumReal: null,
|
|
||||||
remark: '',
|
|
||||||
finishedRows: 0,
|
|
||||||
totalRows: 0,
|
|
||||||
finishedCounts: 0,
|
|
||||||
totalCounts: 0,
|
|
||||||
tip: ''
|
|
||||||
})
|
|
||||||
this.$refs.goodsId.focus()
|
|
||||||
},
|
|
||||||
// 确认完成工作
|
|
||||||
createTask() {
|
|
||||||
if (this.standId == '' || this.workFormEntity.goodsId == '') {
|
|
||||||
ElMessage({
|
|
||||||
message: '站台号和料号不可缺少',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
const requestParams = {
|
|
||||||
goodsId: '',
|
goodsId: '',
|
||||||
stockNum: null,
|
stockNum: null,
|
||||||
needNum: null,
|
needNum: null,
|
||||||
workOrder: '',
|
workOrder: '',
|
||||||
smallVehicleNo: '',
|
smallVehicleNo: '',
|
||||||
callReason: '',
|
callReason: ''
|
||||||
|
})
|
||||||
|
this.$refs.goodsId.focus()
|
||||||
|
},
|
||||||
|
resetConfirmForms() {
|
||||||
|
this.confirmFormEntity = reactive({
|
||||||
|
vehicleId: '',
|
||||||
|
goodsId: '',
|
||||||
|
realPickNum: null
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 确认完成工作
|
||||||
|
createTask() {
|
||||||
|
if (this.standId == '' || this.workFormEntity.goodsId == '') {
|
||||||
|
errorBox('站台号和料号不可缺少')
|
||||||
|
return
|
||||||
|
}
|
||||||
|
const requestParams = {
|
||||||
|
goodsId: this.workFormEntity.goodsId,
|
||||||
|
stockNum: this.workFormEntity.stockNum,
|
||||||
|
needNum: this.workFormEntity.needNum,
|
||||||
|
workOrder: this.workFormEntity.workOrder,
|
||||||
|
smallVehicleNo: this.workFormEntity.smallVehicleNo,
|
||||||
|
callReason: this.workFormEntity.callReason,
|
||||||
standId: this.standId,
|
standId: this.standId,
|
||||||
userName: store.getters.getUserName
|
userName: store.getters.getUserName
|
||||||
}
|
}
|
||||||
clcNoPlan(requestParams).then(res => {
|
clcNoPlan(requestParams).then(res => {
|
||||||
const response = res.data
|
const response = res.data
|
||||||
if (response.code == 0) {
|
if (response.code == 0) {
|
||||||
ElMessage.success(response.message)
|
successBox(response.message)
|
||||||
|
this.resetForms()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('请求时发生异常。')
|
errorBox('请求时发生异常。')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 确认回库
|
// 确认回库
|
||||||
confirmPick() {
|
confirmPick() {
|
||||||
if (this.standId == '' || this.workFormEntity.goodsId == '') {
|
if (this.standId == '' || this.workFormEntity.goodsId == '') {
|
||||||
ElMessage({
|
errorBox('站台号和料号不可缺少')
|
||||||
message: '站台号和料号不可缺少',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const confirmParams = {
|
const confirmParams = {
|
||||||
standId: this.standId,
|
standId: this.standId,
|
||||||
goodsId: this.workFormEntity.goodsId,
|
goodsId: this.confirmFormEntity.goodsId,
|
||||||
vehicleId: this.workFormEntity.vehicleId,
|
vehicleId: this.confirmFormEntity.vehicleId,
|
||||||
realPickNum: this.workFormEntity.realPickNum,
|
realPickNum: this.confirmFormEntity.realPickNum,
|
||||||
userName: store.getters.getUserName
|
userName: store.getters.getUserName
|
||||||
}
|
}
|
||||||
clcNoPlanConfirmBack(confirmParams).then(res => {
|
clcNoPlanConfirmBack(confirmParams).then(res => {
|
||||||
const response = res.data
|
const response = res.data
|
||||||
if (response.code == 0) {
|
if (response.code == 0) {
|
||||||
ElMessage.success(response.message)
|
successBox(response.message)
|
||||||
|
this.resetConfirmForms()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('确认时发生异常。')
|
errorBox('确认时发生异常。')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -131,7 +131,8 @@
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getDbs, deleteDbs, updateDbs } from '@/api/kateWork.js'
|
import { getDbs, deleteDbs, updateDbs } from '@/api/kateWork.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
import { ElMessageBox } from 'element-plus'
|
||||||
|
import { errorBox, infoBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import UploadExcelDbs from '@/excel/UploadExcelDbs.vue'
|
import UploadExcelDbs from '@/excel/UploadExcelDbs.vue'
|
||||||
|
|
@ -181,10 +182,11 @@ export default {
|
||||||
this.dbsList = tableResponse.returnData.lists
|
this.dbsList = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('查询DBS错误' + err.message)
|
console.log(err)
|
||||||
|
errorBox('查询DBS错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -229,23 +231,17 @@ export default {
|
||||||
}
|
}
|
||||||
deleteDbs(params).then(res => {
|
deleteDbs(params).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
ElMessage({
|
successBox('删除DBS信息成功')
|
||||||
message: '删除DBS信息成功',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('删除DBS信息成功')
|
errorBox('删除DBS信息成功')
|
||||||
})
|
})
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
ElMessage({
|
infoBox('操作取消')
|
||||||
type: 'info',
|
|
||||||
message: '操作取消',
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
submitDbsInfo(formData) {
|
submitDbsInfo(formData) {
|
||||||
|
|
@ -260,16 +256,14 @@ export default {
|
||||||
updateDbs(params).then(res => {
|
updateDbs(params).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('更新DBS成功。')
|
||||||
message: '更新DBS成功。',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('更新DBS失败。')
|
console.log(err)
|
||||||
|
errorBox('更新DBS失败。')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCurrentRow(row) {
|
getCurrentRow(row) {
|
||||||
|
|
@ -303,7 +297,7 @@ export default {
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('发生异常')
|
errorBox('发生异常')
|
||||||
})
|
})
|
||||||
this.uploadDialogVisible = true
|
this.uploadDialogVisible = true
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -24,10 +24,10 @@
|
||||||
label-width="150px" style="max-width: 100%" :rules="rules" status-icon>
|
label-width="150px" style="max-width: 100%" :rules="rules" status-icon>
|
||||||
<div style="display: flex;">
|
<div style="display: flex;">
|
||||||
<div style="display: block; margin: 5px;">
|
<div style="display: block; margin: 5px;">
|
||||||
<el-dialog v-model="dialogVisible" title="提醒" width="40%" draggable
|
<!-- <el-dialog v-model="dialogVisible" title="提醒" width="40%" draggable
|
||||||
:show-close="true">
|
:show-close="true">
|
||||||
<span style="color: green; margin-right: 16px; font-size: 35px;"> {{ workFormEntity.tip }}</span>
|
<span style="color: green; margin-right: 16px; font-size: 35px;"> {{ workFormEntity.tip }}</span>
|
||||||
</el-dialog>
|
</el-dialog> -->
|
||||||
<div style="display: flex;">
|
<div style="display: flex;">
|
||||||
<div style="display: flex; flex-direction: column;">
|
<div style="display: flex; flex-direction: column;">
|
||||||
<div class="display-title-div">
|
<div class="display-title-div">
|
||||||
|
|
@ -140,8 +140,8 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getWorkByStandAndGoods, confirmFinishWork, queryFinishByStandAndGoods } from '@/api/task'
|
import { getWorkByStandAndGoods, confirmFinishWork, queryFinishByStandAndGoods } from '@/api/task'
|
||||||
|
import { errorBox, successBox, warningBox } from '@/utils/myMessageBox.js'
|
||||||
import { reactive, ref } from 'vue'
|
import { reactive, ref } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
@ -171,7 +171,6 @@ export default {
|
||||||
{ required: true, message: '请输入料号' }
|
{ required: true, message: '请输入料号' }
|
||||||
]
|
]
|
||||||
}),
|
}),
|
||||||
dialogVisible: false,
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
|
@ -206,16 +205,16 @@ export default {
|
||||||
this.workFormEntity.tip = response.returnData.tip
|
this.workFormEntity.tip = response.returnData.tip
|
||||||
if (this.workFormEntity.remainNumOrigin == 0) {
|
if (this.workFormEntity.remainNumOrigin == 0) {
|
||||||
this.workFormEntity.tip = "理论剩余库存为0,请确认。"
|
this.workFormEntity.tip = "理论剩余库存为0,请确认。"
|
||||||
this.dialogVisible = true
|
warningBox(this.workFormEntity.tip)
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
ElMessage.error('查询工作信息错误')
|
errorBox('查询工作信息错误')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 查询是否完成
|
// 查询是否完成
|
||||||
|
|
@ -232,18 +231,9 @@ export default {
|
||||||
if (response.code == 0) {
|
if (response.code == 0) {
|
||||||
if (response.returnData != null && response.returnData.tip != '') {
|
if (response.returnData != null && response.returnData.tip != '') {
|
||||||
this.workFormEntity.tip = response.returnData.tip
|
this.workFormEntity.tip = response.returnData.tip
|
||||||
this.dialogVisible = true
|
warningBox(this.workFormEntity.tip)
|
||||||
// ElMessage({
|
|
||||||
// message: response.returnData.tip,
|
|
||||||
// type: 'warning',
|
|
||||||
// showClose: true
|
|
||||||
// })
|
|
||||||
} else {
|
} else {
|
||||||
ElMessage({
|
successBox(response.message)
|
||||||
message: response.message,
|
|
||||||
type: 'success',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
}
|
}
|
||||||
|
|
@ -263,10 +253,7 @@ export default {
|
||||||
// 确认完成工作
|
// 确认完成工作
|
||||||
confirmTask() {
|
confirmTask() {
|
||||||
if (this.standId == '' || this.workFormEntity.goodsId == '') {
|
if (this.standId == '' || this.workFormEntity.goodsId == '') {
|
||||||
ElMessage({
|
errorBox('站台号和料号不可缺少')
|
||||||
message: '站台号和料号不可缺少',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const confirmParams = {
|
const confirmParams = {
|
||||||
|
|
@ -283,13 +270,13 @@ export default {
|
||||||
this.workFormEntity.tip = response.returnData.tip
|
this.workFormEntity.tip = response.returnData.tip
|
||||||
}
|
}
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
ElMessage.success(response.message)
|
successBox(response.message)
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('确认时发生异常')
|
errorBox('确认时发生异常')
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -85,6 +85,7 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
|
|
|
||||||
|
|
@ -85,6 +85,7 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
|
|
|
||||||
|
|
@ -139,8 +139,8 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getFinishedWorkInfo, confirmFinishedWork, requestPrintData } from '@/api/task'
|
import { getFinishedWorkInfo, confirmFinishedWork, requestPrintData } from '@/api/task'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { reactive, ref } from 'vue'
|
import { reactive, ref } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
@ -199,7 +199,7 @@ export default {
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
ElMessage.error('查询工作信息错误')
|
errorBox('查询工作信息错误')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
resetForms() {
|
resetForms() {
|
||||||
|
|
@ -215,10 +215,7 @@ export default {
|
||||||
confirmWork() {
|
confirmWork() {
|
||||||
console.log('完成确认')
|
console.log('完成确认')
|
||||||
if (this.standId == '') {
|
if (this.standId == '') {
|
||||||
ElMessage({
|
errorBox('站台号不可缺少')
|
||||||
message: '站台号不可缺少',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const confirmParams = {
|
const confirmParams = {
|
||||||
|
|
@ -228,17 +225,14 @@ export default {
|
||||||
confirmFinishedWork(confirmParams).then(res => {
|
confirmFinishedWork(confirmParams).then(res => {
|
||||||
const response = res.data
|
const response = res.data
|
||||||
if (response.code == 0) {
|
if (response.code == 0) {
|
||||||
ElMessage({
|
successBox('response.message')
|
||||||
message: response.message,
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('确认时发生异常')
|
errorBox('确认时发生异常')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
requestPrint() {
|
requestPrint() {
|
||||||
|
|
@ -251,11 +245,11 @@ export default {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.printTabs = res.data.returnData
|
this.printTabs = res.data.returnData
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('获取标签数据时异常')
|
errorBox('获取标签数据时异常')
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -53,7 +53,8 @@
|
||||||
layout="total, sizes, prev, pager, next, jumper" :total="total" @size-change="search"
|
layout="total, sizes, prev, pager, next, jumper" :total="total" @size-change="search"
|
||||||
@current-change="search" />
|
@current-change="search" />
|
||||||
<el-dialog v-model="dialogVisible" title="物料信息" width="40%" draggable :show-close="false">
|
<el-dialog v-model="dialogVisible" title="物料信息" width="40%" draggable :show-close="false">
|
||||||
<div style="max-width: 100%; max-height: 500px; overflow: auto; display: flex; justify-content: center;">
|
<div
|
||||||
|
style="max-width: 100%; max-height: 500px; overflow: auto; display: flex; justify-content: center;">
|
||||||
<el-form ref="goodsFormRef" :model="goodsFormEntity" :label-position="labelPosition"
|
<el-form ref="goodsFormRef" :model="goodsFormEntity" :label-position="labelPosition"
|
||||||
label-width="100px" style="width: 95%;" :rules="rules" status-icon>
|
label-width="100px" style="width: 95%;" :rules="rules" status-icon>
|
||||||
<el-row :gutter="16">
|
<el-row :gutter="16">
|
||||||
|
|
@ -89,8 +90,7 @@
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="重量" prop="weight">
|
<el-form-item label="重量" prop="weight">
|
||||||
<el-input-number v-model.number="goodsFormEntity.weight" controls-position="right"
|
<el-input-number v-model.number="goodsFormEntity.weight" controls-position="right"
|
||||||
:precision="3" :step="0.1"
|
:precision="3" :step="0.1" :min="0" clearable />
|
||||||
:min="0" clearable />
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
@ -102,8 +102,8 @@
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="每盒数量" prop="quantityPerBox">
|
<el-form-item label="每盒数量" prop="quantityPerBox">
|
||||||
<el-input-number v-model.number="goodsFormEntity.quantityPerBox" controls-position="right"
|
<el-input-number v-model.number="goodsFormEntity.quantityPerBox"
|
||||||
:min="0" clearable />
|
controls-position="right" :min="0" clearable />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
@ -139,8 +139,8 @@
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="补货点" prop="feedingValue">
|
<el-form-item label="补货点" prop="feedingValue">
|
||||||
<el-input-number v-model.number="goodsFormEntity.feedingValue" controls-position="right"
|
<el-input-number v-model.number="goodsFormEntity.feedingValue"
|
||||||
:min="0" clearable />
|
controls-position="right" :min="0" clearable />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
@ -176,11 +176,11 @@
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getGoodsInfoByPage } from '@/api/goods.js'
|
import { getGoodsInfoByPage } from '@/api/goods.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
import { ElMessageBox } from 'element-plus'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
|
import { errorBox, infoBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import UploadExcelGoods from '@/excel/UploadExcelGoods.vue'
|
import UploadExcelGoods from '@/excel/UploadExcelGoods.vue'
|
||||||
import UploadExcelStationConfig from '@/excel/UploadExcelStationConfig.vue'
|
|
||||||
import { downloadMaterialExcel } from '@/api/excel.js'
|
import { downloadMaterialExcel } from '@/api/excel.js'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
</script>
|
</script>
|
||||||
|
|
@ -223,10 +223,11 @@ export default {
|
||||||
this.goodsList = tableResponse.returnData.lists
|
this.goodsList = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('查询物料错误' + err.message)
|
console.log(err)
|
||||||
|
errorBox('查询物料错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -278,39 +279,30 @@ export default {
|
||||||
}
|
}
|
||||||
deleteAllKateTasks(params).then(res => {
|
deleteAllKateTasks(params).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
ElMessage({
|
successBox('删除物料信息成功')
|
||||||
message: '删除物料信息成功',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('删除物料信息失败')
|
errorBox('删除物料信息失败')
|
||||||
})
|
})
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
ElMessage({
|
infoBox('操作取消')
|
||||||
type: 'info',
|
|
||||||
message: '操作取消',
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
submitGoodsInfo(formData) {
|
submitGoodsInfo(formData) {
|
||||||
updatePartInfo(formData).then(res => {
|
updatePartInfo(formData).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('更新物料信息成功')
|
||||||
message: '更新零件信息成功',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('更新零件信息失败')
|
errorBox('更新物料信息失败')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCurrentRow(row) {
|
getCurrentRow(row) {
|
||||||
|
|
@ -335,18 +327,12 @@ export default {
|
||||||
document.body.removeChild(link)
|
document.body.removeChild(link)
|
||||||
url.revokeObjectURL(link.href)//移除url对象
|
url.revokeObjectURL(link.href)//移除url对象
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
ElMessage({
|
console.log(e)
|
||||||
message: '下载文件失败:: ' + e,
|
errorBox('下载文件失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage({
|
console.log(err)
|
||||||
message: '导出失败:: ' + err,
|
errorBox('导出失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -101,7 +101,7 @@ import store from '@/store'
|
||||||
import { sendGoodsInTask } from '@/api/task'
|
import { sendGoodsInTask } from '@/api/task'
|
||||||
import { replaceEnglishAndNumberIGAI } from '@/utils/formatter'
|
import { replaceEnglishAndNumberIGAI } from '@/utils/formatter'
|
||||||
import { reactive, ref } from 'vue'
|
import { reactive, ref } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
@ -148,10 +148,7 @@ export default {
|
||||||
this.workFormEntity.vehicleId = replaceEnglishAndNumberIGAI(this.workFormEntity.vehicleId)
|
this.workFormEntity.vehicleId = replaceEnglishAndNumberIGAI(this.workFormEntity.vehicleId)
|
||||||
if (this.workFormEntity.vehicleId != '' && this.workFormEntity.goodsId != '' && this.workFormEntity.goodsNum != null && this.workFormEntity.goodsNum > 0) {
|
if (this.workFormEntity.vehicleId != '' && this.workFormEntity.goodsId != '' && this.workFormEntity.goodsNum != null && this.workFormEntity.goodsNum > 0) {
|
||||||
if (this.currentVehicleId != '' && this.currentVehicleId != this.workFormEntity.vehicleId) {
|
if (this.currentVehicleId != '' && this.currentVehicleId != this.workFormEntity.vehicleId) {
|
||||||
ElMessage({
|
errorBox('请下发之前料箱的任务后再继续绑定新的料箱')
|
||||||
message: '请下发之前料箱的任务后再继续绑定新的料箱',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const sameIndex = this.tempTasks.findIndex(task => task.goodsId == this.workFormEntity.goodsId)
|
const sameIndex = this.tempTasks.findIndex(task => task.goodsId == this.workFormEntity.goodsId)
|
||||||
|
|
@ -192,10 +189,7 @@ export default {
|
||||||
},
|
},
|
||||||
confirmTask() {
|
confirmTask() {
|
||||||
if (this.currentVehicleId == '') {
|
if (this.currentVehicleId == '') {
|
||||||
ElMessage({
|
errorBox('必须输入料箱号')
|
||||||
message: '必须输入料箱号',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const request = {
|
const request = {
|
||||||
|
|
@ -206,20 +200,17 @@ export default {
|
||||||
sendGoodsInTask(request).then(res => {
|
sendGoodsInTask(request).then(res => {
|
||||||
const response = res.data
|
const response = res.data
|
||||||
if (response.code == 0) {
|
if (response.code == 0) {
|
||||||
ElMessage({
|
successBox('入库确认成功。')
|
||||||
message: '入库确认成功。',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
this.currentVehicleId = ''
|
this.currentVehicleId = ''
|
||||||
this.tempTasks = []
|
this.tempTasks = []
|
||||||
this.$refs.vehicleId.focus()
|
this.$refs.vehicleId.focus()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('入库处理异常')
|
errorBox('入库处理异常')
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -126,6 +126,7 @@ import { sendGoodsInTask, callEmptyVehicle } from '@/api/task'
|
||||||
import { queryPartInfoByPartNo } from '@/api/goods'
|
import { queryPartInfoByPartNo } from '@/api/goods'
|
||||||
import { reactive, ref } from 'vue'
|
import { reactive, ref } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import UploadExcelPart from '@/excel/UploadExcelPart.vue'
|
import UploadExcelPart from '@/excel/UploadExcelPart.vue'
|
||||||
const taskInRequestRef = ref()
|
const taskInRequestRef = ref()
|
||||||
|
|
|
||||||
|
|
@ -135,6 +135,7 @@ import { sendGoodsOutTask, getTasksByPage, getTasks, finishPickingAndBack } from
|
||||||
import { taskStatusFormatter, dueFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { taskStatusFormatter, dueFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import { reactive, ref } from 'vue'
|
import { reactive, ref } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
const taskOutRequestRef = ref()
|
const taskOutRequestRef = ref()
|
||||||
const pickConfirmRef = ref()
|
const pickConfirmRef = ref()
|
||||||
|
|
|
||||||
|
|
@ -88,6 +88,7 @@ import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,3 @@
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div style="margin-bottom: 15px">
|
<div style="margin-bottom: 15px">
|
||||||
<el-config-provider :locale="zhCn">
|
<el-config-provider :locale="zhCn">
|
||||||
|
|
@ -13,7 +12,8 @@
|
||||||
<el-table :data="tasks" stripe border v-loading="loading" style="width: 100%" max-height="684px"
|
<el-table :data="tasks" stripe border v-loading="loading" style="width: 100%" max-height="684px"
|
||||||
class="table-class" :header-cell-style="{ 'text-align': 'center' }"
|
class="table-class" :header-cell-style="{ 'text-align': 'center' }"
|
||||||
:cell-style="{ 'text-align': 'center' }">
|
:cell-style="{ 'text-align': 'center' }">
|
||||||
<el-table-column prop="taskType" label="任务类型" fixed="left" :formatter="taskTypeFormat" min-width="120px" />
|
<el-table-column prop="taskType" label="任务类型" fixed="left" :formatter="taskTypeFormat"
|
||||||
|
min-width="120px" />
|
||||||
<el-table-column prop="goodsType" label="型号" min-width="120px" />
|
<el-table-column prop="goodsType" label="型号" min-width="120px" />
|
||||||
<el-table-column prop="specification" label="规格" min-width="120px" />
|
<el-table-column prop="specification" label="规格" min-width="120px" />
|
||||||
<el-table-column prop="batchNo" label="批次号" min-width="120px" />
|
<el-table-column prop="batchNo" label="批次号" min-width="120px" />
|
||||||
|
|
@ -44,7 +44,7 @@ import { getTaskRecords } from '@/api/record.js'
|
||||||
import { dateFormatter, taskStatusFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, taskStatusFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import { downloadInRecordExcel } from '@/api/excel.js'
|
import { downloadInRecordExcel } from '@/api/excel.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
</script>
|
</script>
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
|
|
@ -97,11 +97,11 @@ export default {
|
||||||
this.tasks = tableResponse.returnData.lists
|
this.tasks = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('查询任务记录错误')
|
errorBox('查询任务记录错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -133,18 +133,12 @@ export default {
|
||||||
document.body.removeChild(link)
|
document.body.removeChild(link)
|
||||||
url.revokeObjectURL(link.href)//移除url对象
|
url.revokeObjectURL(link.href)//移除url对象
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
ElMessage({
|
console.log(e)
|
||||||
message: '下载文件失败:: ' + e,
|
errorBox('下载文件失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage({
|
console.log(e)
|
||||||
message: '导出失败:: ' + err,
|
errorBox('导出失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -88,7 +88,7 @@
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getWorkByStandAndGoods, confirmFinishWork, queryFinishByStandAndGoods } from '@/api/task'
|
import { getWorkByStandAndGoods, confirmFinishWork, queryFinishByStandAndGoods } from '@/api/task'
|
||||||
import { reactive, ref } from 'vue'
|
import { reactive, ref } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import UploadExcelInventoryList from '@/excel/UploadExcelInventoryList.vue'
|
import UploadExcelInventoryList from '@/excel/UploadExcelInventoryList.vue'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
</script>
|
</script>
|
||||||
|
|
@ -152,12 +152,12 @@ export default {
|
||||||
this.workFormEntity.tip = response.returnData.tip
|
this.workFormEntity.tip = response.returnData.tip
|
||||||
} else {
|
} else {
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
ElMessage.error('查询工作信息错误')
|
errorBox('查询工作信息错误')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 查询是否完成
|
// 查询是否完成
|
||||||
|
|
@ -176,7 +176,7 @@ export default {
|
||||||
this.workFormEntity.tip = response.returnData.tip
|
this.workFormEntity.tip = response.returnData.tip
|
||||||
}
|
}
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
ElMessage.success(response.message)
|
successBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
|
|
@ -201,10 +201,7 @@ export default {
|
||||||
// 确认完成工作
|
// 确认完成工作
|
||||||
confirmTask() {
|
confirmTask() {
|
||||||
if (this.standId == '' || this.workFormEntity.goodsId == '') {
|
if (this.standId == '' || this.workFormEntity.goodsId == '') {
|
||||||
ElMessage({
|
errorBox('站台号和料号不可缺少')
|
||||||
message: '站台号和料号不可缺少',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const confirmParams = {
|
const confirmParams = {
|
||||||
|
|
@ -220,13 +217,13 @@ export default {
|
||||||
this.workFormEntity.tip = response.returnData.tip
|
this.workFormEntity.tip = response.returnData.tip
|
||||||
}
|
}
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
ElMessage.success(response.message)
|
successBox(response.message)
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('确认时发生异常')
|
errorBox('确认时发生异常')
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -59,7 +59,7 @@
|
||||||
import { getTaskRecords } from '@/api/record.js'
|
import { getTaskRecords } from '@/api/record.js'
|
||||||
import { dateFormatter, taskStatusFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, taskStatusFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox } from '@/utils/myMessageBox.js'
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
</script>
|
</script>
|
||||||
<script>
|
<script>
|
||||||
|
|
@ -117,12 +117,12 @@ export default {
|
||||||
this.tasks = tableResponse.rows
|
this.tasks = tableResponse.rows
|
||||||
this.total = tableResponse.total
|
this.total = tableResponse.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
|
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('查询盘点记录错误')
|
errorBox('查询盘点记录错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -27,11 +27,11 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="orderId" label="id" fixed="left" min-width="120px" show-overflow-tooltip />
|
<el-table-column prop="orderId" label="id" fixed="left" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="workOrder" label="工单" fixed="left" min-width="120px" />
|
<el-table-column prop="workOrder" label="工单" fixed="left" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="goodsId" label="料号" min-width="120px" />
|
<el-table-column prop="goodsId" label="料号" min-width="120px" />
|
||||||
<el-table-column prop="supplyArea" label="小工位" fixed="left" min-width="120px" />
|
<el-table-column prop="supplyArea" label="小工位" fixed="left" min-width="120px" />
|
||||||
<el-table-column prop="item" label="Item" min-width="120px" />
|
<el-table-column prop="item" label="Item" min-width="120px" />
|
||||||
<el-table-column prop="description" label="描述" min-width="120px" />
|
<el-table-column prop="description" label="描述" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="sLoc" label="SLoc" min-width="120px" />
|
<el-table-column prop="sLoc" label="SLoc" min-width="120px" />
|
||||||
<el-table-column prop="type" label="Type" min-width="120px" />
|
<el-table-column prop="type" label="Type" min-width="120px" />
|
||||||
<el-table-column prop="originStatus" label="Status" min-width="120px" />
|
<el-table-column prop="originStatus" label="Status" min-width="120px" />
|
||||||
|
|
@ -158,7 +158,8 @@
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getOrders, deleteOrders, updateOrders } from '@/api/kateWork.js'
|
import { getOrders, deleteOrders, updateOrders } from '@/api/kateWork.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
import { ElMessageBox } from 'element-plus'
|
||||||
|
import { errorBox, infoBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import UploadExcelOrders from '@/excel/UploadExcelOrders.vue'
|
import UploadExcelOrders from '@/excel/UploadExcelOrders.vue'
|
||||||
|
|
@ -212,10 +213,11 @@ export default {
|
||||||
this.ordersList = tableResponse.returnData.lists
|
this.ordersList = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('查询工单错误' + err.message)
|
console.log(err)
|
||||||
|
errorBox('查询工单错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -262,23 +264,17 @@ export default {
|
||||||
}
|
}
|
||||||
deleteOrders(params).then(res => {
|
deleteOrders(params).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
ElMessage({
|
successBox('删除工单信息成功。')
|
||||||
message: '删除工单信息成功',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('删除工单信息成功')
|
errorBox('删除工单信息成功')
|
||||||
})
|
})
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
ElMessage({
|
infoBox('操作取消')
|
||||||
type: 'info',
|
|
||||||
message: '操作取消',
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
submitOrdersInfo(formData) {
|
submitOrdersInfo(formData) {
|
||||||
|
|
@ -296,16 +292,14 @@ export default {
|
||||||
updateOrders(params).then(res => {
|
updateOrders(params).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('更新工单成功。')
|
||||||
message: '更新工单成功。',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('更新工单失败。')
|
console.log(err)
|
||||||
|
errorBox('更新工单失败。')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCurrentRow(row) {
|
getCurrentRow(row) {
|
||||||
|
|
@ -339,7 +333,7 @@ export default {
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('发生异常')
|
errorBox('发生异常')
|
||||||
})
|
})
|
||||||
this.uploadDialogVisible = true
|
this.uploadDialogVisible = true
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -66,6 +66,7 @@ import store from '@/store'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { getLocations, updateLocation } from '@/api/location.js'
|
import { getLocations, updateLocation } from '@/api/location.js'
|
||||||
import { ElMessage, ElLoading } from 'element-plus'
|
import { ElMessage, ElLoading } from 'element-plus'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { reactive } from 'vue'
|
import { reactive } from 'vue'
|
||||||
</script>
|
</script>
|
||||||
<script>
|
<script>
|
||||||
|
|
|
||||||
|
|
@ -132,7 +132,7 @@ import store from '@/store'
|
||||||
import { getLocations, updateLocation } from '@/api/location.js'
|
import { getLocations, updateLocation } from '@/api/location.js'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { locationStatusFormatter, locationFormatter } from '@/utils/formatter.js'
|
import { locationStatusFormatter, locationFormatter } from '@/utils/formatter.js'
|
||||||
</script>
|
</script>
|
||||||
|
|
@ -200,10 +200,11 @@ export default {
|
||||||
this.locations = tableResponse.returnData.lists
|
this.locations = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('查询库位信息错误' + err.message)
|
console.log(err)
|
||||||
|
errorBox('查询库位信息错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -258,16 +259,14 @@ export default {
|
||||||
updateLocation(request).then(res => {
|
updateLocation(request).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('更新库位信息成功')
|
||||||
message: '更新库位信息成功',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('更新库位信息失败:' + err)
|
console.log(err)
|
||||||
|
errorBox('更新库位信息失败')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCurrentRow(row) {
|
getCurrentRow(row) {
|
||||||
|
|
|
||||||
|
|
@ -41,6 +41,7 @@
|
||||||
import { getTaskRecords } from '@/api/record.js'
|
import { getTaskRecords } from '@/api/record.js'
|
||||||
import { dateFormatter, taskStatusFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, taskStatusFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import { downloadOutRecordExcel } from '@/api/excel.js'
|
import { downloadOutRecordExcel } from '@/api/excel.js'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
|
|
|
||||||
|
|
@ -86,6 +86,7 @@
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
|
|
|
||||||
|
|
@ -85,7 +85,7 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
|
|
@ -148,10 +148,11 @@ export default {
|
||||||
this.pickTaskList = tableResponse.returnData.lists
|
this.pickTaskList = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('查询拣选任务错误' + err.message)
|
console.log(err)
|
||||||
|
errorBox('查询拣选任务错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -200,16 +201,14 @@ export default {
|
||||||
updatePickTaskInfo(params).then(res => {
|
updatePickTaskInfo(params).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('更新拣选任务成功。')
|
||||||
message: '更新拣选任务成功。',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('更新拣选任务失败。')
|
console.log(err)
|
||||||
|
errorBox('更新拣选任务失败。')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCurrentRow(row) {
|
getCurrentRow(row) {
|
||||||
|
|
|
||||||
|
|
@ -66,7 +66,7 @@
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { requestSortBox } from '@/api/task'
|
import { requestSortBox } from '@/api/task'
|
||||||
import { reactive, ref } from 'vue'
|
import { reactive, ref } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
@ -104,17 +104,11 @@ export default {
|
||||||
},
|
},
|
||||||
confirmTask() {
|
confirmTask() {
|
||||||
if (this.workFormEntity.bigBoxNo == '') {
|
if (this.workFormEntity.bigBoxNo == '') {
|
||||||
ElMessage({
|
errorBox('请输入大盒子号')
|
||||||
message: '请输入大盒子号',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (this.workFormEntity.orderOfOrders == null) {
|
if (this.workFormEntity.orderOfOrders == null) {
|
||||||
ElMessage({
|
errorBox('请输入工单顺序')
|
||||||
message: '请输入工单顺序',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const request = {
|
const request = {
|
||||||
|
|
@ -126,17 +120,14 @@ export default {
|
||||||
requestSortBox(request).then(res => {
|
requestSortBox(request).then(res => {
|
||||||
const response = res.data
|
const response = res.data
|
||||||
if (response.code == 0) {
|
if (response.code == 0) {
|
||||||
ElMessage({
|
successBox('请根据灯光拣选盒子。')
|
||||||
message: '请根据灯光拣选盒子。',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.resetForms()
|
this.resetForms()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(response.message)
|
errorBox(response.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('请求发生异常。')
|
errorBox('请求发生异常。')
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -86,6 +86,7 @@
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
|
|
|
||||||
|
|
@ -153,7 +153,8 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getStationConfigs, deleteStationConfigs, updateStationConfigs } from '@/api/kateWork.js'
|
import { getStationConfigs, deleteStationConfigs, updateStationConfigs } from '@/api/kateWork.js'
|
||||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
import { ElMessageBox } from 'element-plus'
|
||||||
|
import { errorBox, successBox, infoBox } from '@/utils/myMessageBox.js'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import UploadExcelStationConfig from '@/excel/UploadExcelStationConfig.vue'
|
import UploadExcelStationConfig from '@/excel/UploadExcelStationConfig.vue'
|
||||||
|
|
@ -206,10 +207,11 @@ export default {
|
||||||
this.stationConfigList = tableResponse.returnData.lists
|
this.stationConfigList = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('查询工站配置错误' + err.message)
|
console.log(err)
|
||||||
|
errorBox('查询工站配置错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -258,23 +260,17 @@ export default {
|
||||||
}
|
}
|
||||||
deleteStationConfigs(params).then(res => {
|
deleteStationConfigs(params).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
ElMessage({
|
successBox('工站配置信息删除成功')
|
||||||
message: '删除工站配置信息成功',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('删除工站配置信息成功')
|
errorBox('删除工站配置信息失败')
|
||||||
})
|
})
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
ElMessage({
|
infoBox('操作取消')
|
||||||
type: 'info',
|
|
||||||
message: '操作取消',
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
submitConfigInfo(formData) {
|
submitConfigInfo(formData) {
|
||||||
|
|
@ -295,16 +291,14 @@ export default {
|
||||||
updateStationConfigs(params).then(res => {
|
updateStationConfigs(params).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('工站配置信息更新成功')
|
||||||
message: '更新工站配置成功。',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('更新工站配置失败。')
|
console.log(err)
|
||||||
|
errorBox('更新工站配置失败。')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCurrentRow(row) {
|
getCurrentRow(row) {
|
||||||
|
|
@ -338,7 +332,7 @@ export default {
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('发生异常')
|
errorBox('发生异常')
|
||||||
})
|
})
|
||||||
this.uploadDialogVisible = true
|
this.uploadDialogVisible = true
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -25,24 +25,30 @@
|
||||||
<el-radio :label="scope.row.stockId" v-model="stockId"> </el-radio>
|
<el-radio :label="scope.row.stockId" v-model="stockId"> </el-radio>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<el-table-column prop="stockId" label="库存编号" fixed="left" min-width="120px" show-overflow-tooltip />
|
||||||
|
<el-table-column prop="vehicleId" label="箱号" fixed="left" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="goodsId" label="物料号" fixed="left" min-width="120px" show-overflow-tooltip />
|
<el-table-column prop="goodsId" label="物料号" fixed="left" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="goodsName" label="物料名称" fixed="left" min-width="120px" show-overflow-tooltip />
|
<el-table-column prop="goodsName" label="物料名称" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="remainNum" label="剩余数量" min-width="120px" />
|
|
||||||
<el-table-column prop="totalNum" label="入库数量" min-width="120px" />
|
|
||||||
<el-table-column prop="vehicleId" label="载具号" min-width="120px" show-overflow-tooltip />
|
|
||||||
<el-table-column prop="locationId" label="库位" :formatter="locationFormat" min-width="120px"
|
<el-table-column prop="locationId" label="库位" :formatter="locationFormat" min-width="120px"
|
||||||
show-overflow-tooltip />
|
show-overflow-tooltip />
|
||||||
<el-table-column prop="isInventory" label="是否盘点" min-width="120px" />
|
<el-table-column prop="totalNum" label="入库数量" min-width="120px" />
|
||||||
<el-table-column prop="createTime" label="上架时间" :formatter="timeFormat" min-width="120px"
|
<el-table-column prop="remainNum" label="剩余数量" min-width="120px" />
|
||||||
show-overflow-tooltip />
|
|
||||||
<el-table-column prop="goodsStatus" label="物料状态" :formatter="goodsStatusFormat" min-width="120px" />
|
<el-table-column prop="goodsStatus" label="物料状态" :formatter="goodsStatusFormat" min-width="120px" />
|
||||||
<el-table-column prop="stockStatus" label="库存状态" :formatter="stockStatusFormat" fixed="right"
|
<el-table-column prop="stockStatus" label="库存状态" :formatter="stockStatusFormat" fixed="right"
|
||||||
min-width="120px" />
|
min-width="120px" />
|
||||||
<!-- <el-table-column fixed="right" label="操作" width="120px" v-if="selStock == null">
|
<el-table-column prop="isInventory" label="是否盘点" :formatter="yesOrNoFormat" min-width="120px" />
|
||||||
|
<el-table-column prop="inventoryTaskId" label="盘点任务号" min-width="120px" />
|
||||||
|
<el-table-column prop="noUseDays" label="未使用天数" min-width="120px" />
|
||||||
|
<el-table-column prop="createTime" label="上架时间" :formatter="timeFormat" min-width="120px"
|
||||||
|
show-overflow-tooltip />
|
||||||
|
<el-table-column prop="lastUpdateTime" label="最近更新时间" :formatter="timeFormat" min-width="120px"
|
||||||
|
show-overflow-tooltip />
|
||||||
|
<el-table-column prop="lastUpdateUser" label="最近更新用户" min-width="120px" />
|
||||||
|
<el-table-column fixed="right" label="操作" width="120px" v-if="selStock == null">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<el-button plain type="primary" @click="editCurrentRowStock(scope.row)">编辑</el-button>
|
<el-button plain type="primary" @click="editCurrentRowStock(scope.row)">编辑</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column> -->
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<br />
|
<br />
|
||||||
<el-pagination v-model:current-page="currentPage" v-model:page-size="pageSize" :page-sizes="[10, 25, 50]"
|
<el-pagination v-model:current-page="currentPage" v-model:page-size="pageSize" :page-sizes="[10, 25, 50]"
|
||||||
|
|
@ -53,39 +59,39 @@
|
||||||
style="max-width: 100%" :rules="rules" status-icon>
|
style="max-width: 100%" :rules="rules" status-icon>
|
||||||
<el-row :gutter="16">
|
<el-row :gutter="16">
|
||||||
<el-col :span="12" :offset="0">
|
<el-col :span="12" :offset="0">
|
||||||
<el-form-item label="型号" prop="goodsType">
|
<el-form-item label="库存编号" prop="stockId">
|
||||||
<el-input v-model="stockFormEntity.goodsType" clearable />
|
<el-input v-model="stockFormEntity.stockId" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="规格" prop="specification">
|
<el-form-item label="箱号" prop="vehicleId">
|
||||||
<el-input v-model="stockFormEntity.specification" clearable />
|
<el-input v-model="stockFormEntity.vehicleId" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row :gutter="16">
|
<el-row :gutter="16">
|
||||||
<el-col :span="12" :offset="0">
|
<el-col :span="12" :offset="0">
|
||||||
<el-form-item label="条码号" prop="barcode">
|
<el-form-item label="料号" prop="goodsId">
|
||||||
<el-input v-model="stockFormEntity.barcode" clearable />
|
<el-input v-model="stockFormEntity.goodsId" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="批次号" prop="batchNo">
|
<el-form-item label="料名" prop="goodsName">
|
||||||
<el-input v-model="stockFormEntity.batchNo" clearable />
|
<el-input v-model="stockFormEntity.goodsName" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row :gutter="16">
|
<el-row :gutter="16">
|
||||||
<el-col :span="12" :offset="0">
|
<el-col :span="12" :offset="0">
|
||||||
<el-form-item label="入库数量" prop="originNum">
|
<el-form-item label="入库数量" prop="totalNum">
|
||||||
<el-input-number v-model.number="stockFormEntity.originNum" clearable
|
<el-input-number v-model.number="stockFormEntity.totalNum"
|
||||||
controls-position="right" :min="0" />
|
controls-position="right" :min="0" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="实际数量(为0时删除库存)" prop="realNum">
|
<el-form-item label="剩余数量(为0时删除库存)" prop="remainNum">
|
||||||
<el-input-number v-model.number="stockFormEntity.realNum" controls-position="right"
|
<el-input-number v-model.number="stockFormEntity.remainNum" controls-position="right"
|
||||||
:min="0" clearable />
|
:min="0" :max="stockFormEntity.totalNum" clearable />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
@ -96,8 +102,9 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="订单号" prop="orderId">
|
<el-form-item label="未使用天数" prop="noUseDays">
|
||||||
<el-input v-model="stockFormEntity.orderId" clearable />
|
<el-input-number v-model.number="stockFormEntity.noUseDays" controls-position="right"
|
||||||
|
:min="0" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
@ -115,6 +122,37 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
<el-row :gutter="16">
|
||||||
|
<el-col :span="12" :offset="0">
|
||||||
|
<el-form-item label="盘点任务号" prop="inventoryTaskId">
|
||||||
|
<el-input v-model="stockFormEntity.inventoryTaskId" disabled />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="是否盘点" prop="isInventory">
|
||||||
|
<el-input v-model="stockFormEntity.isInventory" disabled />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="16">
|
||||||
|
<el-col :span="12" :offset="0">
|
||||||
|
<el-form-item label="创建时间" prop="createTime">
|
||||||
|
<el-input v-model="stockFormEntity.createTime" disabled />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="最近更新时间" prop="lastUpdateTime">
|
||||||
|
<el-input v-model="stockFormEntity.lastUpdateTime" disabled />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="16">
|
||||||
|
<el-col :span="12" :offset="0">
|
||||||
|
<el-form-item label="最近更新用户" prop="lastUpdateUser">
|
||||||
|
<el-input v-model="stockFormEntity.lastUpdateUser" disabled />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
</el-form>
|
</el-form>
|
||||||
<template #footer>
|
<template #footer>
|
||||||
<span class="dialog-footer">
|
<span class="dialog-footer">
|
||||||
|
|
@ -133,11 +171,11 @@
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getAllStocks, updateStockInfo } from '@/api/stock.js'
|
import { getAllStocks, updateStockInfo } from '@/api/stock.js'
|
||||||
import { downloadStockExcel } from '@/api/excel.js'
|
import { downloadStockExcel } from '@/api/excel.js'
|
||||||
import { dateFormatter, locationFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, locationFormatter, timeFormatter, yesOrNoFormatter } from '@/utils/formatter.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
// import FileSaver from 'file-saver';
|
// import FileSaver from 'file-saver';
|
||||||
// import * as XLSX from 'xlsx';
|
// import * as XLSX from 'xlsx';
|
||||||
</script>
|
</script>
|
||||||
|
|
@ -262,6 +300,9 @@ export default {
|
||||||
return '异常'
|
return '异常'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
yesOrNoFormat: (row, column, cellValue, index) => {
|
||||||
|
return yesOrNoFormatter(cellValue)
|
||||||
|
},
|
||||||
rowStyle: ({ row, rowIndex }) => {
|
rowStyle: ({ row, rowIndex }) => {
|
||||||
if (row.goodsStatus == 3) {
|
if (row.goodsStatus == 3) {
|
||||||
return { "color": "red" }
|
return { "color": "red" }
|
||||||
|
|
@ -286,11 +327,11 @@ export default {
|
||||||
this.displayStocks = tableResponse.returnData.lists
|
this.displayStocks = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('查询库存错误')
|
errorBox('查询库存错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -328,18 +369,12 @@ export default {
|
||||||
document.body.removeChild(link)
|
document.body.removeChild(link)
|
||||||
url.revokeObjectURL(link.href)//移除url对象
|
url.revokeObjectURL(link.href)//移除url对象
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
ElMessage({
|
console.log(e)
|
||||||
message: '下载文件失败:: ' + e,
|
errorBox('下载文件失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage({
|
console.log(err)
|
||||||
message: '导出失败:: ' + err,
|
errorBox('导出失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
editCurrentRowStock(row) {
|
editCurrentRowStock(row) {
|
||||||
|
|
@ -354,35 +389,36 @@ export default {
|
||||||
isInventory: row.isInventory,
|
isInventory: row.isInventory,
|
||||||
inventoryTaskId: row.inventoryTaskId,
|
inventoryTaskId: row.inventoryTaskId,
|
||||||
noUseDays: row.noUseDays,
|
noUseDays: row.noUseDays,
|
||||||
goodsRelated: {
|
|
||||||
goodsId: row.goodsId,
|
goodsId: row.goodsId,
|
||||||
goodsName: row.goodsName,
|
goodsName: row.goodsName,
|
||||||
goodsStatus: row.goodsStatus,
|
goodsStatus: row.goodsStatus,
|
||||||
remainNum: row.remainNum,
|
remainNum: row.remainNum,
|
||||||
totalNum: row.totalNum
|
totalNum: row.totalNum
|
||||||
}
|
}
|
||||||
}
|
|
||||||
this.stockFormEntity = row
|
|
||||||
this.dialogVisible = true
|
this.dialogVisible = true
|
||||||
},
|
},
|
||||||
submitStockInfo(stockFormEntity) {
|
submitStockInfo() {
|
||||||
updateStockInfo(stockFormEntity).then(res => {
|
const request = {
|
||||||
|
stockId: this.stockFormEntity.stockId,
|
||||||
|
locationId: this.stockFormEntity.locationId,
|
||||||
|
vehicleId: this.stockFormEntity.vehicleId,
|
||||||
|
stockStatus: this.stockFormEntity.stockStatus,
|
||||||
|
goodsId: this.stockFormEntity.goodsId,
|
||||||
|
goodsStatus: this.stockFormEntity.goodsStatus,
|
||||||
|
remainNum: this.stockFormEntity.remainNum,
|
||||||
|
userName: store.getters.getUserName
|
||||||
|
}
|
||||||
|
updateStockInfo(request).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('更新库存成功')
|
||||||
message: '更新库存成功',
|
|
||||||
type: 'success'
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage({
|
console.log(err)
|
||||||
message: '更新库存失败: ' + err,
|
errorBox('更新库存失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -2,8 +2,12 @@
|
||||||
<div style="margin-bottom: 10px">
|
<div style="margin-bottom: 10px">
|
||||||
<el-config-provider :locale="zhCn">
|
<el-config-provider :locale="zhCn">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-input v-model="goodsIdQuery" style="width: 256px; margin-right: 10px;" placeholder="料号" />
|
<el-input v-model="goodsIdQuery" style="width: 196px; margin-right: 10px;" placeholder="料号" />
|
||||||
<el-input v-model="vehicleIdQuery" style="width: 256px; margin-right: 10px;" placeholder="箱号" />
|
<el-input v-model="vehicleIdQuery" style="width: 196px; margin-right: 10px;" placeholder="箱号" />
|
||||||
|
<el-select-v2 v-model="taskTypeQuery" style="width: 196px; margin-right: 10px;" placeholder="请选择任务类型"
|
||||||
|
:options="taskTypeOptions" @change="search()"></el-select-v2>
|
||||||
|
<el-select-v2 v-model="taskStatusQuery" style="width: 196px; margin-right: 10px;" placeholder="请选择任务状态"
|
||||||
|
:options="taskStatusOptions" @change="search()"></el-select-v2>
|
||||||
<el-button type="primary" @click="search()">搜索</el-button>
|
<el-button type="primary" @click="search()">搜索</el-button>
|
||||||
<el-button type="warning" @click="reset()">重置</el-button>
|
<el-button type="warning" @click="reset()">重置</el-button>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
@ -16,10 +20,11 @@
|
||||||
<el-radio :label="scope.row.taskId" v-model="taskId"> </el-radio>
|
<el-radio :label="scope.row.taskId" v-model="taskId"> </el-radio>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<el-table-column prop="taskId" label="任务号" fixed="left" show-overflow-tooltip min-width="120px" />
|
||||||
<el-table-column prop="taskType" label="任务类型" fixed="left" :formatter="taskTypeFormat" min-width="120px" />
|
<el-table-column prop="taskType" label="任务类型" fixed="left" :formatter="taskTypeFormat" min-width="120px" />
|
||||||
<el-table-column prop="vehicleId" label="载具号" min-width="120px" />
|
<el-table-column prop="vehicleId" label="箱号" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="goodsRelated.goodsId" label="物料编号" min-width="120px" show-overflow-tooltip />
|
<el-table-column prop="goodsRelated.goodsId" label="料号" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="goodsRelated.goodsName" label="物料名称" min-width="120px" show-overflow-tooltip />
|
<el-table-column prop="goodsRelated.goodsName" label="料名" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="taskGroup" label="任务组" min-width="120px" show-overflow-tooltip />
|
<el-table-column prop="taskGroup" label="任务组" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="origin" label="起点" min-width="120px" />
|
<el-table-column prop="origin" label="起点" min-width="120px" />
|
||||||
<el-table-column prop="destination" label="终点" min-width="120px" />
|
<el-table-column prop="destination" label="终点" min-width="120px" />
|
||||||
|
|
@ -27,16 +32,16 @@
|
||||||
<el-table-column prop="originNum" label="库存数量" min-width="120px" />
|
<el-table-column prop="originNum" label="库存数量" min-width="120px" />
|
||||||
<el-table-column prop="taskPriority" label="任务优先级" min-width="120px" />
|
<el-table-column prop="taskPriority" label="任务优先级" min-width="120px" />
|
||||||
<el-table-column prop="preTask" label="前置任务" min-width="120px" show-overflow-tooltip />
|
<el-table-column prop="preTask" label="前置任务" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="createTime" label="创建时间" :formatter="timeFormat" min-width="120px" />
|
<el-table-column prop="createTime" label="创建时间" :formatter="timeFormat" min-width="120px" show-overflow-tooltip />
|
||||||
<el-table-column prop="createTime" label="运行时长" :formatter="dueFormat" min-width="120px" />
|
<el-table-column prop="createTime" label="运行时长" :formatter="dueFormat" min-width="120px" show-overflow-tooltip />
|
||||||
<!-- <el-table-column prop="userName" label="操作人员姓名" min-width="120px" /> -->
|
<el-table-column prop="userName" label="操作人员姓名" min-width="120px" />
|
||||||
<el-table-column prop="taskStatus" label="任务状态" fixed="right" :formatter="taskStatusFormat"
|
<el-table-column prop="taskStatus" label="任务状态" fixed="right" :formatter="taskStatusFormat"
|
||||||
min-width="120px" />
|
min-width="120px" />
|
||||||
<!-- <el-table-column fixed="right" label="操作" width="120px">
|
<el-table-column fixed="right" label="操作" width="120px">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<el-button plain type="primary" @click="editCurrentRowTask(scope.row)">编辑</el-button>
|
<el-button plain type="primary" @click="editCurrentRowTask(scope.row)">编辑</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column> -->
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<br />
|
<br />
|
||||||
<el-pagination v-model:current-page="currentPage" v-model:page-size="pageSize" :page-sizes="[10, 25, 50]"
|
<el-pagination v-model:current-page="currentPage" v-model:page-size="pageSize" :page-sizes="[10, 25, 50]"
|
||||||
|
|
@ -48,12 +53,25 @@
|
||||||
style="max-width: 100%" :rules="rules" status-icon>
|
style="max-width: 100%" :rules="rules" status-icon>
|
||||||
<el-row :gutter="16">
|
<el-row :gutter="16">
|
||||||
<el-col :span="12" :offset="0">
|
<el-col :span="12" :offset="0">
|
||||||
<el-form-item label="料箱号" prop="vehicleNo">
|
<el-form-item label="任务号" prop="taskId">
|
||||||
<el-input v-model="taskFormEntity.vehicleNo" disabled />
|
<el-input v-model="taskFormEntity.taskId" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="零件号" prop="goodsId">
|
<el-form-item label="任务优先级" prop="taskPriority">
|
||||||
|
<el-input-number v-model.number="taskFormEntity.taskPriority" controls-position="right"
|
||||||
|
:min="1" :max="9" disabled />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row :gutter="16">
|
||||||
|
<el-col :span="12" :offset="0">
|
||||||
|
<el-form-item label="料箱号" prop="vehicleId">
|
||||||
|
<el-input v-model="taskFormEntity.vehicleId" disabled />
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="料号" prop="goodsId">
|
||||||
<el-input v-model="taskFormEntity.goodsId" disabled />
|
<el-input v-model="taskFormEntity.goodsId" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
@ -64,7 +82,7 @@
|
||||||
<el-input v-model="taskFormEntity.origin" disabled />
|
<el-input v-model="taskFormEntity.origin" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12" v-if="taskFormEntity.taskType == 1">
|
<!-- <el-col :span="12" v-if="taskFormEntity.taskType == 1">
|
||||||
<el-form-item label="终点" prop="destination">
|
<el-form-item label="终点" prop="destination">
|
||||||
<el-select-v2 v-model="taskFormEntity.destination"
|
<el-select-v2 v-model="taskFormEntity.destination"
|
||||||
:options="availableLocationOptions"></el-select-v2>
|
:options="availableLocationOptions"></el-select-v2>
|
||||||
|
|
@ -74,6 +92,11 @@
|
||||||
<el-form-item label="终点" prop="destination">
|
<el-form-item label="终点" prop="destination">
|
||||||
<el-input v-model="taskFormEntity.destination" disabled />
|
<el-input v-model="taskFormEntity.destination" disabled />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
</el-col> -->
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="终点" prop="destination">
|
||||||
|
<el-input v-model="taskFormEntity.destination" disabled />
|
||||||
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row :gutter="16">
|
<el-row :gutter="16">
|
||||||
|
|
@ -105,10 +128,10 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { getTasksByPage, changeTaskStatus } from '@/api/task.js'
|
import { getTasksByPage, updateTaskInfo } from '@/api/task.js'
|
||||||
import { dateFormatter, locationFormatter, taskStatusFormatter, timeFormatter, dueFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, taskStatusFormatter, timeFormatter, dueFormatter } from '@/utils/formatter.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
</script>
|
</script>
|
||||||
|
|
@ -123,6 +146,8 @@ export default {
|
||||||
total: 0,
|
total: 0,
|
||||||
goodsIdQuery: '',
|
goodsIdQuery: '',
|
||||||
vehicleIdQuery: '',
|
vehicleIdQuery: '',
|
||||||
|
taskTypeQuery: -99,
|
||||||
|
taskStatusQuery: -99,
|
||||||
loading: true,
|
loading: true,
|
||||||
dialogVisible: false,
|
dialogVisible: false,
|
||||||
taskFormEntity: reactive({}),
|
taskFormEntity: reactive({}),
|
||||||
|
|
@ -131,6 +156,10 @@ export default {
|
||||||
rules: reactive({}),
|
rules: reactive({}),
|
||||||
taskId: '',
|
taskId: '',
|
||||||
taskTypeOptions: [
|
taskTypeOptions: [
|
||||||
|
{
|
||||||
|
value: -99,
|
||||||
|
label: '所有类型'
|
||||||
|
},
|
||||||
{
|
{
|
||||||
value: 1,
|
value: 1,
|
||||||
label: '入库'
|
label: '入库'
|
||||||
|
|
@ -149,16 +178,48 @@ export default {
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
taskStatusOptions: [
|
taskStatusOptions: [
|
||||||
|
{
|
||||||
|
value: -99,
|
||||||
|
label: '所有状态'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: -2,
|
||||||
|
label: '重复入库'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: -1,
|
||||||
|
label: '暂存'
|
||||||
|
},
|
||||||
{
|
{
|
||||||
value: 0,
|
value: 0,
|
||||||
label: '任务重置'
|
label: '新建待下发'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
value: 1,
|
value: 1,
|
||||||
label: '任务取消'
|
label: '已下发'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
value: 2,
|
value: 2,
|
||||||
|
label: '开始执行'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: 8,
|
||||||
|
label: '拣选中'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: 9,
|
||||||
|
label: '盘点中'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: 100,
|
||||||
|
label: '任务完成'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: 998,
|
||||||
|
label: '任务取消'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: 999,
|
||||||
label: '任务完成'
|
label: '任务完成'
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|
@ -195,6 +256,8 @@ export default {
|
||||||
const tableRequest = {
|
const tableRequest = {
|
||||||
pageNo: this.currentPage,
|
pageNo: this.currentPage,
|
||||||
pageSize: this.pageSize,
|
pageSize: this.pageSize,
|
||||||
|
taskType: this.taskTypeQuery == -99 ? null : this.taskTypeQuery,
|
||||||
|
taskStatus: this.taskStatusQuery == -99 ? null : this.taskStatusQuery,
|
||||||
goodsId: this.goodsIdQuery.trim(),
|
goodsId: this.goodsIdQuery.trim(),
|
||||||
vehicleId: this.vehicleIdQuery.trim(),
|
vehicleId: this.vehicleIdQuery.trim(),
|
||||||
userName: store.getters.getUserName
|
userName: store.getters.getUserName
|
||||||
|
|
@ -204,12 +267,13 @@ export default {
|
||||||
if (tableResponse.code == 0) {
|
if (tableResponse.code == 0) {
|
||||||
this.tasks = tableResponse.returnData.lists
|
this.tasks = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
|
console.log(this.tasks)
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('查询任务错误')
|
errorBox('查询任务错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -218,6 +282,7 @@ export default {
|
||||||
this.vehicleIdQuery = ''
|
this.vehicleIdQuery = ''
|
||||||
},
|
},
|
||||||
editCurrentRowTask(row) {
|
editCurrentRowTask(row) {
|
||||||
|
console.log(row)
|
||||||
// if (row.taskType == 1) {
|
// if (row.taskType == 1) {
|
||||||
// this.availableLocationOptions = []
|
// this.availableLocationOptions = []
|
||||||
// var currentOption = {
|
// var currentOption = {
|
||||||
|
|
@ -239,44 +304,42 @@ export default {
|
||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
// }).catch(err => {
|
// }).catch(err => {
|
||||||
// ElMessage.error('查找可用库位失败:' + err)
|
// errorBox('查找可用库位失败:' + err)
|
||||||
// })
|
// })
|
||||||
// }
|
// }
|
||||||
this.taskFormEntity.taskId = row.taskId
|
this.taskFormEntity = {
|
||||||
this.taskFormEntity.vehicleNo = row.vehicleNo
|
taskId: row.taskId,
|
||||||
this.taskFormEntity.goodsId = row.goodsId
|
taskPriority: row.taskPriority,
|
||||||
this.taskFormEntity.origin = row.origin
|
vehicleId: row.vehicleId,
|
||||||
this.taskFormEntity.destination = row.destination
|
goodsId: row.goodsRelated == null ? '' : row.goodsRelated.goodsId,
|
||||||
this.taskFormEntity.taskType = row.taskType
|
origin: row.origin,
|
||||||
this.taskFormEntity.taskStatus = null
|
destination: row.destination,
|
||||||
|
taskType: row.taskType,
|
||||||
|
taskStatus: row.taskStatus,
|
||||||
|
}
|
||||||
this.dialogVisible = true
|
this.dialogVisible = true
|
||||||
},
|
},
|
||||||
submitTaskInfo(formData) {
|
submitTaskInfo() {
|
||||||
if (formData.taskStatus == null || formData.taskStatus == undefined) {
|
if (this.taskFormEntity.taskStatus == null || this.taskFormEntity.taskStatus == undefined) {
|
||||||
ElMessage.error('请选择任务状态')
|
errorBox('请选择任务状态')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
formData.userName = store.getters.getUserName
|
const request = {
|
||||||
changeTaskStatus(formData).then(res => {
|
taskId: this.taskFormEntity.taskId,
|
||||||
|
taskStatus: this.taskFormEntity.taskStatus,
|
||||||
|
userName: store.getters.getUserName
|
||||||
|
}
|
||||||
|
updateTaskInfo(request).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('修改任务成功')
|
||||||
message: '更新任务状态成功',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.taskFormEntity.taskId = ''
|
|
||||||
this.taskFormEntity.vehicleNo = ''
|
|
||||||
this.taskFormEntity.goodsId = ''
|
|
||||||
this.taskFormEntity.origin = ''
|
|
||||||
this.taskFormEntity.destination = ''
|
|
||||||
this.taskFormEntity.taskType = null
|
|
||||||
this.taskFormEntity.taskStatus = null
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('更新任务状态失败:' + err)
|
console.log(err)
|
||||||
|
errorBox('修改任务失败')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCurrentRow(row) {
|
getCurrentRow(row) {
|
||||||
|
|
|
||||||
|
|
@ -1,332 +0,0 @@
|
||||||
<template>
|
|
||||||
<el-config-provider :locale="zhCn">
|
|
||||||
<el-container class="content">
|
|
||||||
<div class="work-area">
|
|
||||||
<fieldset class="title-area">
|
|
||||||
<legend>
|
|
||||||
DBS
|
|
||||||
</legend>
|
|
||||||
<div class="title-div">
|
|
||||||
<span class="title-text">DBS日生产计划管理
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
</fieldset>
|
|
||||||
<fieldset class="main-area">
|
|
||||||
<legend>
|
|
||||||
上传
|
|
||||||
</legend>
|
|
||||||
<el-form ref="workFormRef" :model="workFormEntity" :label-position="labelPosition"
|
|
||||||
label-width="150px" style="max-width: 100%" :rules="rules" status-icon>
|
|
||||||
<div style="display: flex; justify-content: center;">
|
|
||||||
<div style="display: block; margin: 5px;">
|
|
||||||
<!-- <div
|
|
||||||
style="display: inline-flex; justify-content: center; height: 60px; width: 655px; margin: 5px; padding: 5px;">
|
|
||||||
<UploadExcelPart></UploadExcelPart>
|
|
||||||
</div> -->
|
|
||||||
<div style="height: 50px; margin-top: 20px; margin-bottom: 20px;"><UploadExcelDbs></UploadExcelDbs></div>
|
|
||||||
<div style="display: flex; margin-top: 15px">
|
|
||||||
<div
|
|
||||||
style="display: inline-flex; justify-content: center; width: 160px; margin: 5px; padding: 5px; background-color: #CCCCCC;">
|
|
||||||
<span style="align-self: center; font-weight: bold;font-size: 25px;">备注</span>
|
|
||||||
</div>
|
|
||||||
<div
|
|
||||||
style="display: inline-flex; justify-content: center; width: 700px; margin: 5px; padding: 5px; background-color: #00AAE8;">
|
|
||||||
<span style="align-self: center; font-weight: bold;font-size: 25px;">
|
|
||||||
{{ workFormEntity.remark }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</el-form>
|
|
||||||
</fieldset>
|
|
||||||
</div>
|
|
||||||
</el-container>
|
|
||||||
</el-config-provider>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup>
|
|
||||||
import store from '@/store'
|
|
||||||
import { getWorkByStandAndGoods, confirmFinishWork, queryFinishByStandAndGoods } from '@/api/task'
|
|
||||||
import { reactive, ref } from 'vue'
|
|
||||||
import { ElMessage } from 'element-plus'
|
|
||||||
import UploadExcelDbs from '@/excel/UploadExcelDbs.vue'
|
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
name: 'uploadDbs',
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
standId: store.getters.getStandId,
|
|
||||||
timer: '',
|
|
||||||
labelPosition: 'top',
|
|
||||||
workFormRef: ref(),
|
|
||||||
workFormEntity: reactive({
|
|
||||||
goodsId: '',
|
|
||||||
planPickNum: 0,
|
|
||||||
remainNumOrigin: null,
|
|
||||||
remainNumReal: null,
|
|
||||||
remark: '',
|
|
||||||
finishedRows: 0,
|
|
||||||
totalRows: 0,
|
|
||||||
finishedCounts: 0,
|
|
||||||
totalCounts: 0,
|
|
||||||
tip: ''
|
|
||||||
}),
|
|
||||||
rules: reactive({
|
|
||||||
goodsId: [
|
|
||||||
{ required: true, message: '请输入料号' }
|
|
||||||
]
|
|
||||||
}),
|
|
||||||
}
|
|
||||||
},
|
|
||||||
mounted() {
|
|
||||||
this.timer = setInterval(() => {
|
|
||||||
this.queryFinish()
|
|
||||||
}, 2000)
|
|
||||||
},
|
|
||||||
beforeUnmount() {
|
|
||||||
clearInterval(this.timer)
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
// 获取当前工作信息
|
|
||||||
getCurrentWorkInfo() {
|
|
||||||
const request = {
|
|
||||||
standId: this.standId,
|
|
||||||
goodsId: this.workFormEntity.goodsId
|
|
||||||
}
|
|
||||||
getWorkByStandAndGoods(request).then(res => {
|
|
||||||
const response = res.data
|
|
||||||
if (response.code == 0) {
|
|
||||||
this.workFormEntity.goodsId = response.returnData.goodsId
|
|
||||||
this.workFormEntity.planPickNum = response.returnData.planPickNum
|
|
||||||
this.workFormEntity.remainNumOrigin = response.returnData.remainNumOrigin
|
|
||||||
this.workFormEntity.remainNumReal = response.returnData.remainNumReal
|
|
||||||
this.workFormEntity.remark = response.returnData.remark
|
|
||||||
this.workFormEntity.finishedRows = response.returnData.finishedRows
|
|
||||||
this.workFormEntity.totalRows = response.returnData.totalRows
|
|
||||||
this.workFormEntity.finishedCounts = response.returnData.finishedCounts
|
|
||||||
this.workFormEntity.totalCounts = response.returnData.totalCounts
|
|
||||||
this.workFormEntity.tip = response.returnData.tip
|
|
||||||
} else {
|
|
||||||
this.resetForms()
|
|
||||||
ElMessage.error(response.message)
|
|
||||||
}
|
|
||||||
}).catch(err => {
|
|
||||||
console.log(err)
|
|
||||||
this.resetForms()
|
|
||||||
ElMessage.error('查询工作信息错误')
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 查询是否完成
|
|
||||||
queryFinish() {
|
|
||||||
if (this.workFormEntity.goodsId == '') {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
const request = {
|
|
||||||
standId: this.standId,
|
|
||||||
goodsId: this.workFormEntity.goodsId
|
|
||||||
}
|
|
||||||
queryFinishByStandAndGoods(request).then(res => {
|
|
||||||
const response = res.data
|
|
||||||
if (response.code == 0) {
|
|
||||||
if (response.returnData != null) {
|
|
||||||
this.workFormEntity.tip = response.returnData.tip
|
|
||||||
}
|
|
||||||
this.resetForms()
|
|
||||||
ElMessage.success(response.message)
|
|
||||||
}
|
|
||||||
}).catch(err => {
|
|
||||||
console.log(err)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 重置参数
|
|
||||||
resetForms() {
|
|
||||||
this.workFormEntity = reactive({
|
|
||||||
goodsId: '',
|
|
||||||
planPickNum: 0,
|
|
||||||
remainNumOrigin: null,
|
|
||||||
remainNumReal: null,
|
|
||||||
remark: '',
|
|
||||||
finishedRows: 0,
|
|
||||||
totalRows: 0,
|
|
||||||
finishedCounts: 0,
|
|
||||||
totalCounts: 0,
|
|
||||||
tip: ''
|
|
||||||
})
|
|
||||||
this.$refs.goodsId.focus()
|
|
||||||
},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
.content {
|
|
||||||
display: flex;
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.work-area {
|
|
||||||
width: 100%;
|
|
||||||
/* padding: 5px; */
|
|
||||||
}
|
|
||||||
|
|
||||||
.main-area {
|
|
||||||
margin: auto;
|
|
||||||
min-height: fit-content;
|
|
||||||
max-height: 90%;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
min-width: inherit;
|
|
||||||
border: solid 1px;
|
|
||||||
border-radius: 10px;
|
|
||||||
box-shadow: 0px 15px 10px -15px #000;
|
|
||||||
overflow: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.title-area {
|
|
||||||
display: flex;
|
|
||||||
/* min-height: 10%; */
|
|
||||||
max-height: max-content;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
min-width: inherit;
|
|
||||||
border: solid 1px;
|
|
||||||
border-radius: 10px;
|
|
||||||
box-shadow: 0px 15px 10px -15px #000;
|
|
||||||
overflow: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.arrow {
|
|
||||||
background: linear-gradient(-105deg,
|
|
||||||
transparent 50%,
|
|
||||||
#309330 50%,
|
|
||||||
#309330 100%) top right,
|
|
||||||
linear-gradient(-75deg,
|
|
||||||
transparent 50%,
|
|
||||||
#309330 50%,
|
|
||||||
#309330 100%) bottom right;
|
|
||||||
background-size: 100% 50%;
|
|
||||||
height: 400px;
|
|
||||||
width: 250px;
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
display: inline-flex;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.el-input) {
|
|
||||||
width: 195px;
|
|
||||||
height: 130px;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.el-input-number) {
|
|
||||||
width: 125px;
|
|
||||||
height: 130px;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* :deep(.el-input .el-input__inner) {
|
|
||||||
font-size: 60px;
|
|
||||||
height: 130px;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.el-input-number .el-input__inner) {
|
|
||||||
font-size: 60px;
|
|
||||||
height: 130px;
|
|
||||||
} */
|
|
||||||
|
|
||||||
.title-div {
|
|
||||||
display: inline-flex;
|
|
||||||
width: -webkit-fill-available;
|
|
||||||
margin-right: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
background-color: #CCCCCC;
|
|
||||||
}
|
|
||||||
|
|
||||||
.title-text {
|
|
||||||
align-self: center;
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.station-div {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 150px;
|
|
||||||
margin-left: 5px;
|
|
||||||
margin-right: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
background-color: #FFFAAA;
|
|
||||||
}
|
|
||||||
|
|
||||||
.station-text {
|
|
||||||
align-self: center;
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.station-no-div {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 200px;
|
|
||||||
padding: 5px;
|
|
||||||
border: 5px double #000000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.station-no-text {
|
|
||||||
align-self: center;
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-title-div {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 205px;
|
|
||||||
height: 80px;
|
|
||||||
margin: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
background-color: #FFFAAA;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-title-text {
|
|
||||||
align-self: center;
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-form-div {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 195px;
|
|
||||||
margin: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
border: 5px double #000000;
|
|
||||||
margin-top: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-form-div-left {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 125px;
|
|
||||||
margin: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
border: 5px double #000000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-form-div-right {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 50px;
|
|
||||||
margin: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
background-color: #CCCCCC;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-form-text-right {
|
|
||||||
align-self: center;
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,334 +0,0 @@
|
||||||
<template>
|
|
||||||
<el-config-provider :locale="zhCn">
|
|
||||||
<el-container class="content">
|
|
||||||
<div class="work-area">
|
|
||||||
<fieldset class="title-area">
|
|
||||||
<legend>
|
|
||||||
工单
|
|
||||||
</legend>
|
|
||||||
<div class="title-div">
|
|
||||||
<span class="title-text">生产工单管理
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
</fieldset>
|
|
||||||
<fieldset class="main-area">
|
|
||||||
<legend>
|
|
||||||
上传
|
|
||||||
</legend>
|
|
||||||
<el-form ref="workFormRef" :model="workFormEntity" :label-position="labelPosition"
|
|
||||||
label-width="150px" style="max-width: 100%" :rules="rules" status-icon>
|
|
||||||
<div style="display: flex; justify-content: center;">
|
|
||||||
<div style="display: block; margin: 5px;">
|
|
||||||
<!-- <div
|
|
||||||
style="display: inline-flex; justify-content: center; height: 60px; width: 655px; margin: 5px; padding: 5px;">
|
|
||||||
<UploadExcelPart></UploadExcelPart>
|
|
||||||
</div> -->
|
|
||||||
<div style="height: 50px; margin-top: 20px; margin-bottom: 20px;"><UploadExcelOrders></UploadExcelOrders></div>
|
|
||||||
<div style="display: flex; margin-top: 15px">
|
|
||||||
<div
|
|
||||||
style="display: inline-flex; justify-content: center; width: 160px; margin: 5px; padding: 5px; background-color: #CCCCCC;">
|
|
||||||
<span style="align-self: center; font-weight: bold;font-size: 25px;">备注</span>
|
|
||||||
</div>
|
|
||||||
<div
|
|
||||||
style="display: inline-flex; justify-content: center; width: 700px; margin: 5px; padding: 5px; background-color: #00AAE8;">
|
|
||||||
<span style="align-self: center; font-weight: bold;font-size: 25px;">
|
|
||||||
{{ workFormEntity.remark }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</el-form>
|
|
||||||
</fieldset>
|
|
||||||
</div>
|
|
||||||
</el-container>
|
|
||||||
</el-config-provider>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup>
|
|
||||||
import store from '@/store'
|
|
||||||
import { getWorkByStandAndGoods, queryFinishByStandAndGoods } from '@/api/task'
|
|
||||||
import { reactive, ref } from 'vue'
|
|
||||||
import { ElMessage } from 'element-plus'
|
|
||||||
import UploadExcelOrders from '@/excel/UploadExcelOrders.vue'
|
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
name: 'uploadOrders',
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
standId: store.getters.getStandId,
|
|
||||||
timer: '',
|
|
||||||
labelPosition: 'top',
|
|
||||||
workFormRef: ref(),
|
|
||||||
workFormEntity: reactive({
|
|
||||||
goodsId: '',
|
|
||||||
planPickNum: 0,
|
|
||||||
remainNumOrigin: null,
|
|
||||||
remainNumReal: null,
|
|
||||||
remark: '',
|
|
||||||
finishedRows: 0,
|
|
||||||
totalRows: 0,
|
|
||||||
finishedCounts: 0,
|
|
||||||
totalCounts: 0,
|
|
||||||
tip: ''
|
|
||||||
}),
|
|
||||||
rules: reactive({
|
|
||||||
goodsId: [
|
|
||||||
{ required: true, message: '请输入料号' }
|
|
||||||
]
|
|
||||||
}),
|
|
||||||
}
|
|
||||||
},
|
|
||||||
mounted() {
|
|
||||||
this.timer = setInterval(() => {
|
|
||||||
this.queryFinish()
|
|
||||||
}, 2000)
|
|
||||||
},
|
|
||||||
beforeUnmount() {
|
|
||||||
clearInterval(this.timer)
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
// 获取当前工作信息
|
|
||||||
getCurrentWorkInfo() {
|
|
||||||
const request = {
|
|
||||||
standId: this.standId,
|
|
||||||
goodsId: this.workFormEntity.goodsId,
|
|
||||||
userName: store.getters.getUserName
|
|
||||||
}
|
|
||||||
getWorkByStandAndGoods(request).then(res => {
|
|
||||||
const response = res.data
|
|
||||||
if (response.code == 0) {
|
|
||||||
this.workFormEntity.goodsId = response.returnData.goodsId
|
|
||||||
this.workFormEntity.planPickNum = response.returnData.planPickNum
|
|
||||||
this.workFormEntity.remainNumOrigin = response.returnData.remainNumOrigin
|
|
||||||
this.workFormEntity.remainNumReal = response.returnData.remainNumReal
|
|
||||||
this.workFormEntity.remark = response.returnData.remark
|
|
||||||
this.workFormEntity.finishedRows = response.returnData.finishedRows
|
|
||||||
this.workFormEntity.totalRows = response.returnData.totalRows
|
|
||||||
this.workFormEntity.finishedCounts = response.returnData.finishedCounts
|
|
||||||
this.workFormEntity.totalCounts = response.returnData.totalCounts
|
|
||||||
this.workFormEntity.tip = response.returnData.tip
|
|
||||||
} else {
|
|
||||||
this.resetForms()
|
|
||||||
ElMessage.error(response.message)
|
|
||||||
}
|
|
||||||
}).catch(err => {
|
|
||||||
console.log(err)
|
|
||||||
this.resetForms()
|
|
||||||
ElMessage.error('查询工作信息错误')
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 查询是否完成
|
|
||||||
queryFinish() {
|
|
||||||
if (this.workFormEntity.goodsId == '') {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
const request = {
|
|
||||||
standId: this.standId,
|
|
||||||
goodsId: this.workFormEntity.goodsId,
|
|
||||||
userName: store.getters.getUserName
|
|
||||||
}
|
|
||||||
queryFinishByStandAndGoods(request).then(res => {
|
|
||||||
const response = res.data
|
|
||||||
if (response.code == 0) {
|
|
||||||
if (response.returnData != null) {
|
|
||||||
this.workFormEntity.tip = response.returnData.tip
|
|
||||||
}
|
|
||||||
this.resetForms()
|
|
||||||
ElMessage.success(response.message)
|
|
||||||
}
|
|
||||||
}).catch(err => {
|
|
||||||
console.log(err)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 重置参数
|
|
||||||
resetForms() {
|
|
||||||
this.workFormEntity = reactive({
|
|
||||||
goodsId: '',
|
|
||||||
planPickNum: 0,
|
|
||||||
remainNumOrigin: null,
|
|
||||||
remainNumReal: null,
|
|
||||||
remark: '',
|
|
||||||
finishedRows: 0,
|
|
||||||
totalRows: 0,
|
|
||||||
finishedCounts: 0,
|
|
||||||
totalCounts: 0,
|
|
||||||
tip: ''
|
|
||||||
})
|
|
||||||
this.$refs.goodsId.focus()
|
|
||||||
},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
.content {
|
|
||||||
display: flex;
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.work-area {
|
|
||||||
width: 100%;
|
|
||||||
/* padding: 5px; */
|
|
||||||
}
|
|
||||||
|
|
||||||
.main-area {
|
|
||||||
margin: auto;
|
|
||||||
min-height: fit-content;
|
|
||||||
max-height: 90%;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
min-width: inherit;
|
|
||||||
border: solid 1px;
|
|
||||||
border-radius: 10px;
|
|
||||||
box-shadow: 0px 15px 10px -15px #000;
|
|
||||||
overflow: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.title-area {
|
|
||||||
display: flex;
|
|
||||||
/* min-height: 10%; */
|
|
||||||
max-height: max-content;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
min-width: inherit;
|
|
||||||
border: solid 1px;
|
|
||||||
border-radius: 10px;
|
|
||||||
box-shadow: 0px 15px 10px -15px #000;
|
|
||||||
overflow: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.arrow {
|
|
||||||
background: linear-gradient(-105deg,
|
|
||||||
transparent 50%,
|
|
||||||
#309330 50%,
|
|
||||||
#309330 100%) top right,
|
|
||||||
linear-gradient(-75deg,
|
|
||||||
transparent 50%,
|
|
||||||
#309330 50%,
|
|
||||||
#309330 100%) bottom right;
|
|
||||||
background-size: 100% 50%;
|
|
||||||
height: 400px;
|
|
||||||
width: 250px;
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
display: inline-flex;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.el-input) {
|
|
||||||
width: 195px;
|
|
||||||
height: 130px;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.el-input-number) {
|
|
||||||
width: 125px;
|
|
||||||
height: 130px;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* :deep(.el-input .el-input__inner) {
|
|
||||||
font-size: 60px;
|
|
||||||
height: 130px;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.el-input-number .el-input__inner) {
|
|
||||||
font-size: 60px;
|
|
||||||
height: 130px;
|
|
||||||
} */
|
|
||||||
|
|
||||||
.title-div {
|
|
||||||
display: inline-flex;
|
|
||||||
width: -webkit-fill-available;
|
|
||||||
margin-right: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
background-color: #CCCCCC;
|
|
||||||
}
|
|
||||||
|
|
||||||
.title-text {
|
|
||||||
align-self: center;
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.station-div {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 150px;
|
|
||||||
margin-left: 5px;
|
|
||||||
margin-right: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
background-color: #FFFAAA;
|
|
||||||
}
|
|
||||||
|
|
||||||
.station-text {
|
|
||||||
align-self: center;
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.station-no-div {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 200px;
|
|
||||||
padding: 5px;
|
|
||||||
border: 5px double #000000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.station-no-text {
|
|
||||||
align-self: center;
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-title-div {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 205px;
|
|
||||||
height: 80px;
|
|
||||||
margin: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
background-color: #FFFAAA;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-title-text {
|
|
||||||
align-self: center;
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-form-div {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 195px;
|
|
||||||
margin: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
border: 5px double #000000;
|
|
||||||
margin-top: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-form-div-left {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 125px;
|
|
||||||
margin: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
border: 5px double #000000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-form-div-right {
|
|
||||||
display: inline-flex;
|
|
||||||
justify-content: center;
|
|
||||||
width: 50px;
|
|
||||||
margin: 5px;
|
|
||||||
padding: 5px;
|
|
||||||
background-color: #CCCCCC;
|
|
||||||
}
|
|
||||||
|
|
||||||
.display-form-text-right {
|
|
||||||
align-self: center;
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 25px;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -81,7 +81,7 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import { getAllVehicles, updateVehicleInfo } from '@/api/vehicle'
|
import { getAllVehicles, updateVehicleInfo } from '@/api/vehicle'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { vehicleStatusFormatter, locationFormatter, dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { vehicleStatusFormatter, locationFormatter, dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
|
|
@ -161,10 +161,11 @@ export default {
|
||||||
this.vehicles = tableResponse.returnData.lists
|
this.vehicles = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('查询料箱信息错误' + err.message)
|
console.log(err)
|
||||||
|
errorBox('查询料箱信息错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -211,16 +212,14 @@ export default {
|
||||||
updateVehicleInfo(request).then(res => {
|
updateVehicleInfo(request).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('更新料箱信息成功')
|
||||||
message: '更新料箱信息成功',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('更新料箱信息失败:' + err)
|
console.log(err)
|
||||||
|
errorBox('更新料箱信息失败')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCurrentRow(row) {
|
getCurrentRow(row) {
|
||||||
|
|
@ -253,18 +252,12 @@ export default {
|
||||||
document.body.removeChild(link)
|
document.body.removeChild(link)
|
||||||
url.revokeObjectURL(link.href)//移除url对象
|
url.revokeObjectURL(link.href)//移除url对象
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
ElMessage({
|
console.log(e)
|
||||||
message: '下载文件失败:: ' + e,
|
errorBox('下载文件失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage({
|
console.log(err)
|
||||||
message: '导出失败:: ' + err,
|
errorBox('导出失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -91,7 +91,7 @@ import { configTypeFormatter } from '@/utils/formatter.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
</script>
|
</script>
|
||||||
<script>
|
<script>
|
||||||
|
|
@ -176,11 +176,11 @@ export default {
|
||||||
})
|
})
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
ElMessage.error('查询配置错误')
|
errorBox('查询配置错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -213,20 +213,14 @@ export default {
|
||||||
updateConfig(request).then(res => {
|
updateConfig(request).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('更新系统配置成功')
|
||||||
message: '更新系统配置成功',
|
|
||||||
type: 'success'
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage({
|
console.log(err)
|
||||||
message: '更新系统配置失败: ' + err,
|
errorBox('更新系统配置失败')
|
||||||
type: 'error',
|
|
||||||
showClose: true
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -106,7 +106,7 @@
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { queryLogs } from '@/api/wmsLog.js'
|
import { queryLogs } from '@/api/wmsLog.js'
|
||||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox } from '@/utils/myMessageBox.js'
|
||||||
import { timeFormatter, jsonFormatter } from '@/utils/formatter.js'
|
import { timeFormatter, jsonFormatter } from '@/utils/formatter.js'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
</script>
|
</script>
|
||||||
|
|
@ -148,11 +148,12 @@ export default {
|
||||||
this.wmsLogs = tableResponse.returnData.lists
|
this.wmsLogs = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
|
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('查询日志错误' + err.message)
|
console.log(err)
|
||||||
|
errorBox('查询日志错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -157,7 +157,7 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getWorkFlows, updateWorkFlows } from '@/api/kateWork.js'
|
import { getWorkFlows, updateWorkFlows } from '@/api/kateWork.js'
|
||||||
import { ElMessage } from 'element-plus'
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
|
|
@ -234,10 +234,11 @@ export default {
|
||||||
this.workFlowList = tableResponse.returnData.lists
|
this.workFlowList = tableResponse.returnData.lists
|
||||||
this.total = tableResponse.returnData.total
|
this.total = tableResponse.returnData.total
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(tableResponse.message)
|
errorBox(tableResponse.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('查询工作流错误' + err.message)
|
console.log(err)
|
||||||
|
errorBox('查询工作流错误')
|
||||||
})
|
})
|
||||||
this.loading = false
|
this.loading = false
|
||||||
},
|
},
|
||||||
|
|
@ -308,16 +309,14 @@ export default {
|
||||||
updateWorkFlows(params).then(res => {
|
updateWorkFlows(params).then(res => {
|
||||||
if (res.data.code == 0) {
|
if (res.data.code == 0) {
|
||||||
this.dialogVisible = false
|
this.dialogVisible = false
|
||||||
ElMessage({
|
successBox('更新工作流信息成功。')
|
||||||
message: '更新工作流信息成功。',
|
|
||||||
type: 'success',
|
|
||||||
})
|
|
||||||
this.search()
|
this.search()
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(res.data.message)
|
errorBox(res.data.message)
|
||||||
}
|
}
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
ElMessage.error('更新工作流信息失败。')
|
console.log(err)
|
||||||
|
errorBox('更新工作流信息失败。')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getCurrentRow(row) {
|
getCurrentRow(row) {
|
||||||
|
|
|
||||||
|
|
@ -86,6 +86,7 @@
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
import { getPickTasksByPage, updatePickTaskInfo } from '@/api/taskMonitor.js'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
|
import { errorBox, successBox } from '@/utils/myMessageBox.js'
|
||||||
import { ref, reactive } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
import { dateFormatter, timeFormatter } from '@/utils/formatter.js'
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
|
|
|
||||||
|
|
@ -24,23 +24,19 @@ function dueFormatter(date) {
|
||||||
|
|
||||||
function taskStatusFormatter(value) {
|
function taskStatusFormatter(value) {
|
||||||
switch (value) {
|
switch (value) {
|
||||||
|
case -2:
|
||||||
|
return '重复入库'
|
||||||
|
case -1:
|
||||||
|
return '暂存任务'
|
||||||
case 0:
|
case 0:
|
||||||
return '任务新建,待下发'
|
return '任务新建,待下发'
|
||||||
case 1:
|
case 1:
|
||||||
return '任务已下发'
|
return '任务已下发'
|
||||||
case 2:
|
case 2:
|
||||||
return '任务开始执行'
|
return '任务开始执行'
|
||||||
case 3:
|
|
||||||
return '出库完成'
|
|
||||||
case 4:
|
|
||||||
return '输送线转运中'
|
|
||||||
case 5:
|
|
||||||
return '到达拣选站台'
|
|
||||||
case 6:
|
|
||||||
return '正在拣货'
|
|
||||||
case 7:
|
|
||||||
return '正在回库'
|
|
||||||
case 8:
|
case 8:
|
||||||
|
return '拣选中'
|
||||||
|
case 9:
|
||||||
return '盘点中'
|
return '盘点中'
|
||||||
case 100:
|
case 100:
|
||||||
return '任务完成'
|
return '任务完成'
|
||||||
|
|
@ -49,7 +45,7 @@ function taskStatusFormatter(value) {
|
||||||
case 999:
|
case 999:
|
||||||
return '任务异常'
|
return '任务异常'
|
||||||
default:
|
default:
|
||||||
return '未完成'
|
return '其他状态'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -181,6 +177,14 @@ function replaceEnglishAndNumberIGAI(value) {
|
||||||
return value.replace(/[^\u4e00-\u9fa5a-zA-Z0-9]/g, '')
|
return value.replace(/[^\u4e00-\u9fa5a-zA-Z0-9]/g, '')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function yesOrNoFormatter(value) {
|
||||||
|
return value == 1 ? '是' : '否'
|
||||||
|
}
|
||||||
|
|
||||||
|
function converseYesOrNoFormatter(value) {
|
||||||
|
return value == 0 ? '是' : '否'
|
||||||
|
}
|
||||||
|
|
||||||
export {
|
export {
|
||||||
timeFormatter,
|
timeFormatter,
|
||||||
dateFormatter,
|
dateFormatter,
|
||||||
|
|
@ -194,5 +198,7 @@ export {
|
||||||
locationStatusFormatter,
|
locationStatusFormatter,
|
||||||
sizeFormatter,
|
sizeFormatter,
|
||||||
jsonFormatter,
|
jsonFormatter,
|
||||||
replaceEnglishAndNumberIGAI
|
replaceEnglishAndNumberIGAI,
|
||||||
|
yesOrNoFormatter,
|
||||||
|
converseYesOrNoFormatter
|
||||||
}
|
}
|
||||||
64
src/utils/myMessageBox.js
Normal file
64
src/utils/myMessageBox.js
Normal file
|
|
@ -0,0 +1,64 @@
|
||||||
|
import { ElMessageBox } from 'element-plus'
|
||||||
|
|
||||||
|
function errorBox(msg, myCallBack) {
|
||||||
|
ElMessageBox.alert(msg, '错误', {
|
||||||
|
autofocus: true,
|
||||||
|
confirmButtonText: '确认',
|
||||||
|
center: true,
|
||||||
|
type: 'error',
|
||||||
|
closeOnPressEscape: true,
|
||||||
|
showClose: false,
|
||||||
|
callback: (action) => {
|
||||||
|
myCallBack()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
function successBox(msg, myCallBack) {
|
||||||
|
ElMessageBox.alert(msg, '成功', {
|
||||||
|
autofocus: true,
|
||||||
|
confirmButtonText: '确认',
|
||||||
|
center: true,
|
||||||
|
type: 'success',
|
||||||
|
closeOnPressEscape: true,
|
||||||
|
showClose: false,
|
||||||
|
callback: (action) => {
|
||||||
|
myCallBack()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
function infoBox(msg, myCallBack) {
|
||||||
|
ElMessageBox.alert(msg, '提示', {
|
||||||
|
autofocus: true,
|
||||||
|
confirmButtonText: '确认',
|
||||||
|
center: true,
|
||||||
|
type: 'info',
|
||||||
|
closeOnPressEscape: true,
|
||||||
|
showClose: false,
|
||||||
|
callback: (action) => {
|
||||||
|
myCallBack()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
function warningBox(msg, myCallBack) {
|
||||||
|
ElMessageBox.alert(msg, '警告', {
|
||||||
|
autofocus: true,
|
||||||
|
confirmButtonText: '确认',
|
||||||
|
center: true,
|
||||||
|
type: 'warning',
|
||||||
|
closeOnPressEscape: true,
|
||||||
|
showClose: false,
|
||||||
|
callback: (action) => {
|
||||||
|
myCallBack()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export {
|
||||||
|
errorBox,
|
||||||
|
successBox,
|
||||||
|
infoBox,
|
||||||
|
warningBox
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue
Block a user