Fix cashup bugs: PDQ totals, WET placeholder, print styles, cash summary
Issue #1: Parse card machine amounts as floats in applyLoaded — pg returns DECIMAL as strings which caused JS string concatenation in totalPdq and reconciliation banked amounts. After draft save, reload cashUp to get the persisted ID so PDQ Z-report uploads work on first save. Issue #2: Guard empty gl_code in sales breakdown name-matching — an empty column code caused gName.includes('') to always be true, making placeholder columns (like WET 5%) match the first available GL group (dry dept). Issue #3: Move Cash Summary above Safe Count in sidebar nav. Extend cash-summary endpoint with per-day breakdown. Rewrite CashSummary.tsx with a daily cash takings table above the denomination summary. Issue #4: Add @media print CSS — hide sidebar nav, force colour printing, style disabled inputs as plain text, and keep tables/cards intact on paper. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
c2ab162870
commit
2f9b876d0d
5 changed files with 156 additions and 61 deletions
|
|
@ -34,3 +34,26 @@ body {
|
|||
|
||||
button { cursor: pointer; font-family: inherit; }
|
||||
input, textarea, select { font-family: inherit; }
|
||||
|
||||
@media print {
|
||||
nav { display: none !important; }
|
||||
main { overflow: visible !important; }
|
||||
body { background: white !important; }
|
||||
/* force colours/borders to render in print */
|
||||
* { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
|
||||
/* card borders visible on paper */
|
||||
[style*="border:"], [style*="border "] { border-color: #ccc !important; }
|
||||
/* hide interactive controls */
|
||||
button, input[type="file"], label[for] { display: none !important; }
|
||||
/* show disabled inputs as plain readable values */
|
||||
input:disabled, textarea:disabled {
|
||||
border: none !important;
|
||||
background: transparent !important;
|
||||
box-shadow: none !important;
|
||||
padding-left: 0 !important;
|
||||
}
|
||||
/* keep tables together */
|
||||
table { break-inside: avoid; }
|
||||
/* denomination grid — keep each row visible */
|
||||
div[style*="grid"] { break-inside: avoid; }
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue