diff --git a/src/i18n/locale/en.yml b/src/i18n/locale/en.yml index 5118c16c0..76fc31a5b 100644 --- a/src/i18n/locale/en.yml +++ b/src/i18n/locale/en.yml @@ -842,6 +842,7 @@ travel: availabledHour: Availabled hour thermographs: Thermographs hb: HB + roundedCc: Rounded CC basicData: daysInForward: Automatic movement (Raid) isRaid: Raid diff --git a/src/i18n/locale/es.yml b/src/i18n/locale/es.yml index a1a173bf3..75fac881c 100644 --- a/src/i18n/locale/es.yml +++ b/src/i18n/locale/es.yml @@ -925,6 +925,7 @@ travel: availabled: F. Disponible availabledHour: Hora Disponible hb: HB + roundedCc: CC redondeado basicData: daysInForward: Desplazamiento automatico (redada) isRaid: Redada diff --git a/src/pages/Entry/EntryList.vue b/src/pages/Entry/EntryList.vue index 5ebad3144..556f89b0e 100644 --- a/src/pages/Entry/EntryList.vue +++ b/src/pages/Entry/EntryList.vue @@ -249,7 +249,6 @@ function getBadgeAttrs(row) { let timeDiff = today - timeTicket; if (timeDiff > 0) return { color: 'info', 'text-color': 'black' }; - if (timeDiff < 0) return { color: 'warning', 'text-color': 'black' }; switch (row.entryTypeCode) { case 'regularization': case 'life': @@ -274,6 +273,7 @@ function getBadgeAttrs(row) { default: break; } + if (timeDiff < 0) return { color: 'warning', 'text-color': 'black' }; return { color: 'transparent' }; } diff --git a/src/pages/Travel/Card/TravelSummary.vue b/src/pages/Travel/Card/TravelSummary.vue index 7ed3c6820..dc3f6f8c0 100644 --- a/src/pages/Travel/Card/TravelSummary.vue +++ b/src/pages/Travel/Card/TravelSummary.vue @@ -89,6 +89,13 @@ const entriesTableColumns = computed(() => { showValue: true, }, { label: 'CC', field: 'cc', name: 'cc', align: 'left', showValue: true }, + { + label: t('travel.summary.roundedCc'), + field: 'cc', + name: 'roundedCc', + align: 'left', + showValue: true, + }, { label: 'Pallet', field: 'pallet', @@ -191,14 +198,15 @@ const entriesTotals = computed(() => { freightValue: 0, packageValue: 0, cc: 0, + roundedCc: 0, pallet: 0, m3: 0, }; entriesTableRows.value.forEach((row) => { for (const key in totals) { - if (key === 'cc') { - totals[key] += Math.ceil(row[key] || 0); + if (key === 'roundedCc') { + totals['roundedCc'] += Math.ceil(row['cc'] || 0); } else { totals[key] += row[key] || 0; } @@ -210,6 +218,7 @@ const entriesTotals = computed(() => { freight: toCurrency(totals.freightValue), packageValue: toCurrency(totals.packageValue), cc: totals.cc.toFixed(2), + roundedCc: totals.roundedCc, pallet: totals.pallet.toFixed(2), m3: totals.m3.toFixed(2), }; @@ -374,6 +383,11 @@ onMounted(async () => { +