law-common 10.18.1-beta.13 → 10.18.1-beta.15
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.
|
@@ -7,6 +7,7 @@ import { BillingInvoiceTypeEnum } from "../enums/billing_invoice_type.enum";
|
|
|
7
7
|
import { PaymentStatusEnum } from "../enums/payment_status.enum";
|
|
8
8
|
import { EntityEnum, EnumEntityType } from "../interface/entity.utils.interface";
|
|
9
9
|
import { RelationConfigs } from "../interface/relation-config.interface";
|
|
10
|
+
import { BankEntityModel } from "./bank.entity.model";
|
|
10
11
|
import { BaseEntityModel } from "./base.entity.model";
|
|
11
12
|
import { BillingReimbursementExpneseEntityModel } from "./billing-reimbursement-expense.entity.model";
|
|
12
13
|
import { ClientEntityModel } from "./client.entity.model";
|
|
@@ -55,12 +56,14 @@ export declare class BillingEntityModel extends BaseEntityModel<EntityEnum.BILLI
|
|
|
55
56
|
billOverdue?: boolean;
|
|
56
57
|
billingIdReimbursementExpense?: BillingReimbursementExpneseEntityModel[];
|
|
57
58
|
reimbursementExpense?: ReimbursementExpenseEntityModel[];
|
|
59
|
+
bank?: BankEntityModel[];
|
|
58
60
|
static relationConfigs: RelationConfigs<[
|
|
59
61
|
EntityEnum.PROJECT,
|
|
60
62
|
EntityEnum.CLIENT,
|
|
61
63
|
EntityEnum.USER,
|
|
62
64
|
EntityEnum.REIMBURSEMENT_EXPENSE,
|
|
63
|
-
EntityEnum.BILLING_REIMBURSEMENT_EXPENSE
|
|
65
|
+
EntityEnum.BILLING_REIMBURSEMENT_EXPENSE,
|
|
66
|
+
EntityEnum.BANK
|
|
64
67
|
], EnumEntityType<EntityEnum.BILLING>>;
|
|
65
68
|
static fromApiEntity(apiEntity: IBillingApiEntity): BillingEntityModel;
|
|
66
69
|
getStatusCategory(): BillingStatusCategoryEnumForUI;
|
|
@@ -225,4 +225,13 @@ BillingEntityModel.relationConfigs = [
|
|
|
225
225
|
key: "id",
|
|
226
226
|
},
|
|
227
227
|
},
|
|
228
|
+
{
|
|
229
|
+
name: entity_utils_interface_1.EntityEnum.BANK,
|
|
230
|
+
relation: relation_type_enum_1.RelationType.MANY,
|
|
231
|
+
key: "bank",
|
|
232
|
+
mapKeyConfig: {
|
|
233
|
+
relationKey: "id",
|
|
234
|
+
key: "bankId",
|
|
235
|
+
},
|
|
236
|
+
},
|
|
228
237
|
];
|
|
@@ -5,6 +5,7 @@ exports.getEntityIndexMap = getEntityIndexMap;
|
|
|
5
5
|
exports.populateRelationsFor = populateRelationsFor;
|
|
6
6
|
exports.parseEntities = parseEntities;
|
|
7
7
|
const entity_utils_interface_1 = require("../interface/entity.utils.interface");
|
|
8
|
+
const bank_entity_model_1 = require("./bank.entity.model");
|
|
8
9
|
const base_entity_model_1 = require("./base.entity.model");
|
|
9
10
|
const billing_reimbursement_expense_entity_model_1 = require("./billing-reimbursement-expense.entity.model");
|
|
10
11
|
const billing_entity_model_1 = require("./billing.entity.model");
|
|
@@ -54,6 +55,7 @@ function parseEntities(json, baseEntity, entityMap) {
|
|
|
54
55
|
[entity_utils_interface_1.EntityEnum.REIMBURSEMENT_EXPENSE]: reimbursement_expense_entity_model_1.ReimbursementExpenseEntityModel.fromApiEntity,
|
|
55
56
|
[entity_utils_interface_1.EntityEnum.BILLING_REIMBURSEMENT_EXPENSE]: billing_reimbursement_expense_entity_model_1.BillingReimbursementExpneseEntityModel.fromApiEntity,
|
|
56
57
|
[entity_utils_interface_1.EntityEnum.CLIENT_AFFILIATE]: client_affiliate_entity_model_1.ClientAffiliateEntityModel.fromApiEntity,
|
|
58
|
+
[entity_utils_interface_1.EntityEnum.BANK]: bank_entity_model_1.BankEntityModel.fromApiEntity,
|
|
57
59
|
};
|
|
58
60
|
if (!(baseEntity in entityFromJsonMappings)) {
|
|
59
61
|
throw new Error(`Unknown entity: ${baseEntity}`);
|