feat: added translations and show error in item-type
gitea/salix/pipeline/pr-dev This commit looks good
Details
gitea/salix/pipeline/pr-dev This commit looks good
Details
This commit is contained in:
parent
86a36732f0
commit
97f08542be
|
@ -390,6 +390,7 @@
|
||||||
"The web user's email already exists": "El correo del usuario web ya existe",
|
"The web user's email already exists": "El correo del usuario web ya existe",
|
||||||
"Sales already moved": "Ya han sido transferidas",
|
"Sales already moved": "Ya han sido transferidas",
|
||||||
"The raid information is not correct": "La información de la redada no es correcta",
|
"The raid information is not correct": "La información de la redada no es correcta",
|
||||||
"There are tickets to be invoiced": "Hay tickets para esta zona, borralos primero"
|
"There are tickets to be invoiced": "Hay tickets para esta zona, borralos primero",
|
||||||
|
"An item type with the same code already exists": "Un tipo con el mismo código ya existe"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
name: Minimum Quantity
|
||||||
|
columns:
|
||||||
|
ended: Ended
|
||||||
|
code: Code
|
||||||
|
started: Started
|
|
@ -0,0 +1,5 @@
|
||||||
|
name: Cantidad Mínima
|
||||||
|
columns:
|
||||||
|
ended: Finaliza
|
||||||
|
quantity: Cantidad
|
||||||
|
started: Comienza
|
|
@ -46,4 +46,4 @@ columns:
|
||||||
itemFk: item
|
itemFk: item
|
||||||
density: density
|
density: density
|
||||||
compression: compression
|
compression: compression
|
||||||
|
minQuantity: min quantity
|
||||||
|
|
|
@ -46,4 +46,4 @@ columns:
|
||||||
itemFk: artículo
|
itemFk: artículo
|
||||||
density: densidad
|
density: densidad
|
||||||
compression: compresión
|
compression: compresión
|
||||||
|
minQuantity: Cantidad mínima
|
||||||
|
|
|
@ -0,0 +1,9 @@
|
||||||
|
let UserError = require('vn-loopback/util/user-error');
|
||||||
|
|
||||||
|
module.exports = Self => {
|
||||||
|
Self.rewriteDbError(function(err) {
|
||||||
|
if (err.code === 'ER_DUP_ENTRY')
|
||||||
|
return new UserError(`An item type with the same code already exists`);
|
||||||
|
return err;
|
||||||
|
});
|
||||||
|
};
|
Loading…
Reference in New Issue