feat: choose which cart items to pay, with a thumbnail of each
All checks were successful
Build and deploy / Validate source (push) Successful in 5s
Build and deploy / Integration suite on a real stack (push) Successful in 3m22s
Build and deploy / Secret scan and release gate (push) Successful in 6s
Build and deploy / Publish images (push) Successful in 1m13s
All checks were successful
Build and deploy / Validate source (push) Successful in 5s
Build and deploy / Integration suite on a real stack (push) Successful in 3m22s
Build and deploy / Secret scan and release gate (push) Successful in 6s
Build and deploy / Publish images (push) Successful in 1m13s
Each cart item has a checkbox and a thumbnail of its first file (or its extension when there is none). Only checked items are priced, quoted, uploaded and paid; an unchecked item stays in the cart, dimmed, for a later order, and stays there after the others are paid. The header count is the whole cart; the summary counts what is being paid. Also removes the "A conta nasce aqui…" and "Carrinho salvo neste navegador…" texts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -100,6 +100,12 @@ try{
|
||||
await site.fill('#fZap','11999999999');
|
||||
await site.fill('#fMail','local-browser@example.test');
|
||||
assert.equal(await site.eval('pedido[0].localFiles[0].name'),'local-test.cdr');
|
||||
// An unchecked item stays in the cart but is not paid for now.
|
||||
await site.click('[data-sel="0"]');
|
||||
assert.deepEqual(await site.eval(`({marcado:pedido[0].marcado,pagar:itensAPagar().length,zero:$('carrTot').textContent.includes('0,00'),row:document.querySelector('.item').classList.contains('fora')})`),
|
||||
{marcado:false,pagar:0,zero:true,row:true});
|
||||
await site.click('[data-sel="0"]');
|
||||
assert.equal(await site.eval('pedido[0].marcado===true && itensAPagar().length===1'),true);
|
||||
assert.equal(await site.eval('pedido[0].total'),21.89);
|
||||
assert.equal(await site.eval('document.getElementById("bPagar").disabled'),false);
|
||||
await site.click('#bPagar');
|
||||
|
||||
Reference in New Issue
Block a user