@accounter/server
Version:
Accounter GraphQL server
23 lines (22 loc) • 1.72 kB
TypeScript
import DataLoader from 'dataloader';
import { AdminContextProvider } from '../../admin-context/providers/admin-context.provider.js';
import { TenantAwareDBClient } from '../../app-providers/tenant-db-client.js';
import type { IDeleteFinancialAccountParams, IGetAllFinancialAccountsResult, IInsertFinancialAccountsParams, IUpdateFinancialAccountParams } from '../types.js';
export declare class FinancialAccountsProvider {
private db;
private adminContextProvider;
constructor(db: TenantAwareDBClient, adminContextProvider: AdminContextProvider);
private batchFinancialAccountsByOwnerIds;
getFinancialAccountsByOwnerIdLoader: DataLoader<string, import("../types.js").IGetFinancialAccountsByOwnerIdsResult[], string>;
private batchFinancialAccountsByAccountNumbers;
getFinancialAccountByAccountNumberLoader: DataLoader<string, import("../types.js").IGetFinancialAccountsByAccountNumbersResult | undefined, string>;
private batchFinancialAccountsByAccountIDs;
getFinancialAccountByAccountIDLoader: DataLoader<string, import("../types.js").IGetFinancialAccountsByAccountIDsResult | undefined, string>;
private allFinancialAccountsCache;
getAllFinancialAccounts(): Promise<IGetAllFinancialAccountsResult[]>;
updateFinancialAccount(params: IUpdateFinancialAccountParams): Promise<import("../types.js").IUpdateFinancialAccountResult>;
deleteFinancialAccount(params: IDeleteFinancialAccountParams): Promise<import("../types.js").IDeleteFinancialAccountResult[]>;
insertFinancialAccounts(params: IInsertFinancialAccountsParams): Promise<import("../types.js").IInsertFinancialAccountsResult[]>;
invalidateById(financialAccountId: string): void;
clearCache(): void;
}