alliance-shared-types 1.0.16 → 1.0.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -538,3 +538,65 @@ export interface CorporateEmployeeWithRole extends CorporateEmployee {
|
|
|
538
538
|
role?: CorporateRole;
|
|
539
539
|
rolePermissions?: CorporatePermission[];
|
|
540
540
|
}
|
|
541
|
+
export type WalletType = 'prepaid' | 'postpaid';
|
|
542
|
+
export type WalletStatus = 'active' | 'suspended' | 'closed';
|
|
543
|
+
export type TransactionType = 'deposit' | 'withdrawal' | 'booking_payment' | 'refund';
|
|
544
|
+
export interface CorporateWallet {
|
|
545
|
+
walletId: string;
|
|
546
|
+
corporateAccountId: string;
|
|
547
|
+
walletType: WalletType;
|
|
548
|
+
currentBalance: number;
|
|
549
|
+
creditLimit: number;
|
|
550
|
+
currency: string;
|
|
551
|
+
status: WalletStatus;
|
|
552
|
+
createdAt: string | Date;
|
|
553
|
+
updatedAt: string | Date;
|
|
554
|
+
}
|
|
555
|
+
export interface CorporateWalletWithBalance extends CorporateWallet {
|
|
556
|
+
availableBalance: number;
|
|
557
|
+
}
|
|
558
|
+
export interface CorporateWalletTransaction {
|
|
559
|
+
transactionId: string;
|
|
560
|
+
walletId: string;
|
|
561
|
+
employeeId?: string;
|
|
562
|
+
departmentId?: string;
|
|
563
|
+
transactionType: TransactionType;
|
|
564
|
+
amount: number;
|
|
565
|
+
balanceBefore: number;
|
|
566
|
+
balanceAfter: number;
|
|
567
|
+
referenceType?: string;
|
|
568
|
+
referenceId?: string;
|
|
569
|
+
description?: string;
|
|
570
|
+
metadata?: any;
|
|
571
|
+
createdAt: string | Date;
|
|
572
|
+
}
|
|
573
|
+
export interface CorporateWalletCreate {
|
|
574
|
+
corporateAccountId: string;
|
|
575
|
+
walletType: WalletType;
|
|
576
|
+
creditLimit?: number;
|
|
577
|
+
currency?: string;
|
|
578
|
+
}
|
|
579
|
+
export interface DepositRequest {
|
|
580
|
+
amount: number;
|
|
581
|
+
employeeId?: string;
|
|
582
|
+
description?: string;
|
|
583
|
+
}
|
|
584
|
+
export interface TransactionFilters {
|
|
585
|
+
employeeId?: string;
|
|
586
|
+
departmentId?: string;
|
|
587
|
+
transactionType?: TransactionType;
|
|
588
|
+
referenceType?: string;
|
|
589
|
+
startDate?: string;
|
|
590
|
+
endDate?: string;
|
|
591
|
+
limit?: number;
|
|
592
|
+
offset?: number;
|
|
593
|
+
}
|
|
594
|
+
export interface WalletSummary {
|
|
595
|
+
wallet: CorporateWallet;
|
|
596
|
+
availableBalance: number;
|
|
597
|
+
recentTransactions: CorporateWalletTransaction[];
|
|
598
|
+
}
|
|
599
|
+
export interface ExpenseReport {
|
|
600
|
+
transactions: CorporateWalletTransaction[];
|
|
601
|
+
totalExpense: number;
|
|
602
|
+
}
|