From 039a8d1d02e1ca30a2dd6701a60b7211b3de01cd Mon Sep 17 00:00:00 2001 From: carlossa Date: Thu, 12 Sep 2024 09:32:41 +0200 Subject: [PATCH] refs #7283 fix items --- src/i18n/locale/en.yml | 2 ++ src/i18n/locale/es.yml | 2 ++ src/pages/Item/Card/ItemCard.vue | 2 +- src/pages/Item/ItemList.vue | 49 ++++++++++++-------------------- src/pages/Item/ItemRequest.vue | 2 +- 5 files changed, 24 insertions(+), 33 deletions(-) diff --git a/src/i18n/locale/en.yml b/src/i18n/locale/en.yml index 6546b78c4..37d1e3726 100644 --- a/src/i18n/locale/en.yml +++ b/src/i18n/locale/en.yml @@ -1022,6 +1022,8 @@ travel: travelFileDescription: 'Travel id { travelId }' file: File item: + searchbar: + label: Search item descriptor: item: Item buyer: Buyer diff --git a/src/i18n/locale/es.yml b/src/i18n/locale/es.yml index 79e66b5f7..0c0447b78 100644 --- a/src/i18n/locale/es.yml +++ b/src/i18n/locale/es.yml @@ -1007,6 +1007,8 @@ travel: travelFileDescription: 'Id envío { travelId }' file: Fichero item: + searchbar: + label: Buscar artículo descriptor: item: Artículo buyer: Comprador diff --git a/src/pages/Item/Card/ItemCard.vue b/src/pages/Item/Card/ItemCard.vue index 1162327c1..4cf1372cc 100644 --- a/src/pages/Item/Card/ItemCard.vue +++ b/src/pages/Item/Card/ItemCard.vue @@ -12,7 +12,7 @@ import ItemListFilter from '../ItemListFilter.vue'; search-data-key="ItemList" :searchbar-props="{ url: 'Items/filter', - label: 'searchbar.labelr', + label: 'item.searchbar.label', info: 'searchbar.info', }" /> diff --git a/src/pages/Item/ItemList.vue b/src/pages/Item/ItemList.vue index 2f3d20390..c31302bba 100644 --- a/src/pages/Item/ItemList.vue +++ b/src/pages/Item/ItemList.vue @@ -44,25 +44,24 @@ const itemFilter = { ], }; const columns = computed(() => [ - // { - // label: '', - // name: 'image', - // align: 'left', - // columnField: { - // component: VnImg, - // attrs: (id) => { - // return { - // id, - // width: '50px', - // }; - // }, - // }, - // columnFilter: false, - // }, + { + label: '', + name: 'image', + align: 'left', + columnField: { + component: VnImg, + attrs: (id) => { + return { + id, + width: '50px', + }; + }, + }, + columnFilter: false, + }, { label: t('item.list.id'), name: 'id', - field: 'id', align: 'left', isId: true, chip: { @@ -71,38 +70,35 @@ const columns = computed(() => [ }, { label: t('item.list.grouping'), - field: 'grouping', name: 'grouping', align: 'left', }, { label: t('item.list.packing'), - field: 'packing', name: 'packing', align: 'left', }, { label: t('globals.description'), - field: 'name', name: 'description', align: 'left', create: true, + columnFilter: { + name: 'description', + }, }, { label: t('item.list.stems'), - field: 'stems', name: 'stems', align: 'left', }, { label: t('item.list.size'), - field: 'size', name: 'size', align: 'left', }, { label: t('item.list.typeName'), - field: 'typeName', name: 'typeName', align: 'left', component: 'select', @@ -117,7 +113,6 @@ const columns = computed(() => [ }, { label: t('item.list.category'), - field: 'category', name: 'category', align: 'left', component: 'select', @@ -131,7 +126,6 @@ const columns = computed(() => [ }, { label: t('item.list.intrastat'), - field: 'intrastat', name: 'intrastat', align: 'left', component: 'select', @@ -146,7 +140,6 @@ const columns = computed(() => [ }, { label: t('item.list.origin'), - field: 'origin', name: 'origin', align: 'left', component: 'select', @@ -161,13 +154,11 @@ const columns = computed(() => [ }, { label: t('item.list.userName'), - field: 'userName', name: 'userName', align: 'left', }, { label: t('item.list.weightByPiece'), - field: 'weightByPiece', name: 'weightByPiece', align: 'left', component: 'input', @@ -177,7 +168,6 @@ const columns = computed(() => [ }, { label: t('item.list.stemMultiplier'), - field: 'stemMultiplier', name: 'stemMultiplier', align: 'left', component: 'input', @@ -187,14 +177,12 @@ const columns = computed(() => [ }, { label: t('item.list.isActive'), - field: 'isActive', name: 'isActive', align: 'left', component: 'checkbox', }, { label: t('item.list.producer'), - field: 'producer', name: 'producer', align: 'left', component: 'select', @@ -208,7 +196,6 @@ const columns = computed(() => [ }, { label: t('item.list.landed'), - field: 'landed', name: 'landed', align: 'left', component: 'date', diff --git a/src/pages/Item/ItemRequest.vue b/src/pages/Item/ItemRequest.vue index be0a9c2e8..4bf45fe4c 100644 --- a/src/pages/Item/ItemRequest.vue +++ b/src/pages/Item/ItemRequest.vue @@ -188,7 +188,7 @@ onMounted(async () => { ref="tableRef" data-key="itemRequest" url="ticketRequests/filter" - order="shippedDate ASC, isOk ASC" + order="shipped ASC, isOk ASC" :columns="columns" :user-params="userParams" :is-editable="true"