Browse Source

移除多余组件

wms3.0_pda
niexiting 11 months ago
parent
commit
6b36b25fbc
  1. 110
      mycomponents/wincom/winScanContainerNumber.vue
  2. 6
      pages/query/container.vue

110
mycomponents/wincom/winScanContainerNumber.vue

@ -1,110 +0,0 @@
<template>
<winScanStandard ref="standard" :title="title" @getScanResult="getScanResult">
</winScanStandard>
</template>
<script>
import {
getContainerByNumber,
} from '@/api/request.js';
import winScanStandard from '@/mycomponents/wincom/scanCom/winScanStandard.vue'
export default {
components: {
winScanStandard
},
emits: ["getScanCode"],
props: {
title: {
type: String,
default: '器具代码'
},
locationTypeList: {
type: Array,
default: []
},
isJudgeStatus: {
type: Boolean,
default: true
},
},
data() {
return {
code: '',
number: '',
container: {}
}
},
created() {
},
methods: {
openScanPopup() {
this.$refs.standard.openScanPopup()
},
closeScanPopup() {
this.$refs.standard.closeScanPopup()
},
scanClick() {
this.$refs.standard.clickScanMsg();
},
cancelClick() {
this.$refs.standard.clearScanValue();
},
getScanResult(result) {
if (result.label.Type == "QRCode") {
this.code = result.label.itemCode;
} else if (result.label.Type == "BarCode") {
this.code = result.label.code;
}
uni.showLoading({
title: '扫描中...',
mask: true
});
getContainerByNumber(this.code).then(res => {
uni.hideLoading();
if (res.data.total > 0) {
var number = res.data.list[0].number;
var type = res.data.list[0].type;
var status = res.data.list[0].status;
if (this.isJudgeStatus) {
if (status == 'qjztUsed') {
this.container = res.data.list[0];
this.callBack();
} else {
this.$refs.standard.showWarningMessage("扫描器具[" + this.code + "]不可用", res => {})
}
}
} else {
this.$refs.standard.showWarningMessage('未查询到器具' + '【' + this.code + '】', res => {
})
}
}).catch(error => {
uni.hideLoading();
this.$refs.standard.showWarningMessage(error, res => {
})
})
},
callBack() {
this.closeScanPopup();
this.$emit("getScanCode", this.container, this.number);
},
getfocus() {
this.$refs.standard.getfocus();
},
}
}
</script>
<style>
</style>

6
pages/query/container.vue

@ -52,7 +52,7 @@
import winScanButton from '@/mycomponents/scan/winScanButton.vue' import winScanButton from '@/mycomponents/scan/winScanButton.vue'
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import comLocationDetailCard from '@/pages/query/coms/comLocationDetailCard.vue' import comLocationDetailCard from '@/pages/query/coms/comLocationDetailCard.vue'
import winScanItem from '@/mycomponents/scan/winScanItem.vue' import winScanContainer from "@/mycomponents/scan/winScanContainer.vue"
import containerInfo from '@/mycomponents/container/containerInfo.vue' import containerInfo from '@/mycomponents/container/containerInfo.vue'
export default { export default {
@ -64,7 +64,9 @@
comMessage, comMessage,
comLocationDetailCard, comLocationDetailCard,
winScanItem, winScanItem,
containerInfo containerInfo,
winScanContainer
}, },
data() { data() {
return { return {

Loading…
Cancel
Save