From bdbc34d4e7fb9a1a1bb9f5183cf9f7f955f7471b Mon Sep 17 00:00:00 2001 From: carlossa Date: Tue, 9 Jan 2024 14:00:51 +0100 Subject: [PATCH 1/2] refs #6325 claimRatio --- src/pages/Customer/Card/CustomerSummary.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/Customer/Card/CustomerSummary.vue b/src/pages/Customer/Card/CustomerSummary.vue index 6693274ac..4ebd6efab 100644 --- a/src/pages/Customer/Card/CustomerSummary.vue +++ b/src/pages/Customer/Card/CustomerSummary.vue @@ -38,7 +38,7 @@ const balanceDue = computed(() => { const balanceDueWarning = computed(() => (balanceDue.value ? 'negative' : '')); const claimRate = computed(() => { - return customer.value.claimsRatio.claimingRate * 100; + return customer.value.claimsRatio.claimingRate; }); const priceIncreasingRate = computed(() => { From 375154b18d06624e809dafe3a152a0af9283fca4 Mon Sep 17 00:00:00 2001 From: carlossa Date: Thu, 11 Jan 2024 10:26:15 +0100 Subject: [PATCH 2/2] refs #6325 claimingRate --- src/pages/Claim/Card/ClaimDescriptor.vue | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/src/pages/Claim/Card/ClaimDescriptor.vue b/src/pages/Claim/Card/ClaimDescriptor.vue index 85ae9f7e1..47809e9dc 100644 --- a/src/pages/Claim/Card/ClaimDescriptor.vue +++ b/src/pages/Claim/Card/ClaimDescriptor.vue @@ -2,7 +2,7 @@ import { ref, computed } from 'vue'; import { useRoute } from 'vue-router'; import { useI18n } from 'vue-i18n'; -import { toDate } from 'src/filters'; +import { toDate, toPercentage } from 'src/filters'; import { useState } from 'src/composables/useState'; import TicketDescriptorProxy from 'pages/Ticket/Card/TicketDescriptorProxy.vue'; @@ -34,7 +34,16 @@ const filter = { { relation: 'client', scope: { - include: { relation: 'salesPersonUser' }, + include: [ + { relation: 'salesPersonUser' }, + { + relation: 'claimsRatio', + scope: { + fields: ['claimingRate'], + limit: 1, + }, + }, + ], }, }, { @@ -137,6 +146,10 @@ const setData = (entity) => { :value="entity.ticket?.address?.province?.name" /> +