Skip to content
This repository has been archived by the owner on Mar 31, 2021. It is now read-only.

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
TheBestPessimist committed Jul 24, 2019
1 parent 498931f commit 00b9431
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions cypress/integration/a/reverse_empties_return.js
Original file line number Diff line number Diff line change
Expand Up @@ -170,12 +170,13 @@ function addLines(productNames, productQuantity) {
cy.pressBatchEntryButton();
cy.writeIntoLookupListField('M_HU_PackingMaterial_ID', productName, productName);

const qty = productQuantity + index;
if (productQuantity > 0) {
cy.writeIntoStringField('Qty', productQuantity + index); //.type('{enter}');
cy.writeIntoStringField('Qty', qty); //.type('{enter}');
cy.closeBatchEntry();
} else {
cy.writeIntoStringField('Qty', -1 * productQuantity); //.type('{enter}'); // first write the positive qty (frontend bug workaround)
writeQtyInAdvancedEdit(productQuantity + index, productName, index);
cy.writeIntoStringField('Qty', -1 * qty); //.type('{enter}'); // first write the positive qty (frontend bug workaround)
writeQtyInAdvancedEdit(qty, productName, index);
}
});
}
Expand Down

0 comments on commit 00b9431

Please sign in to comment.