minor bug
gitea/salix/pipeline/head This commit is unstable
Details
gitea/salix/pipeline/head This commit is unstable
Details
This commit is contained in:
parent
da7d9b48ea
commit
399612c9db
|
@ -232,5 +232,6 @@
|
|||
"Fichadas impares": "Fichadas impares",
|
||||
"Descanso diario 12h.": "Descanso diario 12h.",
|
||||
"Descanso semanal 36h. / 72h.": "Descanso semanal 36h. / 72h.",
|
||||
"Dirección incorrecta": "Dirección incorrecta"
|
||||
"Dirección incorrecta": "Dirección incorrecta",
|
||||
"Prices recalculated": "Precios recalculados"
|
||||
}
|
|
@ -27,6 +27,7 @@ module.exports = Self => {
|
|||
const myOptions = {};
|
||||
const userId = ctx.req.accessToken.userId;
|
||||
const models = Self.app.models;
|
||||
const $t = ctx.req.__;
|
||||
|
||||
if (typeof options == 'object')
|
||||
Object.assign(myOptions, options);
|
||||
|
@ -41,14 +42,13 @@ module.exports = Self => {
|
|||
id
|
||||
], myOptions);
|
||||
*/
|
||||
const oldProperties = await loggable.translateValues(Self, {price: 'Prices recalculated'});
|
||||
const entryLog = await models.EntryLog.create({
|
||||
originFk: id,
|
||||
userFk: userId,
|
||||
action: 'update',
|
||||
changedModel: 'Entry',
|
||||
changedModelId: id,
|
||||
oldInstance: oldProperties
|
||||
description: $t('Prices recalculated')
|
||||
}, myOptions);
|
||||
|
||||
if (tx) await tx.commit();
|
||||
|
|
|
@ -10,7 +10,9 @@
|
|||
</vn-item>
|
||||
<vn-item
|
||||
ng-click="$ctrl.recalcPrices()"
|
||||
translate>
|
||||
translate
|
||||
vn-acl="buyer"
|
||||
vn-acl-action="remove">
|
||||
Recalc prices
|
||||
</vn-item>
|
||||
</slot-menu>
|
||||
|
|
|
@ -93,7 +93,7 @@ class Controller extends Descriptor {
|
|||
|
||||
recalcPrices() {
|
||||
this.$http.post(`Entries/${this.id}/recalcPrices`).then(() => {
|
||||
this.vnApp.showSuccess(this.$t('Prices recalculated!'));
|
||||
this.vnApp.showSuccess(this.$t('Prices recalculated'));
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue