fix(chequebook,ctsclearing): surface global stock allocation in UI; fix decided-state check
build-run / Run Lint, Build and Deploy (push) Canceled after 0s
Publish Image in Docker Hub / build (push) Canceled after 0s
Playwright E2E Tests / Run Playwright Tests (push) Canceled after 0s
Tests / testRigor (push) Canceled after 0s

Receive Stock form now displays the actual highest-allocated serial across
every series (not just silently prefilling the field), so the operator
can see and trust the auto-suggested range start rather than taking it
on faith.

Fixes a real bug where item.decision (which InwardClearingItem.java always
sets to the literal string "PENDING" at creation, never null) was checked
with a plain truthy test everywhere a "has this been decided yet" branch
was needed. Since "PENDING" is a non-empty string, that check was always
true — silently breaking the Decide/View button label, the collapsed
validation summary, the "Awaiting settlement" text, and the decision
dialog itself (which never showed the actual Pass/Return form, even for
still-pending items). Replaced with a proper isDecided() check everywhere.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-07-23 17:08:10 +05:30
co-authored by Claude Sonnet 5
parent ca85bae4fb
commit 97d0545f07
9 changed files with 73 additions and 23 deletions
@@ -283,7 +283,7 @@
}
}
@if (item.decision) {
@if (isDecided) {
<h3 class="section-title">Decision</h3>
<div class="decided-summary" [ngClass]="pillClass(item.decision)">
<div class="decided-headline">
@@ -372,9 +372,9 @@
<div mat-dialog-actions align="end">
<button mat-raised-button type="button" mat-dialog-close>
{{ (item.decision ? 'labels.buttons.Close' : 'labels.buttons.Cancel') | translate }}
{{ (isDecided ? 'labels.buttons.Close' : 'labels.buttons.Cancel') | translate }}
</button>
@if (!item.decision) {
@if (!isDecided) {
<button
mat-raised-button
[color]="mode === 'RETURN' ? 'warn' : 'primary'"