Merge remote-tracking branch 'origin/dev-nx' into dev-nx
This commit is contained in:
commit
d02ec45f57
|
|
@ -1118,45 +1118,58 @@ export default {
|
|||
saveCodeOut() {
|
||||
this.$refs.codeOutForm.validate((valid) => {
|
||||
if (!valid) return
|
||||
if (this.maCodeList.length <= this.outObj.outNum) {
|
||||
let params = this.maCodeList.map((item) => {
|
||||
let obj = {
|
||||
id: this.outObj.id,
|
||||
maId: item,
|
||||
manageType: 0,
|
||||
carCode: this.codeOutForm.carCode,
|
||||
typeId: this.outObj.typeId,
|
||||
parentId: this.outObj.parentId,
|
||||
outNum: 1,
|
||||
taskId: this.outObj.taskId,
|
||||
createBy: sessionStorage.getItem('userId'),
|
||||
companyId: this.outObj.companyId,
|
||||
}
|
||||
return obj
|
||||
})
|
||||
// console.log(params)
|
||||
submitOut(params).then((res) => {
|
||||
this.$modal.msgSuccess('出库成功')
|
||||
this.openCode = false
|
||||
this.handleDialogQuery()
|
||||
this.handleQuery()
|
||||
})
|
||||
} else {
|
||||
this.$modal.msgError('所选机具编码已超出出库数量!')
|
||||
}
|
||||
// 弹框提示
|
||||
this.$confirm('确定出库该设备么?设备出库后无法修改', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
}).then(() => {
|
||||
if (this.maCodeList.length <= this.outObj.outNum) {
|
||||
let params = this.maCodeList.map((item) => {
|
||||
let obj = {
|
||||
id: this.outObj.id,
|
||||
maId: item,
|
||||
manageType: 0,
|
||||
carCode: this.codeOutForm.carCode,
|
||||
typeId: this.outObj.typeId,
|
||||
parentId: this.outObj.parentId,
|
||||
outNum: 1,
|
||||
taskId: this.outObj.taskId,
|
||||
createBy: sessionStorage.getItem('userId'),
|
||||
companyId: this.outObj.companyId,
|
||||
}
|
||||
return obj
|
||||
})
|
||||
// console.log(params)
|
||||
submitOut(params).then((res) => {
|
||||
this.$modal.msgSuccess('出库成功')
|
||||
this.openCode = false
|
||||
this.handleDialogQuery()
|
||||
this.handleQuery()
|
||||
})
|
||||
} else {
|
||||
this.$modal.msgError('所选机具编码已超出出库数量!')
|
||||
}
|
||||
})
|
||||
})
|
||||
},
|
||||
//数量出库保存
|
||||
saveNumOut() {
|
||||
this.$refs.numOutForm.validate((valid) => {
|
||||
if (!valid) return
|
||||
this.outNumList[0].carCode = this.numOutForm.carCode
|
||||
let param = this.outNumList
|
||||
submitNumOut(param).then((res) => {
|
||||
this.$modal.msgSuccess('出库成功')
|
||||
this.openNum = false
|
||||
this.handleDialogQuery()
|
||||
this.handleQuery()
|
||||
this.$confirm('确定出库该设备么?设备出库后无法修改', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
}).then(() => {
|
||||
this.outNumList[0].carCode = this.numOutForm.carCode
|
||||
let param = this.outNumList
|
||||
submitNumOut(param).then((res) => {
|
||||
this.$modal.msgSuccess('出库成功')
|
||||
this.openNum = false
|
||||
this.handleDialogQuery()
|
||||
this.handleQuery()
|
||||
})
|
||||
})
|
||||
})
|
||||
},
|
||||
|
|
|
|||
Loading…
Reference in New Issue