From 3a7366c91ac59e8c088bf8d5ab0414086aacb52a Mon Sep 17 00:00:00 2001 From: robert Date: Thu, 6 Feb 2025 11:47:14 +0100 Subject: [PATCH 01/12] feat: refs #6822 change traduction Partial delay --- src/pages/Entry/Card/EntryDescriptorMenu.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pages/Entry/Card/EntryDescriptorMenu.vue b/src/pages/Entry/Card/EntryDescriptorMenu.vue index 03cd53358..dc759c7a8 100644 --- a/src/pages/Entry/Card/EntryDescriptorMenu.vue +++ b/src/pages/Entry/Card/EntryDescriptorMenu.vue @@ -54,8 +54,8 @@ const transferEntry = async () => { en: transferEntryDialog: The entries will be transferred to the next day - transferEntry: Transfer Entry + transferEntry: Partial delay es: transferEntryDialog: Se van a transferir las compras al dia siguiente - transferEntry: Transferir Entrada + transferEntry: Retraso parcial From 2fea795bdb6ec24793c1f76dae4313d414fca086 Mon Sep 17 00:00:00 2001 From: alexm Date: Fri, 7 Feb 2025 07:21:59 +0100 Subject: [PATCH 02/12] fix: hotfix empty observations --- src/pages/Customer/Card/CustomerAddress.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pages/Customer/Card/CustomerAddress.vue b/src/pages/Customer/Card/CustomerAddress.vue index 5c200582d..4869182cb 100644 --- a/src/pages/Customer/Card/CustomerAddress.vue +++ b/src/pages/Customer/Card/CustomerAddress.vue @@ -189,11 +189,11 @@ const toCustomerAddressEdit = (addressId) => { -
+
Date: Fri, 7 Feb 2025 07:32:28 +0100 Subject: [PATCH 03/12] fix: hotfix fetchData not use userFilter --- src/pages/Customer/Card/CustomerAddress.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/Customer/Card/CustomerAddress.vue b/src/pages/Customer/Card/CustomerAddress.vue index 4869182cb..1b0d1dde1 100644 --- a/src/pages/Customer/Card/CustomerAddress.vue +++ b/src/pages/Customer/Card/CustomerAddress.vue @@ -117,7 +117,7 @@ const toCustomerAddressEdit = (addressId) => { data-key="CustomerAddresses" order="id DESC" ref="vnPaginateRef" - :user-filter="addressFilter" + :filter="addressFilter" :url="`Clients/${route.params.id}/addresses`" />
From 43b6ff89bef4b2f2a2b388f8e6d1ed3a2da45b92 Mon Sep 17 00:00:00 2001 From: Jon Date: Fri, 7 Feb 2025 07:56:08 +0100 Subject: [PATCH 04/12] fix: fixed company filter --- src/pages/InvoiceOut/InvoiceOutList.vue | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/pages/InvoiceOut/InvoiceOutList.vue b/src/pages/InvoiceOut/InvoiceOutList.vue index 09873642d..10b41509c 100644 --- a/src/pages/InvoiceOut/InvoiceOutList.vue +++ b/src/pages/InvoiceOut/InvoiceOutList.vue @@ -96,12 +96,19 @@ const columns = computed(() => [ }, { align: 'left', - name: 'companyCode', + name: 'companyFk', label: t('globals.company'), cardVisible: true, component: 'select', - attrs: { url: 'Companies', optionLabel: 'code', optionValue: 'id' }, - columnField: { component: null }, + attrs: { + url: 'Companies', + optionLabel: 'code', + optionValue: 'id', + }, + columnField: { + component: null, + }, + format: (row, dashIfEmpty) => dashIfEmpty(row.companyCode), }, { align: 'left', From 2a3e80746000feeb949fa0d21629be5221eb5441 Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Fri, 7 Feb 2025 13:38:06 +0000 Subject: [PATCH 05/12] fix: improve method --- src/router/index.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/router/index.js b/src/router/index.js index f0d9487c6..4403901cb 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -107,7 +107,10 @@ export default defineRouter(function (/* { store, ssrContext } */) { 'Failed to fetch dynamically imported module', 'Importing a module script failed', ]; - state.set('error', errorMessages.some(message.includes)); + state.set( + 'error', + errorMessages.some((error) => message.startsWith(error)), + ); }); return Router; }); From 9dc22b39e24a2dca1264b5793cc55ccdc1e3feac Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Fri, 7 Feb 2025 23:02:17 +0100 Subject: [PATCH 06/12] feat: add more filters --- .../Customer/Card/CustomerConsumption.vue | 92 ++++++++++++++++++- src/pages/Customer/locale/en.yml | 3 + src/pages/Customer/locale/es.yml | 3 + 3 files changed, 96 insertions(+), 2 deletions(-) diff --git a/src/pages/Customer/Card/CustomerConsumption.vue b/src/pages/Customer/Card/CustomerConsumption.vue index f0d8dea47..cf80e42eb 100644 --- a/src/pages/Customer/Card/CustomerConsumption.vue +++ b/src/pages/Customer/Card/CustomerConsumption.vue @@ -61,6 +61,60 @@ const columns = computed(() => [ columnFilter: false, cardVisible: true, }, + { + align: 'left', + name: 'buyerId', + label: t('components.itemsFilterPanel.salesPersonFk'), + component: 'select', + attrs: { + url: 'TicketRequests/getItemTypeWorker', + optionLabel: 'nickname', + optionValue: 'id', + + fields: ['id', 'nickname'], + sortBy: ['nickname ASC'], + optionFilter: 'firstName', + }, + cardVisible: false, + visible: false, + }, + // { + // align: 'left', + // name: 'typeId', + // label: t('globals.pageTitles.itemType'), + // component: 'select', + // attrs: ({ model }) => { + // return { + // url: 'ItemTypes', + // optionLabel: 'name', + // optionValue: (row) => row.category?.name, + // optionCaption: (row) => row.category?.name, + // template: ``, + // htmlContent: ``, + // include: 'category', + // fields: ['id', 'name', 'categoryFk'], + // sortBy: ['name ASC'], + // 'phone-number': model, + // }; + // }, + // attrs: { + // }, + // cardVisible: false, + // visible: false, + // }, + // { + // align: 'left', + // name: 'categoryId', + // label: t('item.list.category'), + // component: 'select', + // attrs: { + // url: 'ItemCategories', + // fields: ['id', 'name'], + // sortBy: ['name ASC'], + // }, + // cardVisible: false, + // visible: false, + // }, { name: 'description', align: 'left', @@ -119,7 +173,7 @@ const openSendEmailDialog = async () => { openConfirmationModal( t('The consumption report will be sent'), t('Please, confirm'), - () => sendCampaignMetricsEmail({ address: arrayData.store.data.email }) + () => sendCampaignMetricsEmail({ address: arrayData.store.data.email }), ); }; const sendCampaignMetricsEmail = ({ address }) => { @@ -152,7 +206,7 @@ const updateDateParams = (value, params) => { v-if="campaignList" data-key="CustomerConsumption" url="Clients/consumption" - :order="['itemTypeFk', 'itemName', 'itemSize', 'description']" + :order="['itemTypeFk', 'itemName', 'itemSize', 'description']" :filter="{ where: { clientFk: route.params.id } }" :columns="columns" search-url="consumption" @@ -204,6 +258,40 @@ const updateDateParams = (value, params) => { +en: + + valentinesDay: Valentine's Day + mothersDay: Mother's Day + allSaints: All Saints' Day es: Enter a new search: Introduce una nueva búsqueda Group by items: Agrupar por artículos + valentinesDay: Día de San Valentín + mothersDay: Día de la Madre + allSaints: Día de Todos los Santos + Campaign consumption: Consumo campaña + Campaign: Campaña + From: Desde + To: Hasta From 8c499e3fc3a4d4616ff47a47125a08dc66c08e05 Mon Sep 17 00:00:00 2001 From: Jon Date: Mon, 10 Feb 2025 10:20:40 +0100 Subject: [PATCH 09/12] fix: fixed basic data e2e --- .../invoiceIn/invoiceInBasicData.spec.js | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js b/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js index 2016fca6d..c21438093 100644 --- a/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js +++ b/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js @@ -1,23 +1,20 @@ /// describe('InvoiceInBasicData', () => { - const formInputs = '.q-form > .q-card input'; const firstFormSelect = '.q-card > .vn-row:nth-child(1) > .q-select'; - const documentBtns = '[data-cy="dms-buttons"] button'; + const documentBtns = '[data-cy="dms-buttons"]'; const dialogInputs = '.q-dialog input'; beforeEach(() => { cy.login('developer'); - cy.visit(`/#/invoice-in/1/basic-data`); + cy.visit(`/#/invoice-in/2/basic-data`); }); it('should edit the provideer and supplier ref', () => { - cy.selectOption(firstFormSelect, 'Bros'); + cy.selectOption('[data-cy="Undeductible VAT_select"]', '4751000000') cy.get('[title="Reset"]').click(); - cy.get(formInputs).eq(1).type('{selectall}4739'); + cy.selectOption(firstFormSelect, 'Bros'); cy.saveCard(); - - cy.get(`${firstFormSelect} input`).invoke('val').should('eq', 'Plants nick'); - cy.get(formInputs).eq(1).invoke('val').should('eq', '4739'); + cy.get(`${firstFormSelect} input`).invoke('val').should('eq', 'Bros nick'); }); it('should edit, remove and create the dms data', () => { @@ -25,18 +22,18 @@ describe('InvoiceInBasicData', () => { const secondInput = "I don't know what posting here!"; //edit - cy.get(documentBtns).eq(1).click(); + cy.get(`${documentBtns} > :nth-child(2)`).click(); cy.get(dialogInputs).eq(0).type(`{selectall}${firtsInput}`); cy.get('textarea').type(`{selectall}${secondInput}`); cy.get('[data-cy="FormModelPopup_save"]').click(); - cy.get(documentBtns).eq(1).click(); + cy.get(`${documentBtns} > :nth-child(2)`).click(); cy.get(dialogInputs).eq(0).invoke('val').should('eq', firtsInput); cy.get('textarea').invoke('val').should('eq', secondInput); cy.get('[data-cy="FormModelPopup_save"]').click(); cy.checkNotification('Data saved'); //remove - cy.get(documentBtns).eq(2).click(); + cy.get(`${documentBtns} > :nth-child(3)`).click(); cy.get('[data-cy="VnConfirm_confirm"]').click(); cy.checkNotification('Data saved'); From cdf600cbd0d0bf1f3793c16894f50e5c4b771c57 Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Mon, 10 Feb 2025 11:04:42 +0100 Subject: [PATCH 10/12] fix: replace i18n --- src/components/ItemsFilterPanel.vue | 2 -- src/i18n/locale/es.yml | 1 - src/pages/Customer/Card/CustomerConsumption.vue | 2 +- src/pages/Customer/locale/es.yml | 2 +- 4 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/components/ItemsFilterPanel.vue b/src/components/ItemsFilterPanel.vue index 48f607a30..b6209d8e2 100644 --- a/src/components/ItemsFilterPanel.vue +++ b/src/components/ItemsFilterPanel.vue @@ -328,7 +328,6 @@ en: active: Is active visible: Is visible floramondo: Is floramondo - salesPersonFk: Buyer categoryFk: Category es: @@ -339,7 +338,6 @@ es: active: Activo visible: Visible floramondo: Floramondo - salesPersonFk: Comprador categoryFk: Categoría Plant: Planta natural Flower: Flor fresca diff --git a/src/i18n/locale/es.yml b/src/i18n/locale/es.yml index a082ca88d..4b8aca499 100644 --- a/src/i18n/locale/es.yml +++ b/src/i18n/locale/es.yml @@ -653,7 +653,6 @@ supplier: tableVisibleColumns: nif: NIF/CIF account: Cuenta - summary: responsible: Responsable verified: Verificado diff --git a/src/pages/Customer/Card/CustomerConsumption.vue b/src/pages/Customer/Card/CustomerConsumption.vue index 14b69492b..38582384d 100644 --- a/src/pages/Customer/Card/CustomerConsumption.vue +++ b/src/pages/Customer/Card/CustomerConsumption.vue @@ -64,7 +64,7 @@ const columns = computed(() => [ { align: 'left', name: 'buyerId', - label: t('components.itemsFilterPanel.salesPersonFk'), + label: t('customer.params.buyerId'), component: 'select', attrs: { url: 'TicketRequests/getItemTypeWorker', diff --git a/src/pages/Customer/locale/es.yml b/src/pages/Customer/locale/es.yml index 1cc9ff26d..f50d049da 100644 --- a/src/pages/Customer/locale/es.yml +++ b/src/pages/Customer/locale/es.yml @@ -109,7 +109,7 @@ customer: socialName: Razón social campaign: Campaña typeId: Familia - buyerId: Familia + buyerId: Comprador categoryId: Reino city: Ciudad phone: Teléfono From aa6c6f0e690a3c86c51924a38aebe8ea08872aef Mon Sep 17 00:00:00 2001 From: Jon Date: Mon, 10 Feb 2025 12:44:35 +0100 Subject: [PATCH 11/12] refactor: requested changes --- .../InvoiceIn/Card/InvoiceInBasicData.vue | 2 ++ .../invoiceIn/invoiceInBasicData.spec.js | 19 +++++++++++-------- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue b/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue index 0cc9ac2c9..0ea5dd0ed 100644 --- a/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue +++ b/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue @@ -121,6 +121,7 @@ function deleteFile(dmsFk) { hide-selected :is-clearable="false" :required="true" + data-cy="vnSupplierSelect" />