Commit b7cabf0e authored by 15008242619's avatar 15008242619 Committed by jingnan

退库单退库优化

parent 96c73d8b
......@@ -140,7 +140,6 @@ export default {
this.dialogVisible = true
},
confirm() {
console.log(this.selectionRows)
let isTkdBack = 0
this.selectionRows.forEach(item => {
if (item.remark !== '退库单退库') {
......@@ -155,7 +154,7 @@ export default {
post('/InventoryRequest/purchaseApply/submit?applyIds=' + this.selectionRows.map(item => Number(item.id))).then(res => {
this.$utils.showMessageSuccess('提交成功')
this.$refs.applyTable.$refs.asCom.getData()
}).catch(() => {
}).catch(err => {
this.$utils.showMessageWarning('出现异常,提交失败')
}).finally(() => {
this.dialogVisible = false
......@@ -168,16 +167,18 @@ export default {
this.dialogVisible = false
},
setPersonConfirm() {
let ids = []
console.log(this.selectionRows)
const ids = []
if (this.selectionRows && this.selectionRows.length) {
ids = this.selectionRows.map(item => item.id)
this.selectionRows.map(item => item.inStorageRequestItems.map(i => ids.push(i.id)))
}
post('/InStorageRequestItem/creator/apply?userIds=' + this.form.userIds, ids).then(res => {
this.$utils.showMessageSuccess('提交成功')
this.$refs.applyTable.$refs.asCom.getData()
}).catch(() => {
this.$utils.showMessageWrong('出现异常,提交失败')
setTimeout(() => {
this.$refs.applyTable.$refs.asCom.getData()
}, 1500)
}).catch(err => {
this.$utils.showMessageWarning('出现异常,提交失败')
console.log(err)
}).finally(() => {
this.dialogVisible = false
this.setPersonVisible = false
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment