Browse Source

发料任务跳转到详情

hella_online_20240829
lijuncheng 5 months ago
parent
commit
bd90f6eb94
  1. 4
      src/mycomponents/jobList/jobList.vue
  2. 1
      src/mycomponents/scan/winComScan.vue
  3. 4
      src/pages/issue/coms/comScanIssuePack.vue
  4. 17
      src/pages/issue/job/issueDetail.vue
  5. 15
      src/pages/issue/job/issueJob.vue

4
src/mycomponents/jobList/jobList.vue

@ -38,10 +38,10 @@ import { onShow } from '@dcloudio/uni-app';
methods:{
openList(list){
this.list = list
this.$refs.listPopup.open('center')
},
selectItem(item,index){
this.$refs.listPopup.close();
this.$emit("selectItem", item);
}
}
@ -55,7 +55,7 @@ import { onShow } from '@dcloudio/uni-app';
align-items: center;
.list{
width: 80%;
max-height:80vh;
max-height:50vh;
overflow-y: auto;
border-radius: 10px !important;
.slot-image{

1
src/mycomponents/scan/winComScan.vue

@ -205,6 +205,7 @@
getLabelInfo(content, this.headerType, callback => {
// uni.hideLoading();
let scanResult = callback;
scanResult.scanMessage=content
if (scanResult.success) {
that.clear();
// that.getfocus();//

4
src/pages/issue/coms/comScanIssuePack.vue

@ -173,7 +173,7 @@ import { getDirectoryItemArray } from '../../../common/directory.js';
this.scanOptions = getDetailEditRemoveOption();
},
methods: {
openScanPopupForJobSimulate(content, jobcontent) {
openScanPopupForJobSimulate(content, jobcontent,scanMessage) {
this.issueRecord = [];
this.dataContent = content;
this.jobContent = jobcontent;
@ -187,7 +187,7 @@ import { getDirectoryItemArray } from '../../../common/directory.js';
if(timer){
clearTimeout(timer)
}
this.$refs.comscansimulate.setItemCodeSimulate(item.copyContent)
this.$refs.comscansimulate.setItemCodeSimulate(scanMessage)
this.$refs.comscansimulate.clickScanMsg();
}, 500)
},

17
src/pages/issue/job/issueDetail.vue

@ -97,7 +97,7 @@
detailOptions: [],
scanOptions: [],
jobStatus: "",
scanedPackingNumber: ''
scanMessage: ''
};
},
@ -107,7 +107,7 @@
onLoad(option) {
this.id = option.id;
this.scanedPackingNumber = option.scaned || '';
this.scanMessage = option.scanMessage || '';
if (this.id != undefined) {
//
if (option.status == "1") {
@ -198,6 +198,12 @@
that.subList = res.data.subList;
that.detailSource = getDataSource(that.detailSource, that.subList)
//
if(this.scanMessage){
this.openScanPopupSimulate(this.scanMessage);
}
setTimeout(r => {
that.resizeCollapse();
}, 100)
@ -435,6 +441,7 @@
},
afterScan() {
this.resizeCollapse();
this.detailSource.forEach(detail => {
let s = '';
detail.Items.forEach(item => {
@ -520,9 +527,9 @@
this.$refs.comScanIssuePack.openScanPopup(this.detailSource, this.jobContent);
},
// openScanPopupSimulate(){
// this.$refs.comScanIssuePack.openScanPopupForJobSimulate(this.detailSource, this.jobContent);
// },
openScanPopupSimulate(scanMessage){
this.$refs.comScanIssuePack.openScanPopupForJobSimulate(this.detailSource, this.jobContent,scanMessage);
},
closeScanPopup() {
this.updateCommitBtn();

15
src/pages/issue/job/issueJob.vue

@ -21,7 +21,7 @@
<uni-load-more :status="loadingType" v-if="jobList.length>0" />
</view>
<win-scan-button @goScan='openScanPopup' v-if="false"></win-scan-button>
<win-scan-button @goScan='openScanPopup' v-if="jobList.length>0"></win-scan-button>
<winScanPackJob ref="scanPopup" @getResult='getScanResult' ></winScanPackJob>
<jobList ref="jobList" @selectItem="selectItem"></jobList>
<comMessage ref="comMessage"></comMessage>
@ -232,10 +232,10 @@
},
openJobDetail(item, packingNumber = '') {
openJobDetail(item, scanMessage = '') {
uni.navigateTo({
url: './issueDetail?id=' + item.masterId + '&status=' + item.status+'&scaned=' +
packingNumber
url: './issueDetail?id=' + item.masterId + '&status=' + item.status+'&scanMessage=' +
scanMessage
});
},
@ -249,7 +249,7 @@
selectItem(item) {
this.$refs.scanPopup.closeScanPopup();
this.openJobDetail(item,item.packingNumber);
this.openJobDetail(item,this.scanMessage);
},
swipeClick(e, dataContent) {
@ -371,6 +371,7 @@
sort: 'createTime',
by: 'asc'
}).then(res => {
this.scanMessage =result.scanMessage
let resultList = res.data.list;
if (resultList.length > 0) {
resultList.forEach(item => {
@ -386,10 +387,10 @@
if (list.length > 1) {
this.$refs.jobList.openList(list)
} else {
this.selectItem(list[0])
this.selectItem(list[0],scanMessage)
}
} else {
this.showMessage('未查找到任务')
this.showMessage("物料号+["result.label.itemCode+"]批次["+result.label.batch+']未查找到任务')
}
}).catch(error => {
this.showMessage(error)

Loading…
Cancel
Save