feat: Kanban shows each order's artwork, filters quotes and searches orders and quotes
All checks were successful
Build and deploy / Validate source (push) Successful in 1m25s
Build and deploy / Integration suite on a real stack (push) Successful in 3m16s
Build and deploy / Secret scan and release gate (push) Successful in 13s
Build and deploy / Publish images (push) Successful in 1m29s
All checks were successful
Build and deploy / Validate source (push) Successful in 1m25s
Build and deploy / Integration suite on a real stack (push) Successful in 3m16s
Build and deploy / Secret scan and release gate (push) Successful in 13s
Build and deploy / Publish images (push) Successful in 1m29s
The customer's browser sends the small picture it already makes of each file (at most 300 KB, WebP/JPEG/PNG read from the bytes, own uploads only); it goes when the file's bytes go. Board cards, quote rows, the order panel and the quote detail show it, with the layout drawing as a second view and as the fallback for files without a picture. Cotações gets a customer filter (e-mail, CNPJ, WhatsApp) and product, layout and resolution-warning chips, with the page bar always shown. The board adds Entrega, Retirada and stalled-order chips. The top search now covers orders in any stage and unpaid quotes; CNPJ and phone match by digits only when nothing but digits and punctuation was typed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -357,10 +357,11 @@ function textoProgresso(x){
|
||||
return x.pct<50?'lendo o arquivo…':x.pct<70?'medindo a folha…':'conferindo a arte…';
|
||||
}
|
||||
// The file card's thumbnail (52 x 96 px, drawn at twice that for sharp screens).
|
||||
function miniatura(fonte){
|
||||
// At 480 x 720 it is the picture the Kanban shows of the order (checkout.js).
|
||||
function miniatura(fonte, maxW=104, maxH=192){
|
||||
const w=fonte.naturalWidth||fonte.width, h=fonte.naturalHeight||fonte.height;
|
||||
if(!(w>0 && h>0)) return null;
|
||||
const s=Math.min(1,104/w,192/h), cv=document.createElement('canvas');
|
||||
const s=Math.min(1,maxW/w,maxH/h), cv=document.createElement('canvas');
|
||||
cv.width=Math.max(1,Math.round(w*s)); cv.height=Math.max(1,Math.round(h*s));
|
||||
cv.getContext('2d').drawImage(fonte,0,0,cv.width,cv.height);
|
||||
return cv.toDataURL('image/webp',0.8);
|
||||
|
||||
Reference in New Issue
Block a user