refactor: refs #8219 modified e2e tests and fixed some translations
gitea/salix-front/pipeline/pr-dev This commit looks good
Details
gitea/salix-front/pipeline/pr-dev This commit looks good
Details
This commit is contained in:
parent
45d1cc6a5d
commit
670c089125
|
@ -83,7 +83,11 @@ const { openConfirmationModal } = useVnConfirm();
|
||||||
</template>
|
</template>
|
||||||
<template #body="{ entity }">
|
<template #body="{ entity }">
|
||||||
<VnLv :label="t('department.chat')" :value="entity.chatName" />
|
<VnLv :label="t('department.chat')" :value="entity.chatName" />
|
||||||
<VnLv :label="t('department.email')" :value="entity.notificationEmail" copy />
|
<VnLv
|
||||||
|
:label="t('globals.params.email')"
|
||||||
|
:value="entity.notificationEmail"
|
||||||
|
copy
|
||||||
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('department.selfConsumptionCustomer')"
|
:label="t('department.selfConsumptionCustomer')"
|
||||||
:value="entity.client?.name"
|
:value="entity.client?.name"
|
||||||
|
|
|
@ -58,7 +58,7 @@ onMounted(async () => {
|
||||||
dash
|
dash
|
||||||
/>
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('department.email')"
|
:label="t('globals.params.email')"
|
||||||
:value="department.notificationEmail"
|
:value="department.notificationEmail"
|
||||||
dash
|
dash
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -676,6 +676,7 @@ function setReference(data) {
|
||||||
color="primary"
|
color="primary"
|
||||||
fab
|
fab
|
||||||
icon="vn:invoice-in"
|
icon="vn:invoice-in"
|
||||||
|
data-cy="ticketListMakeInvoiceBtn"
|
||||||
/>
|
/>
|
||||||
<QTooltip>
|
<QTooltip>
|
||||||
{{ t('ticketList.createInvoice') }}
|
{{ t('ticketList.createInvoice') }}
|
||||||
|
|
|
@ -24,21 +24,24 @@ describe('InvoiceOut list', () => {
|
||||||
cy.dataCy('vnSearchBar').find('input').type('{enter}');
|
cy.dataCy('vnSearchBar').find('input').type('{enter}');
|
||||||
cy.dataCy('InvoiceOutFilterAmountBtn').find('input').type('8.88{enter}');
|
cy.dataCy('InvoiceOutFilterAmountBtn').find('input').type('8.88{enter}');
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should download a pdf', () => {
|
it('should download a pdf', () => {
|
||||||
cy.get('.bg-header > :nth-child(1) > .q-checkbox > .q-checkbox__inner').click();
|
cy.get('.bg-header > :nth-child(1) > .q-checkbox > .q-checkbox__inner').click();
|
||||||
cy.dataCy('InvoiceOutDownloadPdfBtn').click();
|
cy.dataCy('InvoiceOutDownloadPdfBtn').click();
|
||||||
cy.get('.bg-header > :nth-child(1) > .q-checkbox > .q-checkbox__inner').click();
|
cy.get('.bg-header > :nth-child(1) > .q-checkbox > .q-checkbox__inner').click();
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should give an error when manual invoicing a ticket that is already invoiced', () => {
|
it('should give an error when manual invoicing a ticket that is already invoiced', () => {
|
||||||
cy.get('[data-cy="vnTableCreateBtn"]').click();
|
cy.dataCy('vnTableCreateBtn').click();
|
||||||
cy.fillInForm(invoiceError);
|
cy.fillInForm(invoiceError);
|
||||||
cy.get('[data-cy="FormModelPopup_save"]').click();
|
cy.dataCy('FormModelPopup_save').click();
|
||||||
cy.get(notification).should('contains.text', 'This ticket is already invoiced');
|
cy.get(notification).should('contains.text', 'This ticket is already invoiced');
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should create a manual invoice and enter to its summary', () => {
|
it('should create a manual invoice and enter to its summary', () => {
|
||||||
cy.get('[data-cy="vnTableCreateBtn"]').click();
|
cy.dataCy('vnTableCreateBtn').click();
|
||||||
cy.fillInForm(invoice);
|
cy.fillInForm(invoice);
|
||||||
cy.get('[data-cy="FormModelPopup_save"]').click();
|
cy.dataCy('FormModelPopup_save').click();
|
||||||
cy.get(notification).should('contains.text', 'Data created');
|
cy.get(notification).should('contains.text', 'Data created');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -10,15 +10,11 @@ describe('InvoiceOut manual invoice', () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should create an invoice from a ticket and go to that invoice', () => {
|
it('should create an invoice from a ticket and go to that invoice', () => {
|
||||||
cy.get(
|
cy.get('[label="Customer ID"]').type('1101{enter}');
|
||||||
'[label="Customer ID"] > .q-field > .q-field__inner > .q-field__control'
|
|
||||||
).type('1101{enter}');
|
|
||||||
cy.get(
|
cy.get(
|
||||||
'[data-q-vs-anchor=""] > :nth-child(1) > .q-checkbox > .q-checkbox__inner'
|
'[data-q-vs-anchor=""] > :nth-child(1) > .q-checkbox > .q-checkbox__inner'
|
||||||
).click();
|
).click();
|
||||||
cy.get(
|
cy.dataCy('ticketListMakeInvoiceBtn').click();
|
||||||
'[style="transform: translate(-256px, 0px); margin: 80px 20px; z-index: 2;"] > div > .q-btn'
|
|
||||||
).click();
|
|
||||||
cy.get(notification).should('contains.text', 'Data saved');
|
cy.get(notification).should('contains.text', 'Data saved');
|
||||||
cy.get('.q-virtual-scroll__content > :nth-child(1) > :nth-child(3)').click();
|
cy.get('.q-virtual-scroll__content > :nth-child(1) > :nth-child(3)').click();
|
||||||
cy.get(':nth-child(8) > .value > .link').click();
|
cy.get(':nth-child(8) > .value > .link').click();
|
||||||
|
|
|
@ -17,7 +17,7 @@ describe('InvoiceOut summary', () => {
|
||||||
cy.get('#searchbar input').type('T1111111{enter}');
|
cy.get('#searchbar input').type('T1111111{enter}');
|
||||||
cy.get('[data-cy="descriptor-more-opts"] > .q-btn__content > .q-icon').click();
|
cy.get('[data-cy="descriptor-more-opts"] > .q-btn__content > .q-icon').click();
|
||||||
cy.get('.q-menu > .q-list > :nth-child(6)').click();
|
cy.get('.q-menu > .q-list > :nth-child(6)').click();
|
||||||
cy.get('[data-cy="VnConfirm_confirm"]').click();
|
cy.dartaCy('VnConfirm_confirm').click();
|
||||||
cy.get(notification).should(
|
cy.get(notification).should(
|
||||||
'contains.text',
|
'contains.text',
|
||||||
'The invoice PDF document has been regenerated'
|
'The invoice PDF document has been regenerated'
|
||||||
|
@ -39,7 +39,7 @@ describe('InvoiceOut summary', () => {
|
||||||
cy.get('#searchbar input').type('T2222222{enter}');
|
cy.get('#searchbar input').type('T2222222{enter}');
|
||||||
cy.get('[data-cy="descriptor-more-opts"] > .q-btn__content > .q-icon').click();
|
cy.get('[data-cy="descriptor-more-opts"] > .q-btn__content > .q-icon').click();
|
||||||
cy.get('.q-menu > .q-list > :nth-child(4)').click();
|
cy.get('.q-menu > .q-list > :nth-child(4)').click();
|
||||||
cy.get('[data-cy="VnConfirm_confirm"]').click();
|
cy.dartaCy('VnConfirm_confirm').click();
|
||||||
cy.get(notification).should('contains.text', 'InvoiceOut deleted');
|
cy.get(notification).should('contains.text', 'InvoiceOut deleted');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -8,13 +8,13 @@ describe('InvoiceOut global invoicing', () => {
|
||||||
|
|
||||||
it('should invoice the client tickets', () => {
|
it('should invoice the client tickets', () => {
|
||||||
cy.get('.q-mb-sm > .q-radio__inner').click();
|
cy.get('.q-mb-sm > .q-radio__inner').click();
|
||||||
cy.get('[data-cy="InvoiceOutGlobalClientSelect"]').type('1101');
|
cy.dataCy('InvoiceOutGlobalClientSelect').type('1101');
|
||||||
cy.get('.q-menu .q-item').contains('1101').click();
|
cy.get('.q-menu .q-item').contains('1101').click();
|
||||||
cy.get('[data-cy="InvoiceOutGlobalSerialSelect"]').click();
|
cy.dataCy('InvoiceOutGlobalSerialSelect').click();
|
||||||
cy.get('.q-menu .q-item').contains('global').click();
|
cy.get('.q-menu .q-item').contains('global').click();
|
||||||
cy.get('[data-cy="InvoiceOutGlobalCompanySelect"]').type('VNL');
|
cy.dataCy('InvoiceOutGlobalCompanySelect').type('VNL');
|
||||||
cy.get('.q-menu .q-item').contains('VNL').click();
|
cy.get('.q-menu .q-item').contains('VNL').click();
|
||||||
cy.get('[data-cy="InvoiceOutGlobalPrinterSelect"]').type('printer1');
|
cy.dataCy('InvoiceOutGlobalPrinterSelect').type('printer1');
|
||||||
cy.get('.q-menu .q-item').contains('printer1').click();
|
cy.get('.q-menu .q-item').contains('printer1').click();
|
||||||
cy.get(
|
cy.get(
|
||||||
'[label="Invoice date"] > .q-field > .q-field__inner > .q-field__control'
|
'[label="Invoice date"] > .q-field > .q-field__inner > .q-field__control'
|
||||||
|
@ -22,9 +22,7 @@ describe('InvoiceOut global invoicing', () => {
|
||||||
cy.get(':nth-child(5) > div > .q-btn > .q-btn__content > .block').click();
|
cy.get(':nth-child(5) > div > .q-btn > .q-btn__content > .block').click();
|
||||||
cy.get('.q-date__years-content > :nth-child(2) > .q-btn').click();
|
cy.get('.q-date__years-content > :nth-child(2) > .q-btn').click();
|
||||||
cy.get('.q-date__calendar-days > :nth-child(6) > .q-btn').click();
|
cy.get('.q-date__calendar-days > :nth-child(6) > .q-btn').click();
|
||||||
cy.get(
|
cy.get('[label="Max date ticket"]').type('01-01-2001{enter}');
|
||||||
'[label="Max date ticket"] > .q-field > .q-field__inner > .q-field__control'
|
|
||||||
).type('01-01-2001{enter}');
|
|
||||||
cy.get('.q-card').should('be.visible');
|
cy.get('.q-card').should('be.visible');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue