From 7f3c97a2051e69436e0851a6e1b5ca4fdc8659ae Mon Sep 17 00:00:00 2001 From: Nitesh Yadav Date: Wed, 14 Oct 2026 13:51:38 +0530 Subject: [PATCH] feat(cashier): GL withdrawal slips, GL account panel with parent GL, and Payment lock on token withdrawals Transaction Entry: - GL withdrawal slip: a GL Withdrawal Slip is always a debit. The clerk raises it as a request (GL, cash vault GL, office and currency ride on the payload), the manager approves it and the cashier pays it against its token; nothing posts directly from this screen any more (submitGlJournalEntry removed). Cashiers without an approved token are told to enter one. GL credit-only rules moved into isGlCreditOnly(), and extra rows are not allowed while a Withdrawal Slip is selected. - A/C NO. now starts the automatic account search after six characters. - Clerk: with AC. TP. = GL show a "GL Account Information" panel (code, name, type, usage, normal balance, parent GL, manual entries, status, description) instead of the empty client panels; the parent GL name is looked up from /glaccounts/{parentId} for GL only. - Cashier: once a token (withdrawal / closure request) is verified, TYPE is disabled and fixed to Payment, and onTypChange refuses to change it. Requires the backend change "GL withdrawal slips through request, approval and cashier payment". Co-Authored-By: Claude Sonnet 5.5 --- .../transaction-entry.component.html | 285 +++++++++--------- .../transaction-entry.component.ts | 230 +++++++------- 2 files changed, 261 insertions(+), 254 deletions(-) diff --git a/src/app/cashier/transaction-entry/transaction-entry.component.html b/src/app/cashier/transaction-entry/transaction-entry.component.html index 586117016..deda8f0e9 100644 --- a/src/app/cashier/transaction-entry/transaction-entry.component.html +++ b/src/app/cashier/transaction-entry/transaction-entry.component.html @@ -117,6 +117,8 @@ @@ -1627,13 +1634,7 @@ class="ws-f__ctl" [(ngModel)]="row.acTyp" (click)="$event.stopPropagation()" - (change)=" - row.acTyp === 'GL' && - row.typ !== 'Disbursement' && - row.typ !== 'Fund Transfer' && - row.typ !== 'Enter Bank Transfer' && - (row.dbCr = 'Cr') - " + (change)="isGlCreditOnly(row) && (row.dbCr = 'Cr')" > @for (a of acTypOptionsFor(row); track a) { @@ -1704,12 +1705,7 @@ type="button" class="ws-seg__btn ws-seg__btn--dr" [class.ws-seg__btn--active-dr]="row.dbCr === 'Dr'" - [disabled]=" - row.acTyp === 'GL' && - row.typ !== 'Disbursement' && - row.typ !== 'Fund Transfer' && - row.typ !== 'Enter Bank Transfer' - " + [disabled]="isGlCreditOnly(row)" (click)="$event.stopPropagation(); row.dbCr = 'Dr'" > DR @@ -1718,6 +1714,7 @@ type="button" class="ws-seg__btn ws-seg__btn--cr" [class.ws-seg__btn--active-cr]="row.dbCr === 'Cr'" + [disabled]="row.typ === 'Withdrawal Slip'" (click)="$event.stopPropagation(); row.dbCr = 'Cr'" > CR @@ -2043,7 +2040,13 @@ @if (isClerk) { -