2/26 虚拟槽位的上货 扫码剔除 1.0

20240912_adapter
wangwei 1 month ago
parent 38b18df431
commit 99862eb374

@ -639,7 +639,7 @@ export default {
codeArray: [],
curQueueName: "",
scanReCount: 0,
curQueue: null,
curQueue: {},
redMesg: false,
redMesgOld: false,
productName: null,
@ -1196,6 +1196,15 @@ export default {
this.$refs.inputRef.focus()
this.$refs.inputRef.select()
this.orderFormData.relId = null
if (response.data.queueCode != null){
console.log("zhzhzhzhzhzh",response.data.queueCode)
//
// this.curQueue.code = response.data.queueCode
this.sharedData = response.data.queueCode
EventBus.$emit('update-data', { message: this.sharedData });
// //
this.getOrder()
}
} else {
if (response.code == 502) {
//ID
@ -1341,7 +1350,9 @@ export default {
},
getOrderData(orderDetail) {
this.productName = orderDetail.coName
this.curQueueName = "当前取货槽:" + this.productName + "(" + this.curQueue.code + ")"
if (this.queueStatus == 1){
this.curQueueName = "当前取货槽:" + this.productName + "(" + this.curQueue.code + ")"
}
this.orderStatus = true
},
getCount(count){
@ -1808,19 +1819,23 @@ export default {
if (this.splitType == 'out') {
if (!this.scanCode.includes("DMQ")) {
if (this.queueStatus == "0" && this.orderFormData.workPlaceQueueCode) {
this.$message.warning('当前工位无需按取货槽上架')
return;
} else if (this.queueStatus == "1" && isBlank(this.orderFormData.workPlaceQueueCode)) {
// if (this.queueStatus == "0" && this.orderFormData.workPlaceQueueCode) {
// this.$message.warning('')
// return;
// } else
if (this.queueStatus == "1" && isBlank(this.orderFormData.workPlaceQueueCode)) {
this.scanCode = ''
this.$message.warning('当前工位需按取货槽上架')
return;
}
} else {
if (this.queueStatus == "0" && this.orderFormData.workPlaceQueueCode) {
this.$message.warning('当前工位无需按取货槽上架')
return;
} else if (this.queueStatus == "1" && !this.orderFormData.workPlaceQueueCode) {
//
// if (this.queueStatus == "0" && this.orderFormData.workPlaceQueueCode) {
// this.$message.warning('')
// return;
// }
// else
if (this.queueStatus == "1" && !this.orderFormData.workPlaceQueueCode) {
this.$message.warning('当前工位需按取货槽上架')
return;
}
@ -2464,6 +2479,12 @@ export default {
code : data,
workPlaceIdFk : this.workplaceId
}
if (this.queueStatus == 0){
this.sharedData = this.curQueue.code
EventBus.$emit('update-data', { message: this.sharedData });
// //
this.getOrder()
}
getByCode(query).then((response) => {
this.loading = false;
if (response.code == 20000) {

@ -25,14 +25,15 @@
>
<el-button size="mini" type="primary" @click.native="paizhao()"
v-if="collectSet != null && collectSet.autoDecode == 0"
:disabled="redMeg || (splitCodes.length === 0 && queueCodes.length === 0)"
style="margin-right: 8px;border-radius: 5%;"
>拍照解码
</el-button>
<el-button size="mini" type="primary" @click.native="fallbackCode()" :disabled="redMeg"
<el-button size="mini" type="primary" @click.native="fallbackCode()" :disabled="redMeg || (splitCodes.length === 0 && queueCodes.length === 0)"
style="margin-right: 8px;border-radius: 5%;"
>回退
</el-button>
<el-button size="mini" type="primary" @click.native="dropCode()" :disabled="redMeg"
<el-button size="mini" type="primary" @click.native="dropCode()" :disabled="redMeg || (splitCodes.length === 0 && queueCodes.length === 0)"
style="margin-right: 8px;border-radius: 5%;"
>放弃
</el-button>
@ -295,7 +296,8 @@ import {splitFifoDetail} from '@/api/inout/splitCode'
import {batchAddCode, batchVailCode, enterCodeWeb} from '@/api/inout/order'
import {getSet} from '@/api/collect/collectSet'
import A from '@/plugins/KeyScaner'
import { EventBus } from '@/eventBus'; // 线
import { EventBus } from '@/eventBus';
import { getUserBindWork } from '@/api/basic/collectPoint/userWorkplace' // 线
const SLOT_CODE_PREFIX = 'DMQ'
@ -373,7 +375,10 @@ export default {
valiCodes: [],
//weksolket
sitcomScan: false,
sictomText: ''
sictomText: '',
allWorkPlaces:[],
//
queueStatus: null,
}
},
methods: {
@ -628,8 +633,10 @@ export default {
if (response.code == 20000) {
this.curQueue = response.data
this.productName = this.curQueue.cpmctymc
this.curQueueName = this.getQueueName()
this.curProductData = this.getCurProduct()
if (this.queueStatus == 1){
this.curQueueName = this.getQueueName()
this.curProductData = this.getCurProduct()
}
this.redMeg = false
this.isCheckQueue = true
this.init()
@ -723,9 +730,9 @@ export default {
})
},
dropCode() {
this.redMeg = true
// this.redMeg = true
this.curQueueName = ''
this.isCheckQueue = false
// this.isCheckQueue = false
this.curProductData = ''
this.curQueue = null
this.queueCodes = []
@ -745,6 +752,7 @@ export default {
this.queueCodeTotal = 0
this.collectSet = null
this.alertInit()
this.findAllWorkPlaces()
},
paizhao() {
if (this.ws && this.ws.readyState === WebSocket.OPEN) {
@ -909,7 +917,31 @@ export default {
this.workplaceId = this.$route.query.workplaceId
this.handleSlotCodeScan()
}
}
},
findAllWorkPlaces() {
let query = {
page: 1,
limit: 100,
}
getUserBindWork(query).then((res) => {
this.allWorkPlaces = res.data.list || [];
{
let item = this.allWorkPlaces.find(item => item.workplaceId == this.workplaceId )
this.queueStatus = item.queueStatus
if (this.curQueue == null){
if (this.queueStatus == 0) {
this.redMeg = false
this.isCheckQueue = true
}else {
this.redMeg = true
this.isCheckQueue = false
}
}
}
})
},
},
computed: {
//
@ -983,7 +1015,8 @@ export default {
},
created() {
this.workplaceId = this.$route.query.workplaceId
// this.selectSysParam()
this.findAllWorkPlaces()
this.selectSysParam()
if (!isBlank(this.message)){
this.scanCode = this.message
this.handleSlotCodeScan()

Loading…
Cancel
Save