diff --git a/src/pages/Customer/Defaulter/CustomerDefaulterFilter.vue b/src/pages/Customer/Defaulter/CustomerDefaulterFilter.vue index 6b4d8baaa..1d7f63f36 100644 --- a/src/pages/Customer/Defaulter/CustomerDefaulterFilter.vue +++ b/src/pages/Customer/Defaulter/CustomerDefaulterFilter.vue @@ -119,7 +119,7 @@ const departments = ref(); emit-value hide-selected map-options - option-label="country" + option-label="name" option-value="id" outlined rounded diff --git a/src/pages/Supplier/Card/SupplierConsumption.vue b/src/pages/Supplier/Card/SupplierConsumption.vue index dea720a61..100a38b2a 100644 --- a/src/pages/Supplier/Card/SupplierConsumption.vue +++ b/src/pages/Supplier/Card/SupplierConsumption.vue @@ -104,10 +104,14 @@ const totalEntryPrice = (rows) => { for (const row of rows) { let total = 0; let quantity = 0; - for (const buy of row.buys) { - total = total + buy.total; - quantity = quantity + buy.quantity; + + if (row.buys) { + for (const buy of row.buys) { + total = total + buy.total; + quantity = quantity + buy.quantity; + } } + row.total = total; row.quantity = quantity; totalPrice = totalPrice + total; diff --git a/test/cypress/integration/invoiceIn/invoiceInCorrective.spec.js b/test/cypress/integration/invoiceIn/invoiceInCorrective.spec.js index 376450b7d..7863d6bfa 100644 --- a/test/cypress/integration/invoiceIn/invoiceInCorrective.spec.js +++ b/test/cypress/integration/invoiceIn/invoiceInCorrective.spec.js @@ -6,15 +6,14 @@ describe('InvoiceInCorrective', () => { const saveDialog = '.q-card > .q-card__actions > .q-btn--standard '; it('should create a correcting invoice', () => { + cy.viewport(1280, 720); cy.login('developer'); cy.visit(`/#/invoice-in/1/summary?limit=10`); - cy.openLeftMenu(); cy.openActionsDescriptor(); cy.get(createRectificative).click(); cy.get(saveDialog).click(); - cy.openLeftMenu(); cy.get(rectificativeSection).click(); cy.get('tbody > tr:visible').should('have.length', 1); });