From 803b8d508d7d1170059c639ae52b3a354498b15e Mon Sep 17 00:00:00 2001 From: jgallego Date: Mon, 13 Jan 2025 11:27:00 +0100 Subject: [PATCH] feat: refs #8381 add initial and final temperature fields to entry forms and summaries --- src/components/common/VnInput.vue | 1 - src/i18n/locale/en.yml | 2 ++ src/i18n/locale/es.yml | 2 ++ src/pages/Entry/Card/EntryBasicData.vue | 16 ++++++++++++++++ src/pages/Entry/Card/EntrySummary.vue | 15 ++++++++++++++- src/pages/Entry/EntryList.vue | 14 ++++++++++++++ src/pages/Travel/Card/TravelSummary.vue | 14 ++++++++++++++ 7 files changed, 62 insertions(+), 2 deletions(-) diff --git a/src/components/common/VnInput.vue b/src/components/common/VnInput.vue index 4c7445aab..99613ed92 100644 --- a/src/components/common/VnInput.vue +++ b/src/components/common/VnInput.vue @@ -45,7 +45,6 @@ const $props = defineProps({ }); const vnInputRef = ref(null); -const showPassword = ref(false); const value = computed({ get() { return $props.modelValue; diff --git a/src/i18n/locale/en.yml b/src/i18n/locale/en.yml index bf001c9ba..4a4041049 100644 --- a/src/i18n/locale/en.yml +++ b/src/i18n/locale/en.yml @@ -429,6 +429,8 @@ entry: observation: Observation booked: Booked excludedFromAvailable: Inventory + initialTemperature: Initial Temp. + finalTemperature: Final Temp. buys: observations: Observations packagingFk: Box diff --git a/src/i18n/locale/es.yml b/src/i18n/locale/es.yml index 2c95f936c..b7a6c3086 100644 --- a/src/i18n/locale/es.yml +++ b/src/i18n/locale/es.yml @@ -430,6 +430,8 @@ entry: commission: Comisión booked: Asentado excludedFromAvailable: Inventario + initialTemperature: Ini °C + finalTemperature: Fin °C buys: observations: Observaciónes packagingFk: Embalaje diff --git a/src/pages/Entry/Card/EntryBasicData.vue b/src/pages/Entry/Card/EntryBasicData.vue index 147287837..46c831349 100644 --- a/src/pages/Entry/Card/EntryBasicData.vue +++ b/src/pages/Entry/Card/EntryBasicData.vue @@ -141,6 +141,22 @@ const onFilterTravelSelected = (formData, id) => { min="0" /> + + + + { :label="t('entry.summary.invoiceNumber')" :value="entry.invoiceNumber" /> + + { :label="t('entry.summary.travelAgency')" :value="entry.travel.agency?.name" /> - + [ name: 'invoiceAmount', cardVisible: true, }, + { + align: 'left', + name: 'initialTemperature', + label: t('entry.basicData.initialTemperature'), + field: 'initialTemperature', + format: (row) => (row.initialTemperature ? `${row.initialTemperature}°` : ''), + }, + { + align: 'left', + name: 'finalTemperature', + label: t('entry.basicData.finalTemperature'), + field: 'finalTemperature', + format: (row) => (row.finalTemperature ? `${row.finalTemperature}°` : ''), + }, { label: t('entry.list.tableVisibleColumns.isExcludedFromAvailable'), name: 'isExcludedFromAvailable', diff --git a/src/pages/Travel/Card/TravelSummary.vue b/src/pages/Travel/Card/TravelSummary.vue index 59c3a8a91..62aabd761 100644 --- a/src/pages/Travel/Card/TravelSummary.vue +++ b/src/pages/Travel/Card/TravelSummary.vue @@ -96,6 +96,20 @@ const entriesTableColumns = computed(() => { showValue: true, }, { label: 'm³', field: 'm3', name: 'm3', align: 'left', showValue: true }, + { + label: t('entry.basicData.initialTemperature'), + field: 'initialTemperature', + name: 'initialTemperature', + align: 'left', + format: (val) => (val ? `${val}°` : ''), + }, + { + label: t('entry.basicData.finalTemperature'), + field: 'finalTemperature', + name: 'finalTemperature', + align: 'left', + format: (val) => (val ? `${val}°` : ''), + }, { label: '', field: 'observation',