Browse Source

修改直接发料可以删除物料

wms3.0_pda
lijuncheng 10 months ago
parent
commit
53c2de8134
  1. 23
      pages/issue/coms/comIssueDetailCard.vue
  2. 35
      pages/issue/record/issueRecord.vue

23
pages/issue/coms/comIssueDetailCard.vue

@ -8,7 +8,12 @@
<uni-collapse-item :open="true">
<template v-slot:title>
<!-- 物品 -->
<item-qty :dataContent="item" :handleQty="item.handleQty"></item-qty>
<uni-swipe-action ref="swipeAction">
<uni-swipe-action-item @click="itemCoceClick($event,item,index)"
:right-options="removeOptions">
<item-qty :dataContent="item" :handleQty="item.handleQty"></item-qty>
</uni-swipe-action-item>
</uni-swipe-action>
<!-- <com-issue-request-info :workShopCode="dataContent.workShopCode" :dataContent="dataContent">
</com-issue-request-info> -->
</template>
@ -68,11 +73,12 @@
import comIssueRequestInfo from '@/pages/issue/coms/comIssueRequestInfo.vue'
import {
getDetailOption,
getEditRemoveOption
getEditRemoveOption,
getRemoveOption
} from '@/common/array.js';
export default {
emits: ['updateData'],
emits: ['updateData',"removeItemCode"],
components: {
itemQty,
recommend,
@ -107,13 +113,15 @@
editItem: {},
batchItem: {},
detailOptions: [],
scanOptions: []
scanOptions: [],
removeOptions:[]
}
},
mounted() {
this.detailOptions = getDetailOption();
this.scanOptions = getEditRemoveOption();
this.removeOptions = getRemoveOption()
},
methods: {
@ -136,6 +144,13 @@
}
},
itemCoceClick(e,item,index){
if (e.content.text == "移除") {
this.dataContent.Items.splice(index, 1);
this.$emit('removeItemCode')
}
},
edit(batch, item) {
let that = this;
that.editItem = item;

35
pages/issue/record/issueRecord.vue

@ -16,11 +16,13 @@
:rawLocationCode="toLocation.toLocationCode"></work-station>
</view>
<com-issue-detail-card ref='comIssueDetailCard' :dataContent="toLocation"
@updateData='updateData'>
@updateData='updateData'
@removeItemCode ="removeItemCode"
>
</com-issue-detail-card>
</view>
</scroll-view>
<button class="btn_add" @click="goScan(true)">+去添加</button>
<button class="btn_add" @click="goScan(false)">+去添加</button>
</view>
<view class="page-footer">
@ -35,13 +37,15 @@
</view>
</view>
</view>
</view>
<com-issue-request-popup ref="comIssueRequestPopup" @confirm='requestConfirm'></com-issue-request-popup>
<win-scan-button v-if='detailSource.length>0' @goScan='openScanDetailPopup'></win-scan-button>
<com-scan-issue-pack ref="comScanIssuePack" @closeScan='closeScan' @updateData='updateData'>
</com-scan-issue-pack>
<com-message ref="comMessage"></com-message>
<comMessage ref="comMessage"></comMessage>
</template>
<script>
@ -131,6 +135,7 @@
this.toInventoryStatuses = res.toInventoryStatuses
this.goScan(true)
} else {
this.showErrorMessage(res.message)
}
});
@ -148,6 +153,7 @@
});
},
goScan(editPosition) {
this.$refs.comIssueRequestPopup.openRequestPopup(editPosition);
},
@ -267,6 +273,14 @@
// item.handleQty=itemHandleQty;
// this.closeScan();
},
removeItemCode(){
var isClear =this.detailSource[0].Items.length==0
if(isClear){
this.clearData();
this.$refs.comIssueRequestPopup.initData()
}
},
setParams() {
var subList = []
@ -381,10 +395,15 @@
})
},
clearData() {
this.detailSource = [];
this.requestList = [];
this.dataContent = {}
this.managementList = []
this.subList= [], //subList
this.detailSource=[], //
this.detailOptions=[],
this.scanOptions= [],
this.workShopCode="",
this.requestList= [],
this.dataContent= {},
this.managementList= []
},
showMessage(message) {

Loading…
Cancel
Save