feat: add bank accounts and branches management

- Implemented bank accounts management with form and list components.
- Added bank branches management with form and list components.
- Created services for bank accounts and branches to handle API interactions.
- Updated routing to include bank accounts and branches.
- Enhanced UI with new select fields for banks and branches.
- Added necessary models and constants for bank accounts and branches.
- Improved state management for banks using a store pattern.
- Updated menu items to include links for bank accounts and branches.
This commit is contained in:
2025-12-24 21:25:13 +03:30
parent 1373cc046d
commit f671e37b14
50 changed files with 885 additions and 9 deletions
@@ -24,7 +24,8 @@ export interface IColumn<T = any> {
width?: string;
minWidth?: string;
canCopy?: boolean;
type?: 'text' | 'price' | 'boolean' | 'date';
type?: 'text' | 'price' | 'boolean' | 'date' | 'nested';
nestedPath?: string;
customDataModel?: TemplateRef<any> | ((item: T) => string | number | boolean);
}
@@ -130,6 +131,18 @@ export class PageDataListComponent<I> {
return data ? 'بله' : 'خیر';
case 'price':
return formatWithCurrency(data, false, 'ریال');
case 'nested': {
const path = column.nestedPath;
if (!path) return '-';
const nestedData = path
.split('.')
.reduce(
(obj, key) => (obj && obj[key] !== undefined ? obj[key] : null),
item[String(field)],
);
return nestedData || '-';
}
default:
break;
}