Settings: change tin notes/notes, label fix, placeholder GL columns

Change tin targets:
- Add £5/£10/£20/£50 note rows (qty in individual notes, not bags)
- Fix label: (= £40.00 @ £20.00 each) instead of (= £40.00 each)
- Add per-denomination Notes text field (stored as change_tin_notes setting)
- Table layout replaces 2-col grid for all 10 denominations

Float count form:
- Notes denominations show a single Qty input; coins keep Bags + Loose
- Change order correctly shows "notes" vs "bags" needed per denomination

Sales breakdown columns:
- Add placeholder column button (gl_code='', labelled PLACEHOLDER)
- Add delete (×) button on every column row
- Fix key={i} to support multiple placeholders with same empty gl_code

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
jtricerolph 2026-07-02 15:58:46 +00:00
parent 618992206e
commit 6c805ce5a7
4 changed files with 150 additions and 65 deletions

View file

@ -143,7 +143,8 @@ export async function initDb() {
('petty_cash_float', '200.00'),
('till_float_target', '0.00'),
('sales_breakdown_columns', '[]'),
('change_tin_breakdown', '{"50.00":0,"20.00":0,"10.00":0,"5.00":0,"2.00":20,"1.00":20,"0.50":10,"0.20":10,"0.10":5,"0.05":5}')
('change_tin_breakdown', '{"50.00":0,"20.00":0,"10.00":0,"5.00":0,"2.00":20,"1.00":20,"0.50":10,"0.20":10,"0.10":5,"0.05":5}'),
('change_tin_notes', '{}')
ON CONFLICT (key) DO NOTHING
`)
}

View file

@ -4,7 +4,7 @@ import { testConnection, fetchGlAccountsGrouped } from '../lib/newbook.js'
const ALL_KEYS = [
'default_report_days', 'petty_cash_float', 'till_float_target',
'sales_breakdown_columns', 'change_tin_breakdown',
'sales_breakdown_columns', 'change_tin_breakdown', 'change_tin_notes',
]
export async function settingsRoutes(app) {