bug solved
This commit is contained in:
parent
26e95bfa56
commit
ee1ee77240
|
@ -25,7 +25,7 @@ module.exports = Self => {
|
||||||
});
|
});
|
||||||
|
|
||||||
Self.updateQuantity = async(id, quantity) => {
|
Self.updateQuantity = async(id, quantity) => {
|
||||||
if (isNaN(params.editLines[0].discount))
|
if (isNaN(quantity))
|
||||||
throw new Error(`The value should be a number`);
|
throw new Error(`The value should be a number`);
|
||||||
|
|
||||||
let currentLine = await Self.app.models.Sale.findOne({where: {id: id}, fields: ['quantity']});
|
let currentLine = await Self.app.models.Sale.findOne({where: {id: id}, fields: ['quantity']});
|
||||||
|
|
Loading…
Reference in New Issue