From 805df64bb27f6c67c562bd8837934b5f838a58a1 Mon Sep 17 00:00:00 2001 From: vicent Date: Thu, 23 Mar 2023 10:54:04 +0100 Subject: [PATCH 1/2] fallo cantidad reclamados --- .../claim/back/methods/claim-state/isEditable.js | 16 ++++++++-------- modules/claim/front/detail/index.js | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/modules/claim/back/methods/claim-state/isEditable.js b/modules/claim/back/methods/claim-state/isEditable.js index 2d0a8dc44..ad51d543a 100644 --- a/modules/claim/back/methods/claim-state/isEditable.js +++ b/modules/claim/back/methods/claim-state/isEditable.js @@ -26,13 +26,13 @@ module.exports = Self => { if (typeof options == 'object') Object.assign(myOptions, options); - - const state = await models.ClaimState.findById(id, { - include: { - relation: 'writeRole' - } - }, myOptions); - const roleWithGrants = state && state.writeRole().name; - return await models.Account.hasRole(userId, roleWithGrants, myOptions); + + const state = await models.ClaimState.findById(id, { + include: { + relation: 'writeRole' + } + }, myOptions); + const roleWithGrants = state && state.writeRole().name; + return await models.Account.hasRole(userId, roleWithGrants, myOptions); }; }; diff --git a/modules/claim/front/detail/index.js b/modules/claim/front/detail/index.js index 833519579..56f39e074 100644 --- a/modules/claim/front/detail/index.js +++ b/modules/claim/front/detail/index.js @@ -151,7 +151,7 @@ class Controller extends Section { isClaimEditable() { if (!this.claim) return; - this.$http.get(`ClaimStates/${this.claim.id}/isEditable`).then(res => { + this.$http.get(`ClaimStates/${this.claim.claimStateFk}/isEditable`).then(res => { this.isRewritable = res.data; }); } From 4762f3b54f67c272229a8b51febb9e2b9724e4ac Mon Sep 17 00:00:00 2001 From: joan Date: Thu, 23 Mar 2023 13:33:14 +0100 Subject: [PATCH 2/2] fix(deliveryNote): ticket without delivery address --- .../reports/delivery-note/delivery-note.html | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/print/templates/reports/delivery-note/delivery-note.html b/print/templates/reports/delivery-note/delivery-note.html index eb133c0cd..0be5a30f0 100644 --- a/print/templates/reports/delivery-note/delivery-note.html +++ b/print/templates/reports/delivery-note/delivery-note.html @@ -33,7 +33,7 @@
{{$t('deliveryAddress')}}
-
+

{{address.nickname}}

{{address.street}}
{{address.postalCode}}, {{address.city}} ({{address.province}})
@@ -245,13 +245,8 @@
- + \ No newline at end of file