From 7d9b34d4c5cfb29acbaae6bfb4d4e9275cc61d99 Mon Sep 17 00:00:00 2001 From: wbuezas Date: Mon, 29 Jan 2024 08:39:46 -0300 Subject: [PATCH] Latest buys WIP --- src/components/common/TableVisibleColumns.vue | 2 +- src/i18n/en/index.js | 31 ++ src/i18n/es/index.js | 31 ++ src/pages/Entry/EntryLatestBuys.vue | 303 ++++++++++++++++++ src/pages/Entry/EntryList.vue | 11 + src/pages/Entry/EntryMain.vue | 13 - src/router/modules/entry.js | 11 +- 7 files changed, 387 insertions(+), 15 deletions(-) create mode 100644 src/pages/Entry/EntryLatestBuys.vue diff --git a/src/components/common/TableVisibleColumns.vue b/src/components/common/TableVisibleColumns.vue index d9a1a2004..7aa696a07 100644 --- a/src/components/common/TableVisibleColumns.vue +++ b/src/components/common/TableVisibleColumns.vue @@ -41,7 +41,7 @@ const setUserConfigViewData = (data) => { // Importante: El name de las columnas de la tabla debe conincidir con el name de las variables que devuelve la view config formattedCols.value = $props.allColumns.map((col) => ({ name: col, - active: data[col], + active: data[col] == undefined ? true : data[col], })); emitSavedConfig(); }; diff --git a/src/i18n/en/index.js b/src/i18n/en/index.js index e9723ebb2..9c25d2b16 100644 --- a/src/i18n/en/index.js +++ b/src/i18n/en/index.js @@ -267,6 +267,7 @@ export default { notes: 'Notes', log: 'Log', create: 'Create', + latestBuys: 'Latest buys', }, list: { newEntry: 'New entry', @@ -352,6 +353,36 @@ export default { landed: 'Landed', warehouseOut: 'Warehouse Out', }, + latestBuys: { + picture: 'Picture', + itemFk: 'Item ID', + packing: 'Packing', + grouping: 'Grouping', + quantity: 'Quantity', + description: 'Description', + size: 'Size', + tags: 'Tags', + type: 'Type', + intrastat: 'Intrastat', + origin: 'Origin', + weightByPiece: 'Weight/Piece', + isActive: 'Active', + family: 'Family', + entryFk: 'Entry', + buyingValue: 'Buying value', + freightValue: 'Freight value', + comissionValue: 'Commission value', + packageValue: 'Package value', + isIgnored: 'Is ignored', + price2: 'Grouping', + price3: 'Packing', + minPrice: 'Min', + ektFk: 'Ekt', + weight: 'Weight', + packagingFk: 'Package', + packingOut: 'Package out', + landing: 'Landing', + }, }, ticket: { pageTitles: { diff --git a/src/i18n/es/index.js b/src/i18n/es/index.js index 86d56ba3e..65f555877 100644 --- a/src/i18n/es/index.js +++ b/src/i18n/es/index.js @@ -266,6 +266,7 @@ export default { notes: 'Notas', log: 'Historial', create: 'Crear', + latestBuys: 'Últimas compras', }, list: { newEntry: 'Nueva entrada', @@ -351,6 +352,36 @@ export default { landed: 'F. entrega', warehouseOut: 'Alm. salida', }, + latestBuys: { + picture: 'Foto', + itemFk: 'ID Artículo', + packing: 'Packing', + grouping: 'Grouping', + quantity: 'Cantidad', + description: 'Descripción', + size: 'Medida', + tags: 'Etiquetas', + type: 'Tipo', + intrastat: 'Intrastat', + origin: 'Origen', + weightByPiece: 'Peso (gramos)/tallo', + isActive: 'Activo', + family: 'Familia', + entryFk: 'Entrada', + buyingValue: 'Coste', + freightValue: 'Porte', + comissionValue: 'Comisión', + packageValue: 'Embalaje', + isIgnored: 'Ignorado', + price2: 'Grouping', + price3: 'Packing', + minPrice: 'Min', + ektFk: 'Ekt', + weight: 'Peso', + packagingFk: 'Embalaje', + packingOut: 'Embalaje envíos', + landing: 'Llegada', + }, }, ticket: { pageTitles: { diff --git a/src/pages/Entry/EntryLatestBuys.vue b/src/pages/Entry/EntryLatestBuys.vue new file mode 100644 index 000000000..d60723403 --- /dev/null +++ b/src/pages/Entry/EntryLatestBuys.vue @@ -0,0 +1,303 @@ + + + + + +es: + diff --git a/src/pages/Entry/EntryList.vue b/src/pages/Entry/EntryList.vue index 0cf707efa..8bbab74db 100644 --- a/src/pages/Entry/EntryList.vue +++ b/src/pages/Entry/EntryList.vue @@ -9,6 +9,7 @@ import VnLv from 'src/components/ui/VnLv.vue'; import CardList from 'src/components/ui/CardList.vue'; import EntrySummaryDialog from './Card/EntrySummaryDialog.vue'; import EntryFilter from './EntryFilter.vue'; +import VnSearchbar from 'src/components/ui/VnSearchbar.vue'; import { useStateStore } from 'stores/useStateStore'; import { toDate } from 'src/filters/index'; @@ -41,6 +42,16 @@ onMounted(async () => {