feat(cashier): add full-screen cashier teller workstation dashboard

- Add Transaction Entry screen with full account details panel
  (personal info, joint holders, nominees, KYC, balances)
- Role-based layout: CASHIER role hides nav/sidebar/ticker,
  redirects to /cashier/transaction-entry on login
- Denomination entry with opening/closing position preview
  (notes first then coins, stepper +/- round button inputs)
- Auto-fetch savings/current/FD/RD accounts with associations,
  client KYC, nominees, addresses, family members (S/D/W/H/O)
- Submit deposit/withdrawal via POST /transactions with denominationBreakdown
- Cashier position auto-loads for CASHIER role (no filter dropdowns)
- Pagination added to cash-history tabs and currency-exchange-detail
- Cashier menu simplified for cashier role permissions

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Jaanu423
2026-06-05 10:59:34 +05:30
co-authored by Claude Sonnet 4.6
parent c8e9ab8f84
commit 9094b9a0eb
18 changed files with 2828 additions and 190 deletions
@@ -0,0 +1,839 @@
/**
* 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/.
*/
:host {
display: block;
min-height: 100vh;
background: #f0f2f5;
font-family: Inter, Roboto, sans-serif;
font-size: 13px;
}
// ── Root wrapper ──────────────────────────────────────────────────────────────
.te-root {
display: flex;
flex-direction: column;
gap: 10px;
padding: 10px 14px;
}
// ── Entry Grid Card ───────────────────────────────────────────────────────────
.te-grid-wrap {
background: #fff;
border: 1px solid #e2e8f0;
border-radius: 10px;
overflow: hidden;
box-shadow: 0 1px 4px rgb(0 0 0 / 6%);
}
.te-grid {
width: 100%;
border-collapse: collapse;
font-size: 12px;
th {
background: #1e293b;
color: #94a3b8;
padding: 7px 8px;
text-align: left;
font-size: 11px;
font-weight: 700;
letter-spacing: 0.04em;
text-transform: uppercase;
border-right: 1px solid #334155;
white-space: nowrap;
&:last-child {
border-right: none;
}
}
td {
border-right: 1px solid #f1f5f9;
border-bottom: 1px solid #f1f5f9;
padding: 3px 4px;
background: #fff;
&:last-child {
border-right: none;
}
}
tr.te-row--selected td {
background: #eff6ff;
}
tr:hover td {
background: #f8fafc;
cursor: pointer;
}
&--mini th {
font-size: 10px;
padding: 5px 6px;
background: #334155;
}
}
.te-cell {
border: 1px solid #e2e8f0;
border-radius: 5px;
background: #f8fafc;
font-family: 'Roboto Mono', monospace;
font-size: 12px;
padding: 4px 7px;
color: #1e293b;
outline: none;
width: 100%;
transition:
border-color 0.15s,
background 0.15s;
&:focus {
border-color: #3b82f6;
background: #fff;
box-shadow: 0 0 0 2px rgb(59 130 246 / 15%);
}
&--xs {
width: 36px;
}
&--sm {
width: 56px;
}
&--md {
width: 88px;
}
&--lg {
width: 130px;
}
}
select.te-cell {
cursor: pointer;
}
.te-grid-footer {
display: flex;
align-items: center;
justify-content: space-between;
padding: 6px 12px;
background: #f8fafc;
border-top: 1px solid #e2e8f0;
}
.te-eff-date {
font-size: 12px;
color: #64748b;
strong {
color: #0f172a;
}
}
.te-add-btn {
width: 26px;
height: 26px;
border-radius: 50%;
background: #0ea5e9;
color: #fff;
border: none;
font-size: 18px;
font-weight: 300;
line-height: 1;
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
transition: background 0.15s;
box-shadow: 0 2px 6px rgb(14 165 233 / 35%);
&:hover {
background: #0284c7;
}
}
// ── Status messages ──────────────────────────────────────────────────────────
.te-loading {
display: flex;
align-items: center;
gap: 10px;
padding: 14px 16px;
background: #fff;
border: 1px solid #e2e8f0;
border-radius: 10px;
color: #64748b;
font-size: 13px;
&::before {
content: '';
width: 16px;
height: 16px;
border: 2px solid #e2e8f0;
border-top-color: #3b82f6;
border-radius: 50%;
animation: te-spin 0.7s linear infinite;
}
}
@keyframes te-spin {
to {
transform: rotate(360deg);
}
}
.te-error {
padding: 10px 16px;
background: #fef2f2;
border: 1px solid #fecaca;
border-radius: 8px;
color: #dc2626;
font-size: 13px;
font-weight: 500;
}
// ── Main Detail Panel ─────────────────────────────────────────────────────────
.te-detail {
display: flex;
flex-direction: column;
gap: 10px;
}
.te-detail-top {
display: grid;
grid-template-columns: 1.1fr 0.9fr 1.1fr;
gap: 10px;
@media (width <= 1100px) {
grid-template-columns: 1fr 1fr;
}
@media (width <= 700px) {
grid-template-columns: 1fr;
}
}
// ── Panel Card ────────────────────────────────────────────────────────────────
.te-panel {
background: #fff;
border: 1px solid #e2e8f0;
border-radius: 10px;
overflow: hidden;
box-shadow: 0 1px 4px rgb(0 0 0 / 5%);
&__header {
display: flex;
align-items: center;
gap: 8px;
padding: 9px 14px;
background: linear-gradient(135deg, #1e293b, #334155);
color: #e2e8f0;
font-size: 11px;
font-weight: 700;
letter-spacing: 0.06em;
text-transform: uppercase;
&--mt {
margin-top: 0;
border-top: 1px solid #e2e8f0;
background: linear-gradient(135deg, #334155, #475569);
}
}
&__body {
padding: 10px 14px;
&--center {
display: flex;
align-items: center;
justify-content: center;
min-height: 60px;
}
}
}
// ── Field rows ────────────────────────────────────────────────────────────────
.te-field {
display: flex;
align-items: flex-start;
gap: 6px;
margin-bottom: 5px;
font-size: 12px;
border-bottom: 1px dotted #f1f5f9;
padding-bottom: 4px;
&:last-child {
border-bottom: none;
margin-bottom: 0;
}
}
.te-field-row {
display: flex;
gap: 10px;
.te-field {
flex: 1;
}
}
.te-label {
min-width: 88px;
color: #64748b;
font-size: 11px;
font-weight: 600;
white-space: nowrap;
padding-top: 1px;
}
.te-value {
color: #1e293b;
font-size: 12px;
font-weight: 500;
flex: 1;
&-name {
font-weight: 700;
color: #0f172a;
font-size: 13px;
}
&-wrap {
white-space: normal;
word-break: break-word;
}
}
.te-mono {
font-family: 'Roboto Mono', 'Courier New', monospace;
}
.te-dim {
color: #94a3b8;
font-size: 11px;
}
// ── Joint holders / Nominees ──────────────────────────────────────────────────
.te-joint-row {
display: flex;
align-items: center;
gap: 8px;
padding: 6px 0;
border-bottom: 1px solid #f1f5f9;
font-size: 12px;
&:last-child {
border-bottom: none;
}
}
.te-joint-name {
flex: 1;
font-weight: 600;
color: #1e293b;
}
.te-badge {
display: inline-flex;
align-items: center;
padding: 2px 8px;
border-radius: 999px;
font-size: 10px;
font-weight: 700;
background: #f1f5f9;
color: #475569;
border: 1px solid #e2e8f0;
white-space: nowrap;
&--primary {
background: #dbeafe;
color: #1d4ed8;
border-color: #bfdbfe;
}
}
.te-mandate-badge {
display: inline-flex;
align-items: center;
padding: 2px 8px;
border-radius: 999px;
font-size: 10px;
font-weight: 700;
background: #fef3c7;
color: #92400e;
border: 1px solid #fde68a;
margin-left: 8px;
text-transform: none;
letter-spacing: 0;
}
.te-sign-badge {
display: inline-flex;
align-items: center;
padding: 2px 7px;
border-radius: 999px;
font-size: 10px;
font-weight: 700;
background: #f1f5f9;
color: #475569;
&--mandatory {
background: #fff7ed;
color: #c2410c;
border: 1px solid #fdba74;
}
&--optional {
background: #f0fdf4;
color: #15803d;
border: 1px solid #86efac;
}
}
// ── Balance rows ──────────────────────────────────────────────────────────────
.te-balance-row {
display: flex;
align-items: center;
justify-content: space-between;
padding: 5px 0;
border-bottom: 1px dotted #f1f5f9;
font-size: 12px;
&:last-child {
border-bottom: none;
}
&--total {
border-top: 1px solid #e2e8f0;
border-bottom: none;
font-weight: 700;
padding-top: 6px;
margin-top: 4px;
}
}
.te-bal-num {
width: 18px;
color: #94a3b8;
font-size: 11px;
flex-shrink: 0;
}
.te-bal-label {
flex: 1;
color: #475569;
font-size: 12px;
}
.te-bal-value {
font-weight: 700;
font-variant-numeric: tabular-nums;
text-align: right;
min-width: 100px;
color: #1e293b;
&--cr {
color: #059669;
}
&--dr {
color: #dc2626;
}
}
// ── Net Balance Bar ───────────────────────────────────────────────────────────
.te-balance-bar {
display: flex;
align-items: center;
flex-wrap: wrap;
gap: 0;
background: #fff;
border: 1px solid #e2e8f0;
border-radius: 10px;
overflow: hidden;
box-shadow: 0 1px 4px rgb(0 0 0 / 5%);
}
.te-bal-item {
display: flex;
align-items: center;
gap: 8px;
padding: 12px 20px;
border-right: 1px solid #e2e8f0;
font-size: 12px;
&:last-child {
border-right: none;
}
&__label {
color: #64748b;
font-weight: 600;
font-size: 11px;
text-transform: uppercase;
letter-spacing: 0.04em;
white-space: nowrap;
}
&__val {
font-weight: 700;
color: #1e293b;
font-variant-numeric: tabular-nums;
&--cr {
color: #059669;
}
&--big {
font-size: 18px;
}
}
}
// ── Denomination Section ──────────────────────────────────────────────────────
.te-denom-wrap {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 10px;
@media (width <= 1100px) {
grid-template-columns: 1fr 1fr;
}
@media (width <= 700px) {
grid-template-columns: 1fr;
}
}
.te-denom-table {
width: 100%;
border-collapse: collapse;
font-size: 12px;
th {
background: #f1f5f9;
color: #64748b;
font-size: 10px;
font-weight: 700;
letter-spacing: 0.05em;
text-transform: uppercase;
padding: 5px 10px;
border-bottom: 1px solid #e2e8f0;
text-align: left;
&.num {
text-align: right;
}
}
td {
padding: 5px 10px;
border-bottom: 1px solid #f8fafc;
color: #1e293b;
font-size: 12px;
&.num {
text-align: right;
font-variant-numeric: tabular-nums;
}
}
tr:last-child td {
border-bottom: none;
}
tr:hover td {
background: #f8fafc;
}
tfoot td {
background: #f1f5f9;
border-top: 2px solid #e2e8f0;
font-size: 12px;
padding: 6px 10px;
}
}
// ── Section header row inside denomination table ──────────────────────────────
.te-denom-section-row td {
padding: 4px 10px;
font-size: 10px;
font-weight: 700;
letter-spacing: 0.06em;
text-transform: uppercase;
border-top: 1px solid #e2e8f0;
&.te-denom-section-row__label {
color: #1d4ed8;
background: #eff6ff;
}
}
.te-denom-section-row--coin td.te-denom-section-row__label {
color: #92400e;
background: #fffbeb;
}
.te-denom-section-label {
font-size: 10px;
font-weight: 700;
letter-spacing: 0.06em;
text-transform: uppercase;
color: #1d4ed8;
background: #eff6ff;
border-bottom: 1px solid #dbeafe;
border-top: 1px solid #e2e8f0;
padding: 4px 10px;
&--coin {
color: #92400e;
background: #fffbeb;
border-color: #fde68a;
}
}
.te-denom-chip {
display: inline-flex;
align-items: center;
justify-content: center;
min-width: 48px;
height: 24px;
padding: 0 8px;
border-radius: 6px;
font-size: 12px;
font-weight: 700;
background: linear-gradient(135deg, #ecfeff, #cffafe);
color: #155e75;
border: 1px solid #a5f3fc;
&--coin {
border-radius: 50%;
width: 32px;
height: 32px;
min-width: 32px;
padding: 0;
background: linear-gradient(135deg, #fef9c3, #fde68a);
color: #854d0e;
border-color: #fcd34d;
}
}
.te-denom-stepper {
display: inline-flex;
align-items: center;
gap: 6px;
margin-left: auto;
button {
width: 28px;
height: 28px;
border-radius: 50%;
border: 1.5px solid #e2e8f0;
background: #f8fafc;
font-size: 16px;
font-weight: 600;
color: #475569;
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
transition: all 0.15s;
padding: 0;
line-height: 1;
&:hover:not(:disabled) {
background: #0ea5e9;
border-color: #0ea5e9;
color: #fff;
}
&:disabled {
opacity: 0.3;
cursor: not-allowed;
}
}
input {
width: 64px;
height: 32px;
border: 1.5px solid #e2e8f0;
border-radius: 8px;
text-align: center;
font-size: 14px;
font-weight: 700;
color: #1e293b;
background: #fff;
outline: none;
appearance: textfield;
transition:
border-color 0.15s,
box-shadow 0.15s;
&:focus {
border-color: #0ea5e9;
box-shadow: 0 0 0 2px rgb(14 165 233 / 15%);
}
&::-webkit-outer-spin-button,
&::-webkit-inner-spin-button {
appearance: none;
}
&::placeholder {
color: #cbd5e1;
}
}
}
.te-denom-actions {
display: flex;
gap: 8px;
margin-top: 10px;
padding-top: 10px;
border-top: 1px solid #e2e8f0;
}
.te-cr {
color: #059669 !important;
}
.te-dr {
color: #dc2626 !important;
}
.te-closing-row--neg td {
background: #fef2f2;
}
// ── Basic Info horizontal layout ─────────────────────────────────────────────
.te-basic-grid {
display: grid;
grid-template-columns: repeat(5, 1fr);
.te-balance-row {
flex-direction: column;
align-items: flex-start;
border-right: 1px solid #f1f5f9;
border-bottom: none;
padding: 10px 16px;
&:last-child {
border-right: none;
}
&--total {
border-top: none;
padding-top: 10px;
margin-top: 0;
}
.te-bal-label {
font-size: 11px;
color: #94a3b8;
margin-bottom: 4px;
}
.te-bal-value {
font-size: 15px;
min-width: unset;
}
}
@media (width <= 900px) {
grid-template-columns: repeat(3, 1fr);
}
}
// ── Action Buttons ────────────────────────────────────────────────────────────
.te-actions {
display: flex;
gap: 8px;
padding: 12px 16px;
background: #fff;
border: 1px solid #e2e8f0;
border-radius: 10px;
justify-content: flex-end;
flex-wrap: wrap;
box-shadow: 0 1px 4px rgb(0 0 0 / 5%);
}
.te-btn {
display: inline-flex;
align-items: center;
gap: 6px;
padding: 7px 18px;
border-radius: 8px;
font-size: 13px;
font-weight: 600;
font-family: inherit;
cursor: pointer;
border: 1.5px solid #e2e8f0;
background: #fff;
color: #475569;
transition: all 0.15s;
&:hover {
background: #f8fafc;
border-color: #cbd5e1;
color: #1e293b;
}
&:active {
transform: scale(0.98);
}
&--primary {
background: linear-gradient(135deg, #0ea5e9, #0284c7);
color: #fff;
border-color: transparent;
box-shadow: 0 2px 8px rgb(14 165 233 / 30%);
&:hover {
background: linear-gradient(135deg, #0284c7, #0369a1);
}
}
&--exit {
background: #fff;
color: #ef4444;
border-color: #fecaca;
&:hover {
background: #fef2f2;
}
}
&--mode {
background: linear-gradient(135deg, #8b5cf6, #7c3aed);
color: #fff;
border-color: transparent;
box-shadow: 0 2px 8px rgb(139 92 246 / 30%);
min-width: 130px;
&:hover {
background: linear-gradient(135deg, #7c3aed, #6d28d9);
}
}
}