oak-pay-business/es/utils/payClazz/index.d.ts

12 lines
736 B
TypeScript

import { EntityDict } from '../../oak-app-domain';
import { EntityDict as BaseEntityDict } from 'oak-domain/lib/types/Entity';
import PayClazz, { PayClazzConstructor } from '../../types/PayClazz';
import { BRC } from '../../types/RuntimeCxt';
import { StorageSchema } from 'oak-domain/lib/types/Storage';
export declare function getAccountEntity(entity: string): string;
export declare function registerPayClazz<ED extends EntityDict & BaseEntityDict, T extends keyof ED>(entity: T, def: {
clazzConstructor: PayClazzConstructor;
accountEntity: keyof ED;
}, schema: StorageSchema<ED>): void;
export declare function getPayClazz(entity: EntityDict['pay']['OpSchema']['entity'], entityId: string, context: BRC): Promise<PayClazz>;