ia-common 1.1.1-beta.1 → 1.1.1-beta.3
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/build/src/@enum.d.ts +3 -1
- package/build/src/@enum.js +3 -1
- package/build/src/enum/error.key.enum.d.ts +3 -0
- package/build/src/enum/error.key.enum.js +7 -0
- package/build/src/enum/relation-type.enum.d.ts +4 -0
- package/build/src/enum/relation-type.enum.js +8 -0
- package/build/src/enum/user/{user-type.enum.d.ts → user-role.enum.d.ts} +1 -1
- package/build/src/enum/user/user-role.enum.js +13 -0
- package/build/src/interface/api/advior-user-interface.d.ts +4 -0
- package/build/src/interface/api/{create-bank-details.interface.d.ts → bank-details-create-dto..interface.d.ts} +5 -2
- package/build/src/interface/api/bank-details-update.dto.interface.d.ts +24 -0
- package/build/src/interface/api/configuration-update-dto.interface.d.ts +13 -0
- package/build/src/interface/api/configurations-create-dto.interface.d.ts +3 -0
- package/build/src/interface/api/corporate-actions-create.dto.d.ts +7 -0
- package/build/src/interface/api/corporate-actions-update.dto.d.ts +19 -0
- package/build/src/interface/api/create-bulk-advice-using-csv.interface.d.ts +3 -3
- package/build/src/interface/api/create-corporate-action-advice.interface.d.ts +1 -1
- package/build/src/interface/api/create-user-dto.interface.d.ts +17 -0
- package/build/src/interface/api/create-user-dto.interface.js +8 -0
- package/build/src/interface/api/delete-bank-details-by-id.interface.d.ts +1 -5
- package/build/src/interface/api/{create-advice.interface.d.ts → equity-advice-create-dto.interface.d.ts} +4 -4
- package/build/src/interface/api/{update-advice.interface.d.ts → equity-advice-update-dto..d.ts} +3 -3
- package/build/src/interface/api/get-advice-by-id.interface.d.ts +2 -2
- package/build/src/interface/api/get-advice-by-ids-status.inteface.d.ts +2 -2
- package/build/src/interface/api/get-organization-by-id.interface.d.ts +2 -3
- package/build/src/interface/api/get-registration-by-id.interface.d.ts +5 -5
- package/build/src/interface/api/get-registration-with-organization-owners.interface.d.ts +3 -3
- package/build/src/interface/api/get-user-entities-by-advisor-id-type.interface.d.ts +1 -2
- package/build/src/interface/api/get-user-entities-by-filter.interface.d.ts +3 -0
- package/build/src/interface/api/index.d.ts +45 -55
- package/build/src/interface/api/index.js +45 -55
- package/build/src/interface/api/mutual-fund-advice-create-dto.interface.d.ts +13 -0
- package/build/src/interface/api/mutual-fund-advice-update-dto.interface.d.ts +11 -0
- package/build/src/interface/api/mutual-funds-create-dto.interface.d.ts +8 -0
- package/build/src/interface/api/nfo-advice-create-dto.interface.d.ts +13 -0
- package/build/src/interface/api/nfo-advice-update-dto.interface.d.ts +10 -0
- package/build/src/interface/api/nfo-create-dto.interface.d.ts +3 -0
- package/build/src/interface/api/organization-create-dto.interface.d.ts +5 -0
- package/build/src/interface/api/organization-update-dto.interface.d.ts +31 -0
- package/build/src/interface/api/permission.create.dto.interface.d.ts +3 -0
- package/build/src/interface/api/permission.update.dto.interface.d.ts +3 -0
- package/build/src/interface/api/{create-pricing-plan.interface.d.ts → pricing-plan-create.dto.interface.d.ts} +7 -1
- package/build/src/interface/api/pricing-plan-update-dto.interface.d.ts +22 -0
- package/build/src/interface/api/registration-create-dto.interface.d.ts +7 -0
- package/build/src/interface/api/registration-update-dto.interface.d.ts +9 -0
- package/build/src/interface/api/role-create-dto.interface.d.ts +3 -0
- package/build/src/interface/api/role-update-dto.interface.d.ts +3 -0
- package/build/src/interface/api/role.permission.mapping.create.dto.interface.d.ts +5 -0
- package/build/src/interface/api/role.permission.mapping.delete.dto.interface.d.ts +3 -0
- package/build/src/interface/api/role.permission.mapping.response.d.ts +5 -0
- package/build/src/interface/api/role.permission.mapping.update.dto.interface.d.ts +3 -0
- package/build/src/interface/api/subscription-create.dto.interface.d.ts +10 -0
- package/build/src/interface/api/subscription-update.dto.interface.d.ts +13 -0
- package/build/src/interface/api/update-corporate-action-advice.interface.d.ts +1 -1
- package/build/src/interface/api/update-user-dto.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/buy-back-corporate-actions.interface.d.ts +1 -2
- package/build/src/interface/corporate-actions/create-bonus-stock.interface.d.ts +4 -0
- package/build/src/interface/corporate-actions/delisting-corporate-actions.interface.d.ts +1 -2
- package/build/src/interface/corporate-actions/dividend-corporate-actions.interface.d.ts +1 -2
- package/build/src/interface/corporate-actions/fpo-corporate-actions.interface.d.ts +1 -2
- package/build/src/interface/corporate-actions/index.d.ts +12 -0
- package/build/src/interface/corporate-actions/index.js +12 -0
- package/build/src/interface/corporate-actions/ipo-corporate-action.interface.d.ts +1 -2
- package/build/src/interface/corporate-actions/ofs-corporate-actions.interface.d.ts +1 -2
- package/build/src/interface/corporate-actions/open-offer-corporate-actions.interface.d.ts +1 -2
- package/build/src/interface/corporate-actions/right-issues-corporate-actions.interface.d.ts +1 -2
- package/build/src/interface/corporate-actions/split-bonus-corporate-action.interface.d.ts +7 -2
- package/build/src/interface/corporate-actions/split-stock-corporate-actions.interface.d.ts +1 -2
- package/build/src/interface/corporate-actions/update-bonus-stock.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/update-buy-back.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/update-delisting.interface.d.ts +5 -0
- package/build/src/interface/corporate-actions/update-dividend.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/update-fpo.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/update-ipo.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/update-ofs.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/update-open-offer.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/update-right-issue.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/update-split-bonus.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/update-split-bonus.interface.js +2 -0
- package/build/src/interface/corporate-actions/update-split-stock.interface.d.ts +6 -0
- package/build/src/interface/corporate-actions/update-split-stock.interface.js +2 -0
- package/build/src/interface/entity/advice-entity.interface.d.ts +2 -5
- package/build/src/interface/entity/advisor-user-mapping-entity.interface.d.ts +3 -1
- package/build/src/interface/entity/bank-details-entity.interface.d.ts +5 -2
- package/build/src/interface/entity/configurations-entity.interface.d.ts +2 -2
- package/build/src/interface/entity/corporate-action-advice-entity.interface.d.ts +2 -2
- package/build/src/interface/entity/corporate-actions-entity.interface.d.ts +2 -2
- package/build/src/interface/entity/cron-job-entity.interface.d.ts +2 -1
- package/build/src/interface/entity/entity-utils.interface.d.ts +54 -8
- package/build/src/interface/entity/entity-utils.interface.js +19 -16
- package/build/src/interface/entity/index.d.ts +5 -1
- package/build/src/interface/entity/index.js +5 -1
- package/build/src/interface/entity/mutual-fund-advice-entity.interface.d.ts +5 -5
- package/build/src/interface/entity/mutual-funds-entity.interface.d.ts +11 -11
- package/build/src/interface/entity/{nfp-advice-entity.interface.d.ts → nfo-advice-entity.interface.d.ts} +3 -3
- package/build/src/interface/entity/nfo-advice-entity.interface.js +2 -0
- package/build/src/interface/entity/nfo-entity.interface.d.ts +2 -2
- package/build/src/interface/entity/organization-entity.interface.d.ts +2 -2
- package/build/src/interface/entity/permission.entity.interface.d.ts +9 -0
- package/build/src/interface/entity/permission.entity.interface.js +2 -0
- package/build/src/interface/entity/pricing-plan-entity.interface.d.ts +3 -3
- package/build/src/interface/entity/registration-entity.d.ts +2 -2
- package/build/src/interface/entity/relation-config.interface.d.ts +16 -0
- package/build/src/interface/entity/relation-config.interface.js +2 -0
- package/build/src/interface/entity/role.entity.interface.d.ts +9 -0
- package/build/src/interface/entity/role.entity.interface.js +2 -0
- package/build/src/interface/entity/role.permission.mapping.entity.interface.d.ts +8 -0
- package/build/src/interface/entity/role.permission.mapping.entity.interface.js +2 -0
- package/build/src/interface/entity/subscription-entity.interface.d.ts +2 -2
- package/build/src/interface/entity/user-entity.interface.d.ts +5 -4
- package/build/src/interface/update-user-info.interface.d.ts +4 -0
- package/build/src/model/advisor-user-mapping-entity-model.d.ts +16 -0
- package/build/src/model/advisor-user-mapping-entity-model.js +28 -0
- package/build/src/model/bank-details-entity-model.d.ts +8 -5
- package/build/src/model/bank-details-entity-model.js +51 -3
- package/build/src/model/base.entity.model.d.ts +7 -10
- package/build/src/model/base.entity.model.js +13 -16
- package/build/src/model/configurations-entity-model.d.ts +9 -6
- package/build/src/model/configurations-entity-model.js +49 -5
- package/build/src/model/corporate-actions/bonus-corporate-action-model.d.ts +2 -2
- package/build/src/model/corporate-actions/buy-back-corporate-action-model.d.ts +4 -4
- package/build/src/model/corporate-actions/corporate-action-model.d.ts +12 -6
- package/build/src/model/corporate-actions/corporate-action-model.js +78 -5
- package/build/src/model/corporate-actions/corporate-actions-advice-model.d.ts +25 -0
- package/build/src/model/corporate-actions/corporate-actions-advice-model.js +37 -0
- package/build/src/model/corporate-actions/delisting-corporate-action-model.d.ts +4 -4
- package/build/src/model/corporate-actions/dividend-corporate-action-model.d.ts +4 -4
- package/build/src/model/corporate-actions/fpo-corporate-action-model.d.ts +4 -4
- package/build/src/model/corporate-actions/ipo-corporate-action-model.d.ts +4 -4
- package/build/src/model/corporate-actions/ofs-corporate-action-model.d.ts +4 -4
- package/build/src/model/corporate-actions/open-offer-corporate-action-model.d.ts +4 -4
- package/build/src/model/corporate-actions/right-issue-corporate-action-model.d.ts +4 -4
- package/build/src/model/corporate-actions/split-bonus-corporate-action-model.d.ts +4 -4
- package/build/src/model/corporate-actions/split-corporate-action-model.d.ts +4 -4
- package/build/src/model/cron-jobs-entity-model.d.ts +23 -0
- package/build/src/model/cron-jobs-entity-model.js +34 -0
- package/build/src/model/equity-advice-entity-model.d.ts +3 -3
- package/build/src/model/equity-advice-entity-model.js +46 -46
- package/build/src/model/index.d.ts +19 -10
- package/build/src/model/index.js +19 -10
- package/build/src/model/interface/entity.model.interface.d.ts +35 -11
- package/build/src/model/interface/entity.model.interface.js +187 -14
- package/build/src/model/mutual-fund-advice-entity.model.d.ts +27 -0
- package/build/src/model/mutual-fund-advice-entity.model.js +39 -0
- package/build/src/model/mutual-funds-entity.model.d.ts +28 -0
- package/build/src/model/mutual-funds-entity.model.js +40 -0
- package/build/src/model/nfo-advice-entity.model.d.ts +22 -0
- package/build/src/model/nfo-advice-entity.model.js +34 -0
- package/build/src/model/nfo-entity.model.d.ts +21 -0
- package/build/src/model/nfo-entity.model.js +33 -0
- package/build/src/model/organization-entity-model.d.ts +34 -8
- package/build/src/model/organization-entity-model.js +223 -29
- package/build/src/model/permission-entity-model.d.ts +18 -0
- package/build/src/model/permission-entity-model.js +30 -0
- package/build/src/model/pricing-plan-entity-model.d.ts +7 -4
- package/build/src/model/pricing-plan-entity-model.js +12 -1
- package/build/src/model/pricing-plan-model.d.ts +6 -3
- package/build/src/model/pricing-plan-model.js +113 -9
- package/build/src/model/registration-entity-model.d.ts +23 -0
- package/build/src/model/registration-entity-model.js +55 -0
- package/build/src/model/role-entity-model.d.ts +15 -0
- package/build/src/model/role-entity-model.js +27 -0
- package/build/src/model/role-permission-entity-model.d.ts +15 -0
- package/build/src/model/role-permission-entity-model.js +26 -0
- package/build/src/model/subscription-entity-model.d.ts +15 -7
- package/build/src/model/subscription-entity-model.js +119 -11
- package/build/src/model/user-entity-model.d.ts +15 -9
- package/build/src/model/user-entity-model.js +109 -12
- package/build/src/utils/helper.fn.utils.d.ts +70 -0
- package/build/src/utils/helper.fn.utils.js +98 -1
- package/package.json +1 -1
- package/build/src/enum/user/user-type.enum.js +0 -13
- package/build/src/interface/api/add-mutual-funds.interface.d.ts +0 -8
- package/build/src/interface/api/create-bonus-stock.interface.d.ts +0 -6
- package/build/src/interface/api/create-buy-back-interface.d.ts +0 -6
- package/build/src/interface/api/create-client.interface.d.ts +0 -12
- package/build/src/interface/api/create-delisting.interface.d.ts +0 -6
- package/build/src/interface/api/create-dividend-interface.d.ts +0 -6
- package/build/src/interface/api/create-fpo.interface.d.ts +0 -6
- package/build/src/interface/api/create-ipo.interface.d.ts +0 -6
- package/build/src/interface/api/create-mutual-fund-advice.interface.d.ts +0 -17
- package/build/src/interface/api/create-nfo-advice.interface.d.ts +0 -13
- package/build/src/interface/api/create-nfo.interface.d.ts +0 -12
- package/build/src/interface/api/create-ofs.interface.d.ts +0 -6
- package/build/src/interface/api/create-open-offer.interface.d.ts +0 -6
- package/build/src/interface/api/create-registration.interface.d.ts +0 -9
- package/build/src/interface/api/create-right-issue.interface.d.ts +0 -6
- package/build/src/interface/api/create-split-bonus-stock.interface.d.ts +0 -6
- package/build/src/interface/api/create-split-stock.interface.d.ts +0 -6
- package/build/src/interface/api/create-staff-dto.d.ts +0 -9
- package/build/src/interface/api/create-subscription.interface.d.ts +0 -18
- package/build/src/interface/api/update-bank-details.interface.d.ts +0 -18
- package/build/src/interface/api/update-bonus-stock.interface.d.ts +0 -6
- package/build/src/interface/api/update-buy-back.interface.d.ts +0 -6
- package/build/src/interface/api/update-configuration.interface.d.ts +0 -10
- package/build/src/interface/api/update-delisting.interface.d.ts +0 -5
- package/build/src/interface/api/update-dividend.interface.d.ts +0 -6
- package/build/src/interface/api/update-fpo.interface.d.ts +0 -6
- package/build/src/interface/api/update-ipo.interface.d.ts +0 -6
- package/build/src/interface/api/update-nfo-advice.interface.d.ts +0 -14
- package/build/src/interface/api/update-ofs.interface.d.ts +0 -6
- package/build/src/interface/api/update-open-offer.interface.d.ts +0 -6
- package/build/src/interface/api/update-organization.interface.d.ts +0 -23
- package/build/src/interface/api/update-pricing-plan.interface.d.ts +0 -13
- package/build/src/interface/api/update-registration.interface.d.ts +0 -8
- package/build/src/interface/api/update-right-issue.interface.d.ts +0 -6
- package/build/src/interface/api/update-split-bonus.interface.d.ts +0 -6
- package/build/src/interface/api/update-split-stock.interface.d.ts +0 -6
- package/build/src/interface/api/update-staff.dto.d.ts +0 -9
- package/build/src/interface/api/update-subscription.interface.d.ts +0 -11
- /package/build/src/interface/api/{add-mutual-funds.interface.js → advior-user-interface.js} +0 -0
- /package/build/src/interface/api/{create-advice.interface.js → bank-details-create-dto..interface.js} +0 -0
- /package/build/src/interface/api/{create-bank-details.interface.js → bank-details-update.dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-bonus-stock.interface.js → configuration-update-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-buy-back-interface.js → configurations-create-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-client.interface.js → corporate-actions-create.dto.js} +0 -0
- /package/build/src/interface/api/{create-delisting.interface.js → corporate-actions-update.dto.js} +0 -0
- /package/build/src/interface/api/{create-dividend-interface.js → equity-advice-create-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-fpo.interface.js → equity-advice-update-dto..js} +0 -0
- /package/build/src/interface/api/{create-ipo.interface.js → get-user-entities-by-filter.interface.js} +0 -0
- /package/build/src/interface/api/{create-mutual-fund-advice.interface.js → mutual-fund-advice-create-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-nfo-advice.interface.js → mutual-fund-advice-update-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-nfo.interface.js → mutual-funds-create-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-ofs.interface.js → nfo-advice-create-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-open-offer.interface.js → nfo-advice-update-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-pricing-plan.interface.js → nfo-create-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-registration.interface.js → organization-create-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-right-issue.interface.js → organization-update-dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-split-bonus-stock.interface.js → permission.create.dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-split-stock.interface.js → permission.update.dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-staff-dto.js → pricing-plan-create.dto.interface.js} +0 -0
- /package/build/src/interface/api/{create-subscription.interface.js → pricing-plan-update-dto.interface.js} +0 -0
- /package/build/src/interface/api/{update-advice.interface.js → registration-create-dto.interface.js} +0 -0
- /package/build/src/interface/api/{update-bank-details.interface.js → registration-update-dto.interface.js} +0 -0
- /package/build/src/interface/api/{update-bonus-stock.interface.js → role-create-dto.interface.js} +0 -0
- /package/build/src/interface/api/{update-buy-back.interface.js → role-update-dto.interface.js} +0 -0
- /package/build/src/interface/api/{update-configuration.interface.js → role.permission.mapping.create.dto.interface.js} +0 -0
- /package/build/src/interface/api/{update-delisting.interface.js → role.permission.mapping.delete.dto.interface.js} +0 -0
- /package/build/src/interface/api/{update-dividend.interface.js → role.permission.mapping.response.js} +0 -0
- /package/build/src/interface/api/{update-fpo.interface.js → role.permission.mapping.update.dto.interface.js} +0 -0
- /package/build/src/interface/api/{update-ipo.interface.js → subscription-create.dto.interface.js} +0 -0
- /package/build/src/interface/api/{update-nfo-advice.interface.js → subscription-update.dto.interface.js} +0 -0
- /package/build/src/interface/api/{update-ofs.interface.js → update-user-dto.interface.js} +0 -0
- /package/build/src/interface/{api/update-open-offer.interface.js → corporate-actions/create-bonus-stock.interface.js} +0 -0
- /package/build/src/interface/{api/update-organization.interface.js → corporate-actions/update-bonus-stock.interface.js} +0 -0
- /package/build/src/interface/{api/update-pricing-plan.interface.js → corporate-actions/update-buy-back.interface.js} +0 -0
- /package/build/src/interface/{api/update-registration.interface.js → corporate-actions/update-delisting.interface.js} +0 -0
- /package/build/src/interface/{api/update-right-issue.interface.js → corporate-actions/update-dividend.interface.js} +0 -0
- /package/build/src/interface/{api/update-split-bonus.interface.js → corporate-actions/update-fpo.interface.js} +0 -0
- /package/build/src/interface/{api/update-split-stock.interface.js → corporate-actions/update-ipo.interface.js} +0 -0
- /package/build/src/interface/{api/update-staff.dto.js → corporate-actions/update-ofs.interface.js} +0 -0
- /package/build/src/interface/{api/update-subscription.interface.js → corporate-actions/update-open-offer.interface.js} +0 -0
- /package/build/src/interface/{entity/nfp-advice-entity.interface.js → corporate-actions/update-right-issue.interface.js} +0 -0
|
@@ -1,24 +1,21 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.BaseEntityModel =
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
RelationType["ONE"] = "one";
|
|
7
|
-
RelationType["MANY"] = "many";
|
|
8
|
-
})(RelationType || (exports.RelationType = RelationType = {}));
|
|
3
|
+
exports.BaseEntityModel = void 0;
|
|
4
|
+
// @ts-nocheck
|
|
5
|
+
const _enum_1 = require("../@enum");
|
|
9
6
|
class BaseEntityModel {
|
|
10
7
|
constructor(entityName) {
|
|
11
8
|
this.entityName = entityName;
|
|
12
9
|
}
|
|
13
|
-
populateRelationsByIndex(
|
|
10
|
+
populateRelationsByIndex(entityModelIndexMap) {
|
|
14
11
|
for (const relationConfig of this.getRelationConfigs() || []) {
|
|
15
12
|
const thisMappingKey = relationConfig.mapKeyConfig.key;
|
|
16
13
|
const relatedMappingKey = relationConfig.mapKeyConfig.relationKey;
|
|
17
14
|
const thisKey = relationConfig.key;
|
|
18
15
|
// console.log('Populating relation for', relationConfig.name, 'on', this.entityName, relationConfig);
|
|
19
16
|
// debugger;
|
|
20
|
-
if (relationConfig.relation === RelationType.ONE) {
|
|
21
|
-
const relatedEntities =
|
|
17
|
+
if (relationConfig.relation === _enum_1.RelationType.ONE) {
|
|
18
|
+
const relatedEntities = entityModelIndexMap[relationConfig.name] || {};
|
|
22
19
|
if (Object.is(relatedEntities, null))
|
|
23
20
|
continue;
|
|
24
21
|
let foundRelatedEntities = [];
|
|
@@ -56,9 +53,9 @@ class BaseEntityModel {
|
|
|
56
53
|
}
|
|
57
54
|
this[thisKey] = foundRelatedEntities[0];
|
|
58
55
|
}
|
|
59
|
-
else if (relationConfig.relation === RelationType.MANY) {
|
|
56
|
+
else if (relationConfig.relation === _enum_1.RelationType.MANY) {
|
|
60
57
|
this[thisKey] = [];
|
|
61
|
-
const relatedEntities =
|
|
58
|
+
const relatedEntities = entityModelIndexMap[relationConfig.name] || {};
|
|
62
59
|
for (const relatedEntity of Object.values(relatedEntities)) {
|
|
63
60
|
if (relatedEntity[relatedMappingKey] === this[thisMappingKey]) {
|
|
64
61
|
this[thisKey].push(relatedEntity);
|
|
@@ -67,13 +64,13 @@ class BaseEntityModel {
|
|
|
67
64
|
}
|
|
68
65
|
}
|
|
69
66
|
}
|
|
70
|
-
static populateRelationsForEntities(
|
|
71
|
-
for (const key of Object.keys(
|
|
72
|
-
const entity =
|
|
73
|
-
entity.populateRelationsByIndex(
|
|
67
|
+
static populateRelationsForEntities(entityModelIndexMap, entityType) {
|
|
68
|
+
for (const key of Object.keys(entityModelIndexMap[entityType] || {})) {
|
|
69
|
+
const entity = entityModelIndexMap[entityType][key];
|
|
70
|
+
entity.populateRelationsByIndex(entityModelIndexMap);
|
|
74
71
|
}
|
|
75
72
|
}
|
|
76
|
-
populateRelations(
|
|
73
|
+
populateRelations(entityModelIndexMap) {
|
|
77
74
|
this.populateRelationsByIndex(entityIndexMap);
|
|
78
75
|
}
|
|
79
76
|
overwrite(entityIndexMap, indexKey = "id") {
|
|
@@ -1,16 +1,19 @@
|
|
|
1
|
-
import { IConfigurationsEntity } from "../@type";
|
|
1
|
+
import { EntityEnum, IConfigurationsEntity } from "../@type";
|
|
2
2
|
import { Configuration } from "../enum/configuration.enum";
|
|
3
|
-
|
|
3
|
+
import { BaseEntityModel } from "./base.entity.model";
|
|
4
|
+
export declare class ConfigurationsEntityModel extends BaseEntityModel<EntityEnum.CONFIGURATION> implements IConfigurationsEntity {
|
|
4
5
|
id: number;
|
|
5
6
|
key: Configuration;
|
|
6
7
|
value: string;
|
|
7
8
|
description: string;
|
|
8
|
-
|
|
9
|
-
|
|
9
|
+
text: string;
|
|
10
|
+
createdOn: number;
|
|
11
|
+
updatedOn: number;
|
|
10
12
|
createdBy: number;
|
|
11
13
|
updatedBy: number;
|
|
12
|
-
|
|
13
|
-
|
|
14
|
+
constructor();
|
|
15
|
+
static fromEntity(entity: IConfigurationsEntity): ConfigurationsEntityModel;
|
|
14
16
|
isCronJobKey(): boolean;
|
|
15
17
|
static findByKey(configurationEntities: IConfigurationsEntity[], key: Configuration): IConfigurationsEntity | undefined;
|
|
18
|
+
getRelationConfigs(): any;
|
|
16
19
|
}
|
|
@@ -1,10 +1,26 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.ConfigurationsEntityModel = void 0;
|
|
4
|
+
const _type_1 = require("../@type");
|
|
4
5
|
const configuration_enum_1 = require("../enum/configuration.enum");
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
const base_entity_model_1 = require("./base.entity.model");
|
|
7
|
+
class ConfigurationsEntityModel extends base_entity_model_1.BaseEntityModel {
|
|
8
|
+
constructor() {
|
|
9
|
+
super(_type_1.EntityEnum.CONFIGURATION);
|
|
10
|
+
this.id = 0;
|
|
11
|
+
this.key = "";
|
|
12
|
+
this.value = "";
|
|
13
|
+
this.description = "";
|
|
14
|
+
this.text = "";
|
|
15
|
+
this.createdOn = 0;
|
|
16
|
+
this.updatedOn = 0;
|
|
17
|
+
this.createdBy = 0;
|
|
18
|
+
this.updatedBy = 0;
|
|
19
|
+
}
|
|
20
|
+
static fromEntity(entity) {
|
|
21
|
+
const result = new ConfigurationsEntityModel();
|
|
22
|
+
Object.assign(result, entity);
|
|
23
|
+
return result;
|
|
8
24
|
}
|
|
9
25
|
isCronJobKey() {
|
|
10
26
|
return configuration_enum_1.Configuration.CronJobsConfigurationsKeys(this.key);
|
|
@@ -12,5 +28,33 @@ class ConfigurationsModel {
|
|
|
12
28
|
static findByKey(configurationEntities, key) {
|
|
13
29
|
return configurationEntities.find((configurationEntity) => configurationEntity.key === key);
|
|
14
30
|
}
|
|
31
|
+
getRelationConfigs() {
|
|
32
|
+
return this.constructor.prototype.constructor.relationConfigs;
|
|
33
|
+
}
|
|
15
34
|
}
|
|
16
|
-
exports.
|
|
35
|
+
exports.ConfigurationsEntityModel = ConfigurationsEntityModel;
|
|
36
|
+
// export class ConfigurationsModel implements IConfigurationsEntity {
|
|
37
|
+
// id: number;
|
|
38
|
+
// key: Configuration;
|
|
39
|
+
// value: string;
|
|
40
|
+
// description: string;
|
|
41
|
+
// createdOn: number;
|
|
42
|
+
// updatedOn: number;
|
|
43
|
+
// createdBy: number;
|
|
44
|
+
// updatedBy: number;
|
|
45
|
+
// text: string;
|
|
46
|
+
// constructor(data: IConfigurationsEntity) {
|
|
47
|
+
// Object.assign(this, data);
|
|
48
|
+
// }
|
|
49
|
+
// isCronJobKey(): boolean {
|
|
50
|
+
// return Configuration.CronJobsConfigurationsKeys(this.key);
|
|
51
|
+
// }
|
|
52
|
+
// static findByKey(
|
|
53
|
+
// configurationEntities: IConfigurationsEntity[],
|
|
54
|
+
// key: Configuration
|
|
55
|
+
// ): IConfigurationsEntity | undefined {
|
|
56
|
+
// return configurationEntities.find(
|
|
57
|
+
// (configurationEntity) => configurationEntity.key === key
|
|
58
|
+
// );
|
|
59
|
+
// }
|
|
60
|
+
// }
|
|
@@ -8,8 +8,8 @@ export declare class BonusCorporateActionModel implements IBonusCorporateAction,
|
|
|
8
8
|
type: CorporateActionsType;
|
|
9
9
|
status: CorporateActionsStatus;
|
|
10
10
|
id: number;
|
|
11
|
-
createdOn:
|
|
12
|
-
updatedOn:
|
|
11
|
+
createdOn: number;
|
|
12
|
+
updatedOn: number;
|
|
13
13
|
createdBy: number;
|
|
14
14
|
updatedBy: number;
|
|
15
15
|
constructor(entity: ICorporateActionsEntity);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { BuyBackType, CorporateActionsStatus, CorporateActionsType } from "../../@enum";
|
|
2
|
-
import {
|
|
3
|
-
export declare class BuyBackCorporateActionModel implements
|
|
2
|
+
import { IBuyBackCorporateActionCreateDtoData, ICorporateActionsEntity, ICorporateEntityOmitData } from "../../@type";
|
|
3
|
+
export declare class BuyBackCorporateActionModel implements IBuyBackCorporateActionCreateDtoData, ICorporateEntityOmitData {
|
|
4
4
|
priceRange: string;
|
|
5
5
|
startDate: number;
|
|
6
6
|
endDate: number;
|
|
@@ -10,8 +10,8 @@ export declare class BuyBackCorporateActionModel implements IBuyBackCorporateAct
|
|
|
10
10
|
status: CorporateActionsStatus;
|
|
11
11
|
buyBackType: BuyBackType;
|
|
12
12
|
id: number;
|
|
13
|
-
createdOn:
|
|
14
|
-
updatedOn:
|
|
13
|
+
createdOn: number;
|
|
14
|
+
updatedOn: number;
|
|
15
15
|
createdBy: number;
|
|
16
16
|
updatedBy: number;
|
|
17
17
|
constructor(entity: ICorporateActionsEntity);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { CorporateActionsStatus, CorporateActionsType } from "../../@enum";
|
|
2
|
-
import { ICorporateActionsEntity } from "../../@type";
|
|
2
|
+
import { EntityEnum, ICorporateActionsEntity } from "../../@type";
|
|
3
|
+
import { BaseEntityModel } from "../base.entity.model";
|
|
3
4
|
import { BonusCorporateActionModel } from "./bonus-corporate-action-model";
|
|
4
5
|
import { BuyBackCorporateActionModel } from "./buy-back-corporate-action-model";
|
|
5
6
|
import { DelistingCorporateActionModel } from "./delisting-corporate-action-model";
|
|
@@ -11,18 +12,23 @@ import { OpenOfferCorporateActionModel } from "./open-offer-corporate-action-mod
|
|
|
11
12
|
import { RightIssueCorporateActionModel } from "./right-issue-corporate-action-model";
|
|
12
13
|
import { SplitBonusCorporateActionModel } from "./split-bonus-corporate-action-model";
|
|
13
14
|
import { SplitCorporateActionModel } from "./split-corporate-action-model";
|
|
14
|
-
export declare class
|
|
15
|
+
export declare class CorporateActionsEntityModel extends BaseEntityModel<EntityEnum.CORPORATE_ACTIONS> implements ICorporateActionsEntity {
|
|
15
16
|
id: number;
|
|
16
17
|
data: string;
|
|
17
18
|
companyName: string;
|
|
18
19
|
recordDate: number;
|
|
19
20
|
type: CorporateActionsType;
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
status: CorporateActionsStatus;
|
|
22
|
+
createdOn: number;
|
|
23
|
+
updatedOn: number;
|
|
22
24
|
createdBy: number;
|
|
23
25
|
updatedBy: number;
|
|
24
|
-
|
|
25
|
-
|
|
26
|
+
constructor();
|
|
27
|
+
/**
|
|
28
|
+
* Factory to convert from plain API entity
|
|
29
|
+
*/
|
|
30
|
+
static fromEntity(entity: ICorporateActionsEntity): CorporateActionsEntityModel;
|
|
31
|
+
getRelationConfigs(): any;
|
|
26
32
|
getFPOModel(): FPOCorporateActionModel;
|
|
27
33
|
getDividendModel(): DividendCorporateActionModel;
|
|
28
34
|
getBuyBackModel(): BuyBackCorporateActionModel;
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.CorporateActionsEntityModel = void 0;
|
|
4
|
+
const _enum_1 = require("../../@enum");
|
|
5
|
+
const _type_1 = require("../../@type");
|
|
6
|
+
const base_entity_model_1 = require("../base.entity.model");
|
|
4
7
|
const bonus_corporate_action_model_1 = require("./bonus-corporate-action-model");
|
|
5
8
|
const buy_back_corporate_action_model_1 = require("./buy-back-corporate-action-model");
|
|
6
9
|
const delisting_corporate_action_model_1 = require("./delisting-corporate-action-model");
|
|
@@ -12,10 +15,32 @@ const open_offer_corporate_action_model_1 = require("./open-offer-corporate-acti
|
|
|
12
15
|
const right_issue_corporate_action_model_1 = require("./right-issue-corporate-action-model");
|
|
13
16
|
const split_bonus_corporate_action_model_1 = require("./split-bonus-corporate-action-model");
|
|
14
17
|
const split_corporate_action_model_1 = require("./split-corporate-action-model");
|
|
15
|
-
class
|
|
16
|
-
constructor(
|
|
17
|
-
|
|
18
|
+
class CorporateActionsEntityModel extends base_entity_model_1.BaseEntityModel {
|
|
19
|
+
constructor() {
|
|
20
|
+
super(_type_1.EntityEnum.CORPORATE_ACTIONS);
|
|
21
|
+
this.id = 0;
|
|
22
|
+
this.data = "";
|
|
23
|
+
this.companyName = "";
|
|
24
|
+
this.recordDate = 0;
|
|
25
|
+
this.type = _enum_1.CorporateActionsType.BONUS;
|
|
26
|
+
this.status = _enum_1.CorporateActionsStatus.ACTIVE;
|
|
27
|
+
this.createdOn = 0;
|
|
28
|
+
this.updatedOn = 0;
|
|
29
|
+
this.createdBy = 0;
|
|
30
|
+
this.updatedBy = 0;
|
|
18
31
|
}
|
|
32
|
+
/**
|
|
33
|
+
* Factory to convert from plain API entity
|
|
34
|
+
*/
|
|
35
|
+
static fromEntity(entity) {
|
|
36
|
+
const result = new CorporateActionsEntityModel();
|
|
37
|
+
Object.assign(result, entity);
|
|
38
|
+
return result;
|
|
39
|
+
}
|
|
40
|
+
getRelationConfigs() {
|
|
41
|
+
return this.constructor.prototype.constructor.relationConfigs;
|
|
42
|
+
}
|
|
43
|
+
// ---- Existing model conversion methods ----
|
|
19
44
|
getFPOModel() {
|
|
20
45
|
return new fpo_corporate_action_model_1.FPOCorporateActionModel(this);
|
|
21
46
|
}
|
|
@@ -50,4 +75,52 @@ class CorporateActionsModel {
|
|
|
50
75
|
return new ofs_corporate_action_model_1.OFSCorporateActionModel(this);
|
|
51
76
|
}
|
|
52
77
|
}
|
|
53
|
-
exports.
|
|
78
|
+
exports.CorporateActionsEntityModel = CorporateActionsEntityModel;
|
|
79
|
+
// export class CorporateActionsModel implements ICorporateActionsEntity {
|
|
80
|
+
// id: number;
|
|
81
|
+
// data: string;
|
|
82
|
+
// companyName: string;
|
|
83
|
+
// recordDate: number;
|
|
84
|
+
// type: CorporateActionsType;
|
|
85
|
+
// createdOn: Date;
|
|
86
|
+
// updatedOn: Date;
|
|
87
|
+
// createdBy: number;
|
|
88
|
+
// updatedBy: number;
|
|
89
|
+
// status: CorporateActionsStatus;
|
|
90
|
+
// constructor(data: ICorporateActionsEntity) {
|
|
91
|
+
// Object.assign(this, data);
|
|
92
|
+
// }
|
|
93
|
+
// getFPOModel() {
|
|
94
|
+
// return new FPOCorporateActionModel(this);
|
|
95
|
+
// }
|
|
96
|
+
// getDividendModel() {
|
|
97
|
+
// return new DividendCorporateActionModel(this);
|
|
98
|
+
// }
|
|
99
|
+
// getBuyBackModel() {
|
|
100
|
+
// return new BuyBackCorporateActionModel(this);
|
|
101
|
+
// }
|
|
102
|
+
// getOpenOfferModel() {
|
|
103
|
+
// return new OpenOfferCorporateActionModel(this);
|
|
104
|
+
// }
|
|
105
|
+
// getDelistingModel() {
|
|
106
|
+
// return new DelistingCorporateActionModel(this);
|
|
107
|
+
// }
|
|
108
|
+
// getRightIssuesModel() {
|
|
109
|
+
// return new RightIssueCorporateActionModel(this);
|
|
110
|
+
// }
|
|
111
|
+
// getSplitStockModel() {
|
|
112
|
+
// return new SplitCorporateActionModel(this);
|
|
113
|
+
// }
|
|
114
|
+
// getBonusModel() {
|
|
115
|
+
// return new BonusCorporateActionModel(this);
|
|
116
|
+
// }
|
|
117
|
+
// getIPOModel() {
|
|
118
|
+
// return new IPOCorporateActionModel(this);
|
|
119
|
+
// }
|
|
120
|
+
// getSplitAndBonusStockModel() {
|
|
121
|
+
// return new SplitBonusCorporateActionModel(this);
|
|
122
|
+
// }
|
|
123
|
+
// getOFSModel() {
|
|
124
|
+
// return new OFSCorporateActionModel(this);
|
|
125
|
+
// }
|
|
126
|
+
// }
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { CorporateActionAdviceStatus, CorporateActionsTransactionType } from "../../@enum";
|
|
2
|
+
import { EntityEnum, ICorporateActionsAdviceEntity } from "../../@type";
|
|
3
|
+
import { BaseEntityModel } from "../base.entity.model";
|
|
4
|
+
export declare class CorporateActionsAdviceEntityModel extends BaseEntityModel<EntityEnum.CORPORATE_ACTIONS_ADVICE> implements ICorporateActionsAdviceEntity {
|
|
5
|
+
id: number;
|
|
6
|
+
corporateActionId: number;
|
|
7
|
+
companyName: string;
|
|
8
|
+
transactionType: CorporateActionsTransactionType;
|
|
9
|
+
advisorOrgId: number;
|
|
10
|
+
status: CorporateActionAdviceStatus;
|
|
11
|
+
noteDocumentUrl: string | null;
|
|
12
|
+
videoUrl: string | null;
|
|
13
|
+
voiceUrl: string | null;
|
|
14
|
+
rationale: string | null;
|
|
15
|
+
createdOn: number;
|
|
16
|
+
updatedOn: number;
|
|
17
|
+
createdBy: number;
|
|
18
|
+
updatedBy: number;
|
|
19
|
+
constructor();
|
|
20
|
+
/**
|
|
21
|
+
* Convert plain API entity to model instance
|
|
22
|
+
*/
|
|
23
|
+
static fromEntity(entity: ICorporateActionsAdviceEntity): CorporateActionsAdviceEntityModel;
|
|
24
|
+
getRelationConfigs(): any;
|
|
25
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CorporateActionsAdviceEntityModel = void 0;
|
|
4
|
+
const _enum_1 = require("../../@enum");
|
|
5
|
+
const _type_1 = require("../../@type");
|
|
6
|
+
const base_entity_model_1 = require("../base.entity.model");
|
|
7
|
+
class CorporateActionsAdviceEntityModel extends base_entity_model_1.BaseEntityModel {
|
|
8
|
+
constructor() {
|
|
9
|
+
super(_type_1.EntityEnum.CORPORATE_ACTIONS_ADVICE);
|
|
10
|
+
this.id = 0;
|
|
11
|
+
this.corporateActionId = 0;
|
|
12
|
+
this.companyName = "";
|
|
13
|
+
this.transactionType = _enum_1.CorporateActionsTransactionType.POSITIVE;
|
|
14
|
+
this.advisorOrgId = 0;
|
|
15
|
+
this.status = _enum_1.CorporateActionAdviceStatus.ACTIVE;
|
|
16
|
+
this.noteDocumentUrl = null;
|
|
17
|
+
this.videoUrl = null;
|
|
18
|
+
this.voiceUrl = null;
|
|
19
|
+
this.rationale = null;
|
|
20
|
+
this.createdOn = 0;
|
|
21
|
+
this.updatedOn = 0;
|
|
22
|
+
this.createdBy = 0;
|
|
23
|
+
this.updatedBy = 0;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Convert plain API entity to model instance
|
|
27
|
+
*/
|
|
28
|
+
static fromEntity(entity) {
|
|
29
|
+
const result = new CorporateActionsAdviceEntityModel();
|
|
30
|
+
Object.assign(result, entity);
|
|
31
|
+
return result;
|
|
32
|
+
}
|
|
33
|
+
getRelationConfigs() {
|
|
34
|
+
return this.constructor.prototype.constructor.relationConfigs;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
exports.CorporateActionsAdviceEntityModel = CorporateActionsAdviceEntityModel;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CorporateActionsStatus, CorporateActionsType } from "../../@enum";
|
|
2
|
-
import { ICorporateActionsEntity, ICorporateEntityOmitData,
|
|
3
|
-
export declare class DelistingCorporateActionModel implements
|
|
2
|
+
import { ICorporateActionsEntity, ICorporateEntityOmitData, IDelistingCorporateActionCreateDtoData } from "../../@type";
|
|
3
|
+
export declare class DelistingCorporateActionModel implements IDelistingCorporateActionCreateDtoData, ICorporateEntityOmitData {
|
|
4
4
|
floorPrice: number;
|
|
5
5
|
startDate: number;
|
|
6
6
|
endDate: number;
|
|
@@ -9,8 +9,8 @@ export declare class DelistingCorporateActionModel implements IDelistingCorporat
|
|
|
9
9
|
type: CorporateActionsType;
|
|
10
10
|
status: CorporateActionsStatus;
|
|
11
11
|
id: number;
|
|
12
|
-
createdOn:
|
|
13
|
-
updatedOn:
|
|
12
|
+
createdOn: number;
|
|
13
|
+
updatedOn: number;
|
|
14
14
|
createdBy: number;
|
|
15
15
|
updatedBy: number;
|
|
16
16
|
constructor(entity: ICorporateActionsEntity);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CorporateActionsStatus, CorporateActionsType } from "../../@enum";
|
|
2
|
-
import { ICorporateActionsEntity, ICorporateEntityOmitData,
|
|
3
|
-
export declare class DividendCorporateActionModel implements
|
|
2
|
+
import { ICorporateActionsEntity, ICorporateEntityOmitData, IDividendCorporateActionCreateDtoData } from "../../@type";
|
|
3
|
+
export declare class DividendCorporateActionModel implements IDividendCorporateActionCreateDtoData, ICorporateEntityOmitData {
|
|
4
4
|
type: CorporateActionsType;
|
|
5
5
|
percentageOnFaceValue: number;
|
|
6
6
|
dividendPerShare: number;
|
|
@@ -9,8 +9,8 @@ export declare class DividendCorporateActionModel implements IDividendCorporateA
|
|
|
9
9
|
faceValue: number;
|
|
10
10
|
status: CorporateActionsStatus;
|
|
11
11
|
id: number;
|
|
12
|
-
createdOn:
|
|
13
|
-
updatedOn:
|
|
12
|
+
createdOn: number;
|
|
13
|
+
updatedOn: number;
|
|
14
14
|
createdBy: number;
|
|
15
15
|
updatedBy: number;
|
|
16
16
|
constructor(entity: ICorporateActionsEntity);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CorporateActionsStatus, CorporateActionsType } from "../../@enum";
|
|
2
|
-
import { ICorporateActionsEntity,
|
|
3
|
-
export declare class FPOCorporateActionModel implements
|
|
2
|
+
import { ICorporateActionsEntity, IFPOCorporateActionCreateDtoData } from "../../@type";
|
|
3
|
+
export declare class FPOCorporateActionModel implements IFPOCorporateActionCreateDtoData, ICorporateActionsEntity {
|
|
4
4
|
companyName: string;
|
|
5
5
|
recordDate: number;
|
|
6
6
|
type: CorporateActionsType;
|
|
@@ -11,8 +11,8 @@ export declare class FPOCorporateActionModel implements IFPOCorporateAction, ICo
|
|
|
11
11
|
recommendation: string;
|
|
12
12
|
id: number;
|
|
13
13
|
data: string;
|
|
14
|
-
createdOn:
|
|
15
|
-
updatedOn:
|
|
14
|
+
createdOn: number;
|
|
15
|
+
updatedOn: number;
|
|
16
16
|
createdBy: number;
|
|
17
17
|
updatedBy: number;
|
|
18
18
|
status: CorporateActionsStatus;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CorporateActionsStatus, CorporateActionsType, IPOListingExchange } from "../../@enum";
|
|
2
|
-
import { ICorporateActionsEntity, ICorporateEntityOmitData,
|
|
3
|
-
export declare class IPOCorporateActionModel implements
|
|
2
|
+
import { ICorporateActionsEntity, ICorporateEntityOmitData, IIPOCorporateActionCreateDtoData } from "../../@type";
|
|
3
|
+
export declare class IPOCorporateActionModel implements IIPOCorporateActionCreateDtoData, ICorporateEntityOmitData {
|
|
4
4
|
startDate: number;
|
|
5
5
|
endDate: number;
|
|
6
6
|
priceRange: string;
|
|
@@ -11,8 +11,8 @@ export declare class IPOCorporateActionModel implements IIPOCorporateAction, ICo
|
|
|
11
11
|
type: CorporateActionsType;
|
|
12
12
|
status: CorporateActionsStatus;
|
|
13
13
|
id: number;
|
|
14
|
-
createdOn:
|
|
15
|
-
updatedOn:
|
|
14
|
+
createdOn: number;
|
|
15
|
+
updatedOn: number;
|
|
16
16
|
createdBy: number;
|
|
17
17
|
updatedBy: number;
|
|
18
18
|
constructor(entity: ICorporateActionsEntity);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CorporateActionsStatus, CorporateActionsType } from "../../@enum";
|
|
2
|
-
import { ICorporateActionsEntity, ICorporateEntityOmitData,
|
|
3
|
-
export declare class OFSCorporateActionModel implements
|
|
2
|
+
import { ICorporateActionsEntity, ICorporateEntityOmitData, IOFSCorporateActionCreateDtoData } from "../../@type";
|
|
3
|
+
export declare class OFSCorporateActionModel implements IOFSCorporateActionCreateDtoData, ICorporateEntityOmitData {
|
|
4
4
|
floorPrice: number;
|
|
5
5
|
startDate: number;
|
|
6
6
|
endDate: number;
|
|
@@ -9,8 +9,8 @@ export declare class OFSCorporateActionModel implements IOFSCorporateAction, ICo
|
|
|
9
9
|
type: CorporateActionsType;
|
|
10
10
|
status: CorporateActionsStatus;
|
|
11
11
|
id: number;
|
|
12
|
-
createdOn:
|
|
13
|
-
updatedOn:
|
|
12
|
+
createdOn: number;
|
|
13
|
+
updatedOn: number;
|
|
14
14
|
createdBy: number;
|
|
15
15
|
updatedBy: number;
|
|
16
16
|
constructor(entity: ICorporateActionsEntity);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CorporateActionsStatus, CorporateActionsType } from "../../@enum";
|
|
2
|
-
import { ICorporateActionsEntity, ICorporateEntityOmitData,
|
|
3
|
-
export declare class OpenOfferCorporateActionModel implements
|
|
2
|
+
import { ICorporateActionsEntity, ICorporateEntityOmitData, IOpenOfferCorporateActionCreateDtoData } from "../../@type";
|
|
3
|
+
export declare class OpenOfferCorporateActionModel implements IOpenOfferCorporateActionCreateDtoData, ICorporateEntityOmitData {
|
|
4
4
|
price: number;
|
|
5
5
|
startDate: number;
|
|
6
6
|
endDate: number;
|
|
@@ -9,8 +9,8 @@ export declare class OpenOfferCorporateActionModel implements IOpenOfferCorporat
|
|
|
9
9
|
type: CorporateActionsType;
|
|
10
10
|
status: CorporateActionsStatus;
|
|
11
11
|
id: number;
|
|
12
|
-
createdOn:
|
|
13
|
-
updatedOn:
|
|
12
|
+
createdOn: number;
|
|
13
|
+
updatedOn: number;
|
|
14
14
|
createdBy: number;
|
|
15
15
|
updatedBy: number;
|
|
16
16
|
constructor(entity: ICorporateActionsEntity);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CorporateActionsStatus, CorporateActionsType } from "../../@enum";
|
|
2
|
-
import { ICorporateActionsEntity, ICorporateEntityOmitData,
|
|
3
|
-
export declare class RightIssueCorporateActionModel implements
|
|
2
|
+
import { ICorporateActionsEntity, ICorporateEntityOmitData, IRightIssueCorporateActionCreateDtoData } from "../../@type";
|
|
3
|
+
export declare class RightIssueCorporateActionModel implements IRightIssueCorporateActionCreateDtoData, ICorporateEntityOmitData {
|
|
4
4
|
price: number;
|
|
5
5
|
startDate: number;
|
|
6
6
|
endDate: number;
|
|
@@ -11,8 +11,8 @@ export declare class RightIssueCorporateActionModel implements IRightIssueCorpor
|
|
|
11
11
|
status: CorporateActionsStatus;
|
|
12
12
|
ratioInWord: string;
|
|
13
13
|
id: number;
|
|
14
|
-
createdOn:
|
|
15
|
-
updatedOn:
|
|
14
|
+
createdOn: number;
|
|
15
|
+
updatedOn: number;
|
|
16
16
|
createdBy: number;
|
|
17
17
|
updatedBy: number;
|
|
18
18
|
constructor(entity: ICorporateActionsEntity);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CorporateActionsStatus, CorporateActionsType, OrderOfSplitAndBonusStock } from "../../@enum";
|
|
2
|
-
import { IBonusStockData, ICorporateActionsEntity, ICorporateEntityOmitData,
|
|
3
|
-
export declare class SplitBonusCorporateActionModel implements
|
|
2
|
+
import { IBonusStockData, ICorporateActionsEntity, ICorporateEntityOmitData, ISplitBonusCorporateActionCreateDtoData, ISplitStockData } from "../../@type";
|
|
3
|
+
export declare class SplitBonusCorporateActionModel implements ISplitBonusCorporateActionCreateDtoData, ICorporateEntityOmitData {
|
|
4
4
|
splitStock: ISplitStockData;
|
|
5
5
|
bonusStock: IBonusStockData;
|
|
6
6
|
order: OrderOfSplitAndBonusStock;
|
|
@@ -9,8 +9,8 @@ export declare class SplitBonusCorporateActionModel implements ISplitBonusCorpor
|
|
|
9
9
|
type: CorporateActionsType;
|
|
10
10
|
status: CorporateActionsStatus;
|
|
11
11
|
id: number;
|
|
12
|
-
createdOn:
|
|
13
|
-
updatedOn:
|
|
12
|
+
createdOn: number;
|
|
13
|
+
updatedOn: number;
|
|
14
14
|
createdBy: number;
|
|
15
15
|
updatedBy: number;
|
|
16
16
|
constructor(entity: ICorporateActionsEntity);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CorporateActionsStatus, CorporateActionsType } from "../../@enum";
|
|
2
|
-
import { ICorporateActionsEntity, ICorporateEntityOmitData,
|
|
3
|
-
export declare class SplitCorporateActionModel implements
|
|
2
|
+
import { ICorporateActionsEntity, ICorporateEntityOmitData, ISplitCorporateActionCreateDtoData } from "../../@type";
|
|
3
|
+
export declare class SplitCorporateActionModel implements ISplitCorporateActionCreateDtoData, ICorporateEntityOmitData {
|
|
4
4
|
currentFV: number;
|
|
5
5
|
newFV: number;
|
|
6
6
|
companyName: string;
|
|
@@ -8,8 +8,8 @@ export declare class SplitCorporateActionModel implements ISplitCorporateAction,
|
|
|
8
8
|
type: CorporateActionsType;
|
|
9
9
|
status: CorporateActionsStatus;
|
|
10
10
|
id: number;
|
|
11
|
-
createdOn:
|
|
12
|
-
updatedOn:
|
|
11
|
+
createdOn: number;
|
|
12
|
+
updatedOn: number;
|
|
13
13
|
createdBy: number;
|
|
14
14
|
updatedBy: number;
|
|
15
15
|
constructor(entity: ICorporateActionsEntity);
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { EntityEnum, ICronJobsEntity } from "../@type";
|
|
2
|
+
import { CronJobsNames, CronJobsStatus } from "../@enum";
|
|
3
|
+
import { BaseEntityModel } from "./base.entity.model";
|
|
4
|
+
export declare class CronJobsEntityModel extends BaseEntityModel<EntityEnum.CRON_JOBS> implements ICronJobsEntity {
|
|
5
|
+
id: number;
|
|
6
|
+
job: CronJobsNames;
|
|
7
|
+
startTime: Date;
|
|
8
|
+
endTime: Date | null;
|
|
9
|
+
message: string;
|
|
10
|
+
error: string;
|
|
11
|
+
data: string;
|
|
12
|
+
status: CronJobsStatus;
|
|
13
|
+
createdOn: number;
|
|
14
|
+
updatedOn: number;
|
|
15
|
+
createdBy: number;
|
|
16
|
+
updatedBy: number;
|
|
17
|
+
constructor();
|
|
18
|
+
/**
|
|
19
|
+
* Factory method to create a model from an entity instance
|
|
20
|
+
*/
|
|
21
|
+
static fromEntity(entity: ICronJobsEntity): CronJobsEntityModel;
|
|
22
|
+
getRelationConfigs(): any[];
|
|
23
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CronJobsEntityModel = void 0;
|
|
4
|
+
const _type_1 = require("../@type");
|
|
5
|
+
const base_entity_model_1 = require("./base.entity.model");
|
|
6
|
+
class CronJobsEntityModel extends base_entity_model_1.BaseEntityModel {
|
|
7
|
+
constructor() {
|
|
8
|
+
super(_type_1.EntityEnum.CRON_JOBS);
|
|
9
|
+
this.id = 0;
|
|
10
|
+
this.job = "";
|
|
11
|
+
this.startTime = new Date();
|
|
12
|
+
this.endTime = null;
|
|
13
|
+
this.message = "";
|
|
14
|
+
this.error = "";
|
|
15
|
+
this.data = "";
|
|
16
|
+
this.status = "";
|
|
17
|
+
this.createdOn = 0;
|
|
18
|
+
this.updatedOn = 0;
|
|
19
|
+
this.createdBy = 0;
|
|
20
|
+
this.updatedBy = 0;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Factory method to create a model from an entity instance
|
|
24
|
+
*/
|
|
25
|
+
static fromEntity(entity) {
|
|
26
|
+
const result = new CronJobsEntityModel();
|
|
27
|
+
Object.assign(result, entity);
|
|
28
|
+
return result;
|
|
29
|
+
}
|
|
30
|
+
getRelationConfigs() {
|
|
31
|
+
return this.constructor.prototype.constructor.relationConfigs;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
exports.CronJobsEntityModel = CronJobsEntityModel;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AdviceType, InvestDurationType, AdviceTransactionType, AdviceStatus } from "../@enum";
|
|
2
|
-
import { EntityEnum,
|
|
2
|
+
import { EntityEnum, IEquityAdviceEntity } from "../@type";
|
|
3
3
|
import { BaseEntityModel } from "./base.entity.model";
|
|
4
|
-
export declare class EquityAdviceEntityModel extends BaseEntityModel<EntityEnum.EQUITY_ADVICE> implements
|
|
4
|
+
export declare class EquityAdviceEntityModel extends BaseEntityModel<EntityEnum.EQUITY_ADVICE> implements IEquityAdviceEntity {
|
|
5
5
|
id: number;
|
|
6
6
|
type: AdviceType;
|
|
7
7
|
advisorOrgId: number;
|
|
@@ -26,7 +26,7 @@ export declare class EquityAdviceEntityModel extends BaseEntityModel<EntityEnum.
|
|
|
26
26
|
createdBy: number;
|
|
27
27
|
updatedBy: number;
|
|
28
28
|
getRelationConfigs(): any;
|
|
29
|
-
static fromEntity(entity:
|
|
29
|
+
static fromEntity(entity: IEquityAdviceEntity): EquityAdviceEntityModel;
|
|
30
30
|
getRandomHigh(): number;
|
|
31
31
|
getGainLoss(randomHigh?: number): number;
|
|
32
32
|
}
|