From 17bb144bce5087508a6f4612836b445f09390f9d Mon Sep 17 00:00:00 2001 From: pablone Date: Mon, 23 Sep 2024 10:04:45 +0200 Subject: [PATCH 1/3] fix: refs #7404 translates and some minor style fixes --- src/i18n/locale/es.yml | 1 + src/pages/Entry/EntryStockBought.vue | 108 +++++++++--------- src/pages/Entry/EntryStockBoughtDetail.vue | 23 +++- .../integration/entry/stockBought.spec.js | 2 - 4 files changed, 75 insertions(+), 59 deletions(-) diff --git a/src/i18n/locale/es.yml b/src/i18n/locale/es.yml index 53b487e9f..423775658 100644 --- a/src/i18n/locale/es.yml +++ b/src/i18n/locale/es.yml @@ -162,6 +162,7 @@ globals: dms: Gestión documental entryCreate: Nueva entrada latestBuys: Últimas compras + reserves: Reservas tickets: Tickets ticketCreate: Nuevo ticket boxing: Encajado diff --git a/src/pages/Entry/EntryStockBought.vue b/src/pages/Entry/EntryStockBought.vue index 5b4d43e06..5027ad511 100644 --- a/src/pages/Entry/EntryStockBought.vue +++ b/src/pages/Entry/EntryStockBought.vue @@ -54,7 +54,6 @@ const columns = [ create: true, component: 'number', summation: true, - cardVisible: true, }, { align: 'left', @@ -101,14 +100,9 @@ const travel = ref(null); const userParams = ref({ dated: Date.vnNew(), }); + const filter = ref({ - where: { - shipped: (userParams.value.dated - ? new Date(userParams.value.dated) - : Date.vnNew() - ).setHours(0, 0, 0, 0), - m3: { neq: null }, - }, + fields: ['id', 'm3', 'warehouseInFk'], include: [ { relation: 'warehouseIn', @@ -117,6 +111,13 @@ const filter = ref({ }, }, ], + where: { + shipped: (userParams.value.dated + ? new Date(userParams.value.dated) + : Date.vnNew() + ).setHours(0, 0, 0, 0), + m3: { neq: null }, + }, }); const setUserParams = async ({ dated }) => { @@ -139,7 +140,7 @@ function openDialog() { :filter="filter" @on-fetch=" (data) => { - travel = data.filter((data) => data.warehouseIn.code === 'VNH'); + travel = data.find((data) => data.warehouseIn.code === 'VNH'); } " /> @@ -149,10 +150,10 @@ function openDialog() { {{ t('Booked trucks') }}: - {{ travel[0]?.m3 }} + {{ travel?.m3 }} - - - - - +
+ + + + + +
- en: - Buyer: Buyer - Reserve: Reserve - Bought: Bought - More: More - Date: Date - This buyer has already made a reservation for this date: This buyer has already made a reservation for this date es: Edit travel: Editar envío Travel: Envíos diff --git a/src/pages/Entry/EntryStockBoughtDetail.vue b/src/pages/Entry/EntryStockBoughtDetail.vue index 744b9d3fe..9489c2362 100644 --- a/src/pages/Entry/EntryStockBoughtDetail.vue +++ b/src/pages/Entry/EntryStockBoughtDetail.vue @@ -22,7 +22,7 @@ const customUrl = `StockBoughts/getStockBoughtDetail?workerFk=${$props.workerFk} const columns = [ { align: 'left', - label: 'Entry', + label: t('Entry'), name: 'entryFk', isTitle: true, isId: true, @@ -41,24 +41,28 @@ const columns = [ create: true, columnClass: 'expand', columnFilter: false, + cardVisible: true, }, { align: 'left', name: 'volume', label: t('Volume'), columnFilter: false, + cardVisible: true, }, { align: 'left', label: t('Packaging'), name: 'packagingFk', columnFilter: false, + cardVisible: true, }, { align: 'left', label: 'Packing', name: 'packing', columnFilter: false, + cardVisible: true, }, ]; @@ -73,18 +77,20 @@ const columns = [ :columns="columns" :right-search="false" :disable-infinite-scroll="true" - :disable-option="{ card: true }" :limit="0" auto-load > + - es: diff --git a/src/pages/Entry/EntryStockBoughtDetail.vue b/src/pages/Entry/EntryStockBoughtDetail.vue index 9489c2362..cdcd28381 100644 --- a/src/pages/Entry/EntryStockBoughtDetail.vue +++ b/src/pages/Entry/EntryStockBoughtDetail.vue @@ -81,7 +81,13 @@ const columns = [ auto-load >