feat(cashier,organization): denomination-aware vault UI, Bank/Branch Profile screens, popup disbursement review
Branch Day open/close now captures a denomination-wise count (carried forward automatically to the next day), and shows an auto-fetched EOD summary at close time -- vault + every cashier's position, a branch-total reconciliation against the book figure, and each cashier's reconciliation/settlement status and transaction count -- so closing the day no longer means separately checking Vault Position and every cashier's own screen by hand. New Vault Position screen (branch-ops menu) mirrors Cashier Position for the teller/vault. Cash Transfer now shows the vault's live per-denomination availability while counting a handout, with a client-side warning before it can be over-counted. New Organization screens for Bank Profile, Branch Profile and Clearing GL Configuration, wired into the Organization landing page and the previously-dead "Bank Profile" admin menu button. Cashier Transaction Entry: TYPE is now Receipt/Payment only (cash-only TXN TP.) on the cashier side, with no change to the clerk dashboard's own Withdrawal Slip/Cheque/Disbursement/Enter Bank Transfer/DD flow beyond adding a new Fund Transfer type alongside Disbursement for a GL credit that isn't a loan payout. Neither TYPE nor TXN TP. offers a blank placeholder option anymore -- a new row starts on a real default instead. Footer no longer polls the business-date config for cashier/clerk roles, who never have permission to read it. Disbursement & Transfer Requests: "Review" now opens the review screen as a popup instead of navigating to a separate route, refreshing the list on close; the review screen recognises the new Fund Transfer request type too, and its non-functional "+ Disbursement Review" tab-styled label is now a plain heading. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,163 @@
|
||||
<!--
|
||||
Copyright since 2025 Mifos Initiative
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
-->
|
||||
|
||||
<div class="bp-container">
|
||||
<div class="bp-header">
|
||||
<button mat-stroked-button [routerLink]="['/organization']" class="bp-back">
|
||||
<i class="fas fa-arrow-left"></i> Organization
|
||||
</button>
|
||||
<h2 class="bp-header__title">Branch Profile</h2>
|
||||
</div>
|
||||
|
||||
@if (errorMsg) {
|
||||
<div class="bp-alert bp-alert--error">{{ errorMsg }}</div>
|
||||
}
|
||||
@if (successMsg) {
|
||||
<div class="bp-alert bp-alert--success">{{ successMsg }}</div>
|
||||
}
|
||||
|
||||
<div class="bp-card">
|
||||
<div class="bp-section">
|
||||
<div class="bp-section__header">
|
||||
<i class="fas fa-code-branch"></i>
|
||||
<h3>Select Branch</h3>
|
||||
</div>
|
||||
<div class="bp-body">
|
||||
@if (loadingOffices) {
|
||||
<span class="bp-muted">Loading branches…</span>
|
||||
} @else {
|
||||
<mat-form-field appearance="outline" class="bp-field">
|
||||
<mat-label>Branch</mat-label>
|
||||
<mat-select [value]="selectedOfficeId" (selectionChange)="selectOffice($event.value)">
|
||||
@for (o of offices; track o.officeId) {
|
||||
<mat-option [value]="o.officeId">{{ officeLabel(o) }}</mat-option>
|
||||
}
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@if (loadingProfile) {
|
||||
<div class="bp-loading">Loading…</div>
|
||||
}
|
||||
|
||||
@if (selectedOfficeId && !loadingProfile) {
|
||||
<form [formGroup]="form" (ngSubmit)="submit()">
|
||||
<div class="bp-section">
|
||||
<div class="bp-section__header">
|
||||
<i class="fas fa-id-card"></i>
|
||||
<h3>Branch Details</h3>
|
||||
</div>
|
||||
<div class="bp-body">
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--half">
|
||||
<mat-label>Branch Code</mat-label>
|
||||
<input matInput formControlName="branchCode" placeholder="e.g. BR001" />
|
||||
</mat-form-field>
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--half">
|
||||
<mat-label>Branch Type</mat-label>
|
||||
<mat-select formControlName="branchType">
|
||||
@for (t of branchTypes; track t.value) {
|
||||
<mat-option [value]="t.value">{{ t.label }}</mat-option>
|
||||
}
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
<mat-form-field appearance="outline" class="bp-field">
|
||||
<mat-label>Address</mat-label>
|
||||
<textarea matInput formControlName="address" rows="2"></textarea>
|
||||
</mat-form-field>
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--half">
|
||||
<mat-label>Contact Phone</mat-label>
|
||||
<input matInput formControlName="contactPhone" />
|
||||
</mat-form-field>
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--half">
|
||||
<mat-label>Contact Email</mat-label>
|
||||
<input matInput type="email" formControlName="contactEmail" />
|
||||
</mat-form-field>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="bp-section">
|
||||
<div class="bp-section__header">
|
||||
<i class="fas fa-landmark"></i>
|
||||
<h3>Branch Identifiers</h3>
|
||||
</div>
|
||||
<div class="bp-body">
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--half">
|
||||
<mat-label>IFSC Code</mat-label>
|
||||
<input matInput formControlName="ifscCode" placeholder="e.g. SUCB0000123" />
|
||||
</mat-form-field>
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--half">
|
||||
<mat-label>MICR Code</mat-label>
|
||||
<input matInput formControlName="micrCode" />
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<p class="bp-note">
|
||||
SWIFT/BIC is set once for the whole bank, not per branch — see
|
||||
<a [routerLink]="['/organization/institution-profile']">Bank Profile</a>.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="bp-section">
|
||||
<div class="bp-section__header">
|
||||
<i class="fas fa-map-marked-alt"></i>
|
||||
<h3>Location (optional)</h3>
|
||||
</div>
|
||||
<div class="bp-body">
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--half">
|
||||
<mat-label>Latitude</mat-label>
|
||||
<input matInput type="number" step="0.000001" formControlName="latitude" />
|
||||
</mat-form-field>
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--half">
|
||||
<mat-label>Longitude</mat-label>
|
||||
<input matInput type="number" step="0.000001" formControlName="longitude" />
|
||||
</mat-form-field>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="bp-section">
|
||||
<div class="bp-section__header">
|
||||
<i class="fas fa-clock"></i>
|
||||
<h3>Working Hours</h3>
|
||||
</div>
|
||||
<div class="bp-body">
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--third">
|
||||
<mat-label>Opens At</mat-label>
|
||||
<input matInput type="time" formControlName="workingHoursStart" />
|
||||
</mat-form-field>
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--third">
|
||||
<mat-label>Closes At</mat-label>
|
||||
<input matInput type="time" formControlName="workingHoursEnd" />
|
||||
</mat-form-field>
|
||||
<mat-form-field appearance="outline" class="bp-field bp-field--third">
|
||||
<mat-label>Working Days</mat-label>
|
||||
<input matInput formControlName="workingDays" placeholder="e.g. Mon-Sat" />
|
||||
</mat-form-field>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@if (lastUpdated) {
|
||||
<div class="bp-lastupdated">Last updated by {{ lastUpdated.by }} · {{ lastUpdated.at | dateFormat }}</div>
|
||||
}
|
||||
|
||||
<div class="bp-actions">
|
||||
<button
|
||||
type="submit"
|
||||
mat-flat-button
|
||||
color="primary"
|
||||
[disabled]="form.pristine || saving"
|
||||
*mifosxHasPermission="'UPDATE_BRANCHPROFILE'"
|
||||
class="bp-actions__submit"
|
||||
>
|
||||
<i class="fas fa-check"></i> Save
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
Reference in New Issue
Block a user