diff --git a/e2e/helpers/extensions.js b/e2e/helpers/extensions.js index 636819860..a3c52748d 100644 --- a/e2e/helpers/extensions.js +++ b/e2e/helpers/extensions.js @@ -558,7 +558,7 @@ let actions = { }, selector); }, - closePopup: async function(selector) { + closePopup: async function() { await Promise.all([ this.keyboard.press('Escape'), this.waitFor('.vn-popup', {hidden: true}), diff --git a/e2e/helpers/selectors.js b/e2e/helpers/selectors.js index 98533b8c3..607b4b8c3 100644 --- a/e2e/helpers/selectors.js +++ b/e2e/helpers/selectors.js @@ -448,17 +448,18 @@ export default { saleButton: 'vn-left-menu a[ui-sref="ticket.card.sale"]', saleLine: 'vn-table div > vn-tbody > vn-tr', saleDescriptorPopover: '.vn-popover.shown vn-item-descriptor', - saleDescriptorPopoverSummaryButton: '.vn-popover.shown vn-item-descriptor a[ui-sref="item.card.summary({id: $ctrl.item.id})"]', + saleDescriptorPopoverSummaryButton: '.vn-popover.shown vn-item-descriptor a[ui-sref="item.card.summary({id: $ctrl.descriptor.id})"]', descriptorItemDiaryButton: '.vn-popover vn-item-descriptor vn-quick-link[icon="icon-transaction"] > a', newItemFromCatalogButton: 'vn-ticket-sale vn-float-button[icon="add"]', newItemButton: 'vn-ticket-sale vn-card vn-icon-button[icon="add_circle"]', - moreMenu: 'vn-ticket-sale vn-tool-bar > vn-button-menu[vn-id="more-button"] > div > button', + moreMenu: 'vn-ticket-sale vn-button[label="More"]', moreMenuCreateClaim: '.vn-drop-down.shown li[name="Add claim"]', moreMenuReserve: '.vn-drop-down.shown li[name="Mark as reserved"]', moreMenuUnmarkReseved: '.vn-drop-down.shown li[name="Unmark as reserved"]', moreMenuUpdateDiscount: '.vn-drop-down.shown li[name="Update discount"]', transferQuantityInput: '.vn-popover.shown vn-table > div > vn-tbody > vn-tr > vn-td-editable > span > text', transferQuantityCell: '.vn-popover.shown vn-table > div > vn-tbody > vn-tr > vn-td-editable', + firstSaleId: 'vn-ticket-sale vn-tbody > vn-tr:nth-child(1) > vn-td:nth-child(4) > span', firstSaleClaimIcon: 'vn-ticket-sale vn-table vn-tbody > vn-tr:nth-child(1) vn-icon[icon="icon-claims"]', firstSaleDescriptorImage: '.vn-popover.shown vn-item-descriptor img', firstSaleText: 'vn-table div > vn-tbody > vn-tr:nth-child(1)', @@ -468,9 +469,9 @@ export default { firstSaleQuantityCell: 'vn-ticket-sale vn-tr:nth-child(1) > vn-td-editable:nth-child(5)', firstSaleIdAutocomplete: 'vn-ticket-sale vn-table vn-tbody > vn-tr:nth-child(1) > vn-td:nth-child(4) > vn-autocomplete', firstSalePrice: 'vn-ticket-sale vn-table vn-tr:nth-child(1) > vn-td:nth-child(7) > span', - firstSalePriceInput: '.vn-popover.shown [ng-model="$ctrl.editedPrice"]', + firstSalePriceInput: '.vn-popover.shown input[ng-model="$ctrl.field"]', firstSaleDiscount: 'vn-ticket-sale vn-table vn-tr:nth-child(1) > vn-td:nth-child(8) > span', - firstSaleDiscountInput: '.vn-popover.shown [ng-model="$ctrl.newDiscount"]', + firstSaleDiscountInput: '.vn-popover.shown [ng-model="$ctrl.field"]', firstSaleImport: 'vn-ticket-sale:nth-child(1) vn-td:nth-child(9)', firstSaleReservedIcon: 'vn-ticket-sale vn-tr:nth-child(1) > vn-td:nth-child(2) > vn-icon:nth-child(3)', firstSaleColour: 'vn-ticket-sale vn-tr:nth-child(1) vn-fetched-tags section', diff --git a/e2e/paths/05-ticket/16_summary.spec.js b/e2e/paths/05-ticket/16_summary.spec.js index f6808651e..70d7592d7 100644 --- a/e2e/paths/05-ticket/16_summary.spec.js +++ b/e2e/paths/05-ticket/16_summary.spec.js @@ -58,7 +58,7 @@ describe('Ticket Summary path', () => { expect(result).toContain('000002'); }); - it(`should click on the first sale ID making the item descriptor visible`, async() => { + it(`should click on the first sale ID to make the item descriptor visible`, async() => { await page.waitToClick(selectors.ticketSummary.firstSaleItemId); await page.waitImgLoad(selectors.ticketSummary.firstSaleDescriptorImage); const visible = await page.isVisible(selectors.ticketSummary.itemDescriptorPopover); diff --git a/modules/ticket/front/sale/index.html b/modules/ticket/front/sale/index.html index 1898462fb..bf9848341 100644 --- a/modules/ticket/front/sale/index.html +++ b/modules/ticket/front/sale/index.html @@ -421,28 +421,34 @@ Send shortage SMS Recalculate price Update discount Add claim Mark as reserved Unmark as reserved