mirror of
https://github.com/PanJiaChen/vue-element-admin.git
synced 2025-08-10 20:39:48 +08:00
Fixed error with Search Product from Value instead name (#680)
This commit is contained in:
parent
4401c1d77d
commit
5e8b46ad32
@ -227,24 +227,13 @@ export default {
|
|||||||
if (!this.isEmptyValue(keyValue.subKeyLayoutUuid)) {
|
if (!this.isEmptyValue(keyValue.subKeyLayoutUuid)) {
|
||||||
this.loadKeyLayout(keyValue.subKeyLayoutUuid)
|
this.loadKeyLayout(keyValue.subKeyLayoutUuid)
|
||||||
} else {
|
} else {
|
||||||
const products = this.listOrderLine.find(item => item.lineDescription === keyValue.name)
|
this.$store.dispatch('notifyActionKeyPerformed', {
|
||||||
// TODO: Change this dispatch
|
columnName: 'ProductValue',
|
||||||
if (!this.isEmptyValue(products) && keyValue.quantity > 1) {
|
value: {
|
||||||
this.$store.dispatch('notifyActionKeyPerformed', {
|
QtyEntered: keyValue.quantity,
|
||||||
value: {
|
value: keyValue.productValue
|
||||||
QtyEntered: keyValue.quantity,
|
}
|
||||||
value: keyValue.name
|
})
|
||||||
}
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
this.$store.dispatch('notifyActionKeyPerformed', {
|
|
||||||
columnName: 'ProductValue',
|
|
||||||
value: {
|
|
||||||
QtyEntered: keyValue.quantity,
|
|
||||||
value: keyValue.name
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleCommand(command) {
|
handleCommand(command) {
|
||||||
|
@ -115,7 +115,7 @@ export function convertKey(keyToConvert) {
|
|||||||
sequence: keyToConvert.sequence,
|
sequence: keyToConvert.sequence,
|
||||||
spanX: keyToConvert.span_x,
|
spanX: keyToConvert.span_x,
|
||||||
spanY: keyToConvert.span_y,
|
spanY: keyToConvert.span_y,
|
||||||
productUuid: keyToConvert.product_uuid,
|
productValue: keyToConvert.product_value,
|
||||||
quantity: keyToConvert.quantity,
|
quantity: keyToConvert.quantity,
|
||||||
resourceReference: convertResourceReference(
|
resourceReference: convertResourceReference(
|
||||||
keyToConvert.resource_reference
|
keyToConvert.resource_reference
|
||||||
|
Loading…
x
Reference in New Issue
Block a user