gemcap-be-common 1.5.30 → 1.5.33
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.
- package/microservice/events.constants.d.ts +2 -0
- package/microservice/events.constants.js +2 -0
- package/microservice/events.constants.ts +2 -0
- package/microservice/queues.constants.d.ts +3 -0
- package/microservice/queues.constants.js +4 -1
- package/microservice/queues.constants.ts +4 -1
- package/package.json +1 -1
- package/services/bank-uploaded-transactions.service.d.ts +1 -1
- package/services/bank-uploaded-transactions.service.js +1 -0
- package/services/bank-uploaded-transactions.service.ts +1 -0
- package/services/borrowers.service.d.ts +2 -2
- package/services/compliance-borrowers.service.d.ts +1 -1
- package/tsconfig.tsbuildinfo +1 -1
|
@@ -27,6 +27,7 @@ export declare const EVENT_KEYS: {
|
|
|
27
27
|
*/
|
|
28
28
|
readonly crm: {
|
|
29
29
|
readonly PROSPECT_EMAILS_SEND_REQUESTED: "crm.prospect.emails.requested";
|
|
30
|
+
readonly PROSPECT_PAYMENT_MATCHED: "crm.prospect.payment-matched";
|
|
30
31
|
};
|
|
31
32
|
/**
|
|
32
33
|
* ========= FINANCE DOMAIN EVENTS =========
|
|
@@ -35,6 +36,7 @@ export declare const EVENT_KEYS: {
|
|
|
35
36
|
readonly REPORT_PER_ACCOUNT_REQUESTED: "finance.report.account.requested";
|
|
36
37
|
readonly REPORT_CONSOLIDATED_REQUESTED: "finance.report.consolidated.requested";
|
|
37
38
|
readonly YIELD_RECALCULATION_REQUESTED: "finance.yield.recalculation.requested";
|
|
39
|
+
readonly INCOMING_PAYMENT_DETECTED: "finance.incoming-payment.detected";
|
|
38
40
|
};
|
|
39
41
|
/**
|
|
40
42
|
* ========= PORTFOLIO DOMAIN EVENTS =========
|
|
@@ -30,6 +30,7 @@ exports.EVENT_KEYS = {
|
|
|
30
30
|
*/
|
|
31
31
|
crm: {
|
|
32
32
|
PROSPECT_EMAILS_SEND_REQUESTED: 'crm.prospect.emails.requested',
|
|
33
|
+
PROSPECT_PAYMENT_MATCHED: 'crm.prospect.payment-matched',
|
|
33
34
|
},
|
|
34
35
|
/**
|
|
35
36
|
* ========= FINANCE DOMAIN EVENTS =========
|
|
@@ -38,6 +39,7 @@ exports.EVENT_KEYS = {
|
|
|
38
39
|
REPORT_PER_ACCOUNT_REQUESTED: 'finance.report.account.requested',
|
|
39
40
|
REPORT_CONSOLIDATED_REQUESTED: 'finance.report.consolidated.requested',
|
|
40
41
|
YIELD_RECALCULATION_REQUESTED: 'finance.yield.recalculation.requested',
|
|
42
|
+
INCOMING_PAYMENT_DETECTED: 'finance.incoming-payment.detected',
|
|
41
43
|
},
|
|
42
44
|
/**
|
|
43
45
|
* ========= PORTFOLIO DOMAIN EVENTS =========
|
|
@@ -30,6 +30,7 @@ export const EVENT_KEYS = {
|
|
|
30
30
|
*/
|
|
31
31
|
crm: {
|
|
32
32
|
PROSPECT_EMAILS_SEND_REQUESTED: 'crm.prospect.emails.requested',
|
|
33
|
+
PROSPECT_PAYMENT_MATCHED: 'crm.prospect.payment-matched',
|
|
33
34
|
},
|
|
34
35
|
|
|
35
36
|
/**
|
|
@@ -39,6 +40,7 @@ export const EVENT_KEYS = {
|
|
|
39
40
|
REPORT_PER_ACCOUNT_REQUESTED: 'finance.report.account.requested',
|
|
40
41
|
REPORT_CONSOLIDATED_REQUESTED: 'finance.report.consolidated.requested',
|
|
41
42
|
YIELD_RECALCULATION_REQUESTED: 'finance.yield.recalculation.requested',
|
|
43
|
+
INCOMING_PAYMENT_DETECTED: 'finance.incoming-payment.detected',
|
|
42
44
|
},
|
|
43
45
|
|
|
44
46
|
/**
|
|
@@ -34,6 +34,9 @@ export declare const QUEUES: {
|
|
|
34
34
|
readonly yield: {
|
|
35
35
|
readonly recalculation: "finance.yield.recalculation";
|
|
36
36
|
};
|
|
37
|
+
readonly incomingPayments: {
|
|
38
|
+
readonly detected: "finance.incoming-payment.detected";
|
|
39
|
+
};
|
|
37
40
|
};
|
|
38
41
|
readonly portfolio: {
|
|
39
42
|
readonly email: {
|
package/package.json
CHANGED
|
@@ -20,7 +20,7 @@ export declare class BankUploadedTransactionsService {
|
|
|
20
20
|
}>;
|
|
21
21
|
resetAllocatedBankTransactions(date: Date): Promise<void>;
|
|
22
22
|
createAllocatedBankTransactions(date: Date): Promise<void>;
|
|
23
|
-
convertBankTransactions(startDate: Date, userId: string): Promise<
|
|
23
|
+
convertBankTransactions(startDate: Date, userId: string): Promise<string[]>;
|
|
24
24
|
recalculateProducts(productIds: string[], productMap: Record<string, string>): Promise<void>;
|
|
25
25
|
preSplitBankTransactions(transactionId: string, splitTransaction: ISplitTransaction[]): Promise<void>;
|
|
26
26
|
deleteBankTransaction(transactionIds: string[]): Promise<void>;
|
|
@@ -343,6 +343,7 @@ class BankUploadedTransactionsService {
|
|
|
343
343
|
});
|
|
344
344
|
}));
|
|
345
345
|
await this.recalculateProducts(Array.from(productIds), productMap);
|
|
346
|
+
return transactions.map((transaction) => transaction._id.toString());
|
|
346
347
|
}
|
|
347
348
|
async recalculateProducts(productIds, productMap) {
|
|
348
349
|
// TODO rework in something better
|
|
@@ -381,6 +381,7 @@ export class BankUploadedTransactionsService {
|
|
|
381
381
|
});
|
|
382
382
|
}));
|
|
383
383
|
await this.recalculateProducts(Array.from(productIds), productMap);
|
|
384
|
+
return transactions.map((transaction) => transaction._id.toString())
|
|
384
385
|
}
|
|
385
386
|
|
|
386
387
|
async recalculateProducts(productIds: string[], productMap: Record<string, string>) {
|
|
@@ -84,10 +84,10 @@ export declare class BorrowerService {
|
|
|
84
84
|
getBorrowerCodesMap(): Promise<Map<string, string>>;
|
|
85
85
|
getBorrowerStatementDetails(borrowers: IBorrowerDoc[]): Promise<{
|
|
86
86
|
[x: string]: {
|
|
87
|
-
SELECTED_PERIOD?: boolean;
|
|
88
|
-
ENTIRE_LOAN?: boolean;
|
|
89
87
|
LAST_MONTH?: boolean;
|
|
90
88
|
CURRENT_MONTH?: boolean;
|
|
89
|
+
ENTIRE_LOAN?: boolean;
|
|
90
|
+
SELECTED_PERIOD?: boolean;
|
|
91
91
|
TERM_LOAN?: boolean;
|
|
92
92
|
};
|
|
93
93
|
}>;
|
|
@@ -45,7 +45,7 @@ export declare class ComplianceBorrowersService {
|
|
|
45
45
|
};
|
|
46
46
|
};
|
|
47
47
|
getFullComplianceBorrowerById(complianceBorrowerId: string): Promise<any>;
|
|
48
|
-
getAllBorrowersShortened(userAccess: IUserAccess): Promise<(Pick<IComplianceBorrowerWithBorrower, "
|
|
48
|
+
getAllBorrowersShortened(userAccess: IUserAccess): Promise<(Pick<IComplianceBorrowerWithBorrower, "items" | "borrower" | "fundingStatus"> | {
|
|
49
49
|
items: {
|
|
50
50
|
instances: any[];
|
|
51
51
|
item: import("../models/ComplianceItem.model").IComplianceItemDocument;
|