taxtank-core 0.33.60 → 0.33.61
Sign up to get free protection for your applications and to get access to all the features.
- package/esm2022/src/lib/collections/asset-sale.collection.mjs +4 -1
- package/esm2022/src/lib/collections/collection-dictionary.mjs +10 -1
- package/esm2022/src/lib/collections/collection.mjs +1 -1
- package/esm2022/src/lib/collections/holding/holding-sale.collection.mjs +3 -3
- package/esm2022/src/lib/collections/holding/holding-trade.collection.mjs +78 -0
- package/esm2022/src/lib/collections/holding/holding.collection.mjs +19 -54
- package/esm2022/src/lib/collections/holding/index.mjs +3 -2
- package/esm2022/src/lib/db/Enums/holding/holding-trade-type.enum.mjs +6 -0
- package/esm2022/src/lib/db/Enums/holding/holding-type-category.enum.mjs +1 -1
- package/esm2022/src/lib/db/Enums/holding/index.mjs +2 -1
- package/esm2022/src/lib/db/Models/holding/holding-sale.mjs +1 -1
- package/esm2022/src/lib/db/Models/holding/holding-trade-import.mjs +3 -0
- package/esm2022/src/lib/db/Models/holding/holding-trade.mjs +3 -0
- package/esm2022/src/lib/db/Models/holding/index.mjs +2 -2
- package/esm2022/src/lib/forms/abstract.form.mjs +6 -1
- package/esm2022/src/lib/forms/holding/holding-reinvest.form.mjs +14 -14
- package/esm2022/src/lib/forms/holding/holding-sale.form.mjs +3 -2
- package/esm2022/src/lib/forms/holding/holding-trade/holding-trade-filter.form.mjs +25 -0
- package/esm2022/src/lib/forms/holding/holding-trade/holding-trade.form.mjs +30 -0
- package/esm2022/src/lib/forms/holding/holding-trade/index.mjs +3 -0
- package/esm2022/src/lib/forms/holding/holding-trade-import.form.mjs +25 -0
- package/esm2022/src/lib/forms/holding/index.mjs +3 -3
- package/esm2022/src/lib/models/endpoint/endpoints.const.mjs +9 -9
- package/esm2022/src/lib/models/holding/holding-reinvest.mjs +4 -4
- package/esm2022/src/lib/models/holding/holding-sale.mjs +10 -1
- package/esm2022/src/lib/models/holding/holding-trade-import.mjs +16 -0
- package/esm2022/src/lib/models/holding/holding-trade.mjs +77 -0
- package/esm2022/src/lib/models/holding/holding-type-exchange.mjs +4 -1
- package/esm2022/src/lib/models/holding/holding-type.mjs +4 -1
- package/esm2022/src/lib/models/holding/holding.mjs +44 -71
- package/esm2022/src/lib/models/holding/index.mjs +4 -3
- package/esm2022/src/lib/services/account-setup/account-setup.service.mjs +3 -3
- package/esm2022/src/lib/services/http/holding/holding-trade-import/holding-trade-import-messages.enum.mjs +9 -0
- package/esm2022/src/lib/services/http/holding/holding-trade-import/holding-trade-import.service.mjs +37 -0
- package/esm2022/src/lib/services/http/holding/holding-trade-messages.enum.mjs +10 -0
- package/esm2022/src/lib/services/http/holding/holding-trade.service.mjs +44 -0
- package/esm2022/src/lib/services/http/holding/index.mjs +5 -6
- package/fesm2022/taxtank-core.mjs +330 -185
- package/fesm2022/taxtank-core.mjs.map +1 -1
- package/package.json +1 -1
- package/src/lib/collections/asset-sale.collection.d.ts +3 -0
- package/src/lib/collections/collection-dictionary.d.ts +1 -0
- package/src/lib/collections/holding/holding-sale.collection.d.ts +4 -4
- package/src/lib/collections/holding/holding-trade.collection.d.ts +21 -0
- package/src/lib/collections/holding/holding.collection.d.ts +7 -10
- package/src/lib/collections/holding/index.d.ts +2 -1
- package/src/lib/db/Enums/holding/holding-trade-type.enum.d.ts +4 -0
- package/src/lib/db/Enums/holding/index.d.ts +1 -0
- package/src/lib/db/Models/holding/holding-sale.d.ts +2 -2
- package/src/lib/db/Models/holding/holding-trade-import.d.ts +8 -0
- package/src/lib/db/Models/holding/{holding.d.ts → holding-trade.d.ts} +1 -1
- package/src/lib/db/Models/holding/index.d.ts +1 -1
- package/src/lib/forms/abstract.form.d.ts +2 -0
- package/src/lib/forms/holding/holding-reinvest.form.d.ts +5 -5
- package/src/lib/forms/holding/holding-sale.form.d.ts +2 -2
- package/src/lib/forms/holding/holding-trade/holding-trade-filter.form.d.ts +9 -0
- package/src/lib/forms/holding/holding-trade/holding-trade.form.d.ts +9 -0
- package/src/lib/forms/holding/holding-trade/index.d.ts +2 -0
- package/src/lib/forms/holding/holding-trade-import.form.d.ts +8 -0
- package/src/lib/forms/holding/index.d.ts +2 -2
- package/src/lib/models/holding/holding-reinvest.d.ts +2 -2
- package/src/lib/models/holding/holding-sale.d.ts +16 -4
- package/src/lib/models/holding/holding-trade-import.d.ts +8 -0
- package/src/lib/models/holding/holding-trade.d.ts +41 -0
- package/src/lib/models/holding/holding-type-exchange.d.ts +3 -0
- package/src/lib/models/holding/holding-type.d.ts +3 -0
- package/src/lib/models/holding/holding.d.ts +18 -34
- package/src/lib/models/holding/index.d.ts +3 -2
- package/src/lib/services/account-setup/account-setup.service.d.ts +2 -2
- package/src/lib/services/http/holding/{holding-import/holding-import-messages.enum.d.ts → holding-trade-import/holding-trade-import-messages.enum.d.ts} +1 -1
- package/src/lib/services/http/holding/holding-trade-import/holding-trade-import.service.d.ts +17 -0
- package/src/lib/services/http/holding/{holding-messages.enum.d.ts → holding-trade-messages.enum.d.ts} +1 -1
- package/src/lib/services/http/holding/holding-trade.service.d.ts +20 -0
- package/src/lib/services/http/holding/index.d.ts +4 -5
- package/esm2022/src/lib/db/Models/holding/holding-import.mjs +0 -3
- package/esm2022/src/lib/db/Models/holding/holding.mjs +0 -3
- package/esm2022/src/lib/forms/holding/holding-import.form.mjs +0 -25
- package/esm2022/src/lib/forms/holding/holding.form.mjs +0 -28
- package/esm2022/src/lib/models/holding/holding-import.mjs +0 -16
- package/esm2022/src/lib/services/http/holding/holding-import/holding-import-messages.enum.mjs +0 -9
- package/esm2022/src/lib/services/http/holding/holding-import/holding-import.service.mjs +0 -37
- package/esm2022/src/lib/services/http/holding/holding-messages.enum.mjs +0 -10
- package/esm2022/src/lib/services/http/holding/holding-sale-messages.enum.mjs +0 -8
- package/esm2022/src/lib/services/http/holding/holding.service.mjs +0 -44
- package/src/lib/db/Models/holding/holding-import.d.ts +0 -8
- package/src/lib/forms/holding/holding-import.form.d.ts +0 -8
- package/src/lib/forms/holding/holding.form.d.ts +0 -8
- package/src/lib/models/holding/holding-import.d.ts +0 -8
- package/src/lib/services/http/holding/holding-import/holding-import.service.d.ts +0 -17
- package/src/lib/services/http/holding/holding-sale-messages.enum.d.ts +0 -6
- package/src/lib/services/http/holding/holding.service.d.ts +0 -20
@@ -1,16 +0,0 @@
|
|
1
|
-
import { __decorate } from "tslib";
|
2
|
-
import { Holding, ObservableModel } from '../../db/Models';
|
3
|
-
import { Type } from 'class-transformer';
|
4
|
-
export class HoldingImport extends ObservableModel {
|
5
|
-
static { this.className = 'HoldingImport'; }
|
6
|
-
}
|
7
|
-
__decorate([
|
8
|
-
Type(() => Date)
|
9
|
-
], HoldingImport.prototype, "createdAt", void 0);
|
10
|
-
__decorate([
|
11
|
-
Type(() => Date)
|
12
|
-
], HoldingImport.prototype, "updatedAt", void 0);
|
13
|
-
__decorate([
|
14
|
-
Type(() => Holding)
|
15
|
-
], HoldingImport.prototype, "holdings", void 0);
|
16
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaG9sZGluZy1pbXBvcnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy90dC1jb3JlL3NyYy9saWIvbW9kZWxzL2hvbGRpbmcvaG9sZGluZy1pbXBvcnQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLE9BQU8sRUFBRSxPQUFPLEVBQUUsZUFBZSxFQUFFLE1BQU0saUJBQWlCLENBQUM7QUFDM0QsT0FBTyxFQUFFLElBQUksRUFBRSxNQUFNLG1CQUFtQixDQUFDO0FBRXpDLE1BQU0sT0FBTyxhQUFjLFNBQVEsZUFBZTthQUN6QyxjQUFTLEdBQUcsZUFBZSxDQUFDOztBQUduQztJQURDLElBQUksQ0FBQyxHQUFHLEVBQUUsQ0FBQyxJQUFJLENBQUM7Z0RBQ0Q7QUFFaEI7SUFEQyxJQUFJLENBQUMsR0FBRyxFQUFFLENBQUMsSUFBSSxDQUFDO2dEQUNEO0FBRWhCO0lBREMsSUFBSSxDQUFDLEdBQUcsRUFBRSxDQUFDLE9BQU8sQ0FBQzsrQ0FDQyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IEhvbGRpbmcsIE9ic2VydmFibGVNb2RlbCB9IGZyb20gJy4uLy4uL2RiL01vZGVscyc7XG5pbXBvcnQgeyBUeXBlIH0gZnJvbSAnY2xhc3MtdHJhbnNmb3JtZXInO1xuXG5leHBvcnQgY2xhc3MgSG9sZGluZ0ltcG9ydCBleHRlbmRzIE9ic2VydmFibGVNb2RlbCB7XG4gIHN0YXRpYyBjbGFzc05hbWUgPSAnSG9sZGluZ0ltcG9ydCc7XG4gIG9yaWdpbmFsTmFtZTogc3RyaW5nO1xuICBAVHlwZSgoKSA9PiBEYXRlKVxuICBjcmVhdGVkQXQ6IERhdGU7XG4gIEBUeXBlKCgpID0+IERhdGUpXG4gIHVwZGF0ZWRBdDogRGF0ZTtcbiAgQFR5cGUoKCkgPT4gSG9sZGluZylcbiAgaG9sZGluZ3M/OiBIb2xkaW5nW107XG59XG4iXX0=
|
package/esm2022/src/lib/services/http/holding/holding-import/holding-import-messages.enum.mjs
DELETED
@@ -1,9 +0,0 @@
|
|
1
|
-
export var HoldingImportMessagesEnum;
|
2
|
-
(function (HoldingImportMessagesEnum) {
|
3
|
-
HoldingImportMessagesEnum["CREATED"] = "Import created successfully";
|
4
|
-
HoldingImportMessagesEnum["UPDATED"] = "Import updated successfully";
|
5
|
-
HoldingImportMessagesEnum["CONFIRM_DELETE"] = "Are you sure you want to delete this import?";
|
6
|
-
HoldingImportMessagesEnum["DELETED"] = "Import deleted successfully";
|
7
|
-
HoldingImportMessagesEnum["DELETE_ERROR"] = "Import including sold assets can not be deleted";
|
8
|
-
})(HoldingImportMessagesEnum || (HoldingImportMessagesEnum = {}));
|
9
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaG9sZGluZy1pbXBvcnQtbWVzc2FnZXMuZW51bS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3R0LWNvcmUvc3JjL2xpYi9zZXJ2aWNlcy9odHRwL2hvbGRpbmcvaG9sZGluZy1pbXBvcnQvaG9sZGluZy1pbXBvcnQtbWVzc2FnZXMuZW51bS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxNQUFNLENBQU4sSUFBWSx5QkFNWDtBQU5ELFdBQVkseUJBQXlCO0lBQ25DLG9FQUF1QyxDQUFBO0lBQ3ZDLG9FQUF1QyxDQUFBO0lBQ3ZDLDRGQUErRCxDQUFBO0lBQy9ELG9FQUF1QyxDQUFBO0lBQ3ZDLDZGQUFnRSxDQUFBO0FBQ2xFLENBQUMsRUFOVyx5QkFBeUIsS0FBekIseUJBQXlCLFFBTXBDIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0IGVudW0gSG9sZGluZ0ltcG9ydE1lc3NhZ2VzRW51bSB7XG4gIENSRUFURUQgPSAnSW1wb3J0IGNyZWF0ZWQgc3VjY2Vzc2Z1bGx5JyxcbiAgVVBEQVRFRCA9ICdJbXBvcnQgdXBkYXRlZCBzdWNjZXNzZnVsbHknLFxuICBDT05GSVJNX0RFTEVURSA9ICdBcmUgeW91IHN1cmUgeW91IHdhbnQgdG8gZGVsZXRlIHRoaXMgaW1wb3J0PycsXG4gIERFTEVURUQgPSAnSW1wb3J0IGRlbGV0ZWQgc3VjY2Vzc2Z1bGx5JyxcbiAgREVMRVRFX0VSUk9SID0gJ0ltcG9ydCBpbmNsdWRpbmcgc29sZCBhc3NldHMgY2FuIG5vdCBiZSBkZWxldGVkJ1xufVxuIl19
|
@@ -1,37 +0,0 @@
|
|
1
|
-
import { Injectable } from '@angular/core';
|
2
|
-
import { RestService } from '../../rest';
|
3
|
-
import { Collection } from '../../../../collections';
|
4
|
-
import { UserRolesEnum } from 'taxtank-core/common';
|
5
|
-
import { HoldingImport } from '../../../../models/holding/holding-import';
|
6
|
-
import { map } from 'rxjs/operators';
|
7
|
-
import * as i0 from "@angular/core";
|
8
|
-
export class HoldingImportService extends RestService {
|
9
|
-
constructor() {
|
10
|
-
super(...arguments);
|
11
|
-
this.modelClass = HoldingImport;
|
12
|
-
this.collectionClass = (Collection);
|
13
|
-
this.endpointUri = 'holding-imports';
|
14
|
-
this.disabledMethods = ['post', 'postBatch', 'putBatch', 'deleteBatch'];
|
15
|
-
this.roles = [UserRolesEnum.HOLDING_TANK];
|
16
|
-
}
|
17
|
-
import(file, exchangeId, isTaxFree) {
|
18
|
-
const formData = new FormData();
|
19
|
-
formData.append('file', file);
|
20
|
-
formData.append('exchangeId', exchangeId.toString());
|
21
|
-
formData.append('isTaxFree', (isTaxFree ? 1 : 0).toString());
|
22
|
-
return this.http.post(this.apiUrl, formData).pipe(map((response) => {
|
23
|
-
const holdingImport = this.createModelInstance(response);
|
24
|
-
this.handleResponse([holdingImport], 'post');
|
25
|
-
return holdingImport;
|
26
|
-
}));
|
27
|
-
}
|
28
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: HoldingImportService, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
|
29
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: HoldingImportService, providedIn: 'root' }); }
|
30
|
-
}
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: HoldingImportService, decorators: [{
|
32
|
-
type: Injectable,
|
33
|
-
args: [{
|
34
|
-
providedIn: 'root'
|
35
|
-
}]
|
36
|
-
}] });
|
37
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaG9sZGluZy1pbXBvcnQuc2VydmljZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4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NlcnZhYmxlPEhvbGRpbmdJbXBvcnQ+IHtcbiAgICBjb25zdCBmb3JtRGF0YTogRm9ybURhdGEgPSBuZXcgRm9ybURhdGEoKTtcbiAgICBmb3JtRGF0YS5hcHBlbmQoJ2ZpbGUnLCBmaWxlKTtcbiAgICBmb3JtRGF0YS5hcHBlbmQoJ2V4Y2hhbmdlSWQnLCBleGNoYW5nZUlkLnRvU3RyaW5nKCkpO1xuICAgIGZvcm1EYXRhLmFwcGVuZCgnaXNUYXhGcmVlJywgKGlzVGF4RnJlZSA/IDEgOiAwKS50b1N0cmluZygpKTtcblxuICAgIHJldHVybiB0aGlzLmh0dHAucG9zdCh0aGlzLmFwaVVybCwgZm9ybURhdGEpLnBpcGUoXG4gICAgICBtYXAoKHJlc3BvbnNlOiBvYmplY3QpID0+IHtcbiAgICAgICAgY29uc3QgaG9sZGluZ0ltcG9ydDogSG9sZGluZ0ltcG9ydCA9IHRoaXMuY3JlYXRlTW9kZWxJbnN0YW5jZShyZXNwb25zZSk7XG4gICAgICAgIHRoaXMuaGFuZGxlUmVzcG9uc2UoW2hvbGRpbmdJbXBvcnRdLCAncG9zdCcpO1xuXG4gICAgICAgIHJldHVybiBob2xkaW5nSW1wb3J0O1xuICAgICAgfSlcbiAgICApO1xuICB9XG59XG4iXX0=
|
@@ -1,10 +0,0 @@
|
|
1
|
-
export var HoldingMessagesEnum;
|
2
|
-
(function (HoldingMessagesEnum) {
|
3
|
-
HoldingMessagesEnum["CREATED"] = "Holding created successfully";
|
4
|
-
HoldingMessagesEnum["UPDATED"] = "Holding updated successfully";
|
5
|
-
HoldingMessagesEnum["CONFIRM_DELETE"] = "Are you sure you want to delete this holding?";
|
6
|
-
HoldingMessagesEnum["DELETED"] = "Holding deleted successfully";
|
7
|
-
HoldingMessagesEnum["DELETE_ASSET_ERROR"] = "In the \"SOLD\" section click on the \"REDO\" button for the current asset";
|
8
|
-
HoldingMessagesEnum["REINVESTED"] = "Reinvested successfully";
|
9
|
-
})(HoldingM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VkVTVEVEID0gJ1JlaW52ZXN0ZWQgc3VjY2Vzc2Z1bGx5J1xufVxuIl19
|
@@ -1,8 +0,0 @@
|
|
1
|
-
export var HoldingSaleMessagesEnum;
|
2
|
-
(function (HoldingSaleMessagesEnum) {
|
3
|
-
HoldingSaleMessagesEnum["CREATED"] = "Holding sold successfully";
|
4
|
-
HoldingSaleMessagesEnum["UPDATED"] = "Sale updated successfully";
|
5
|
-
HoldingSaleMessagesEnum["CONFIRM_DELETE"] = "Are you sure you want to delete this holding sale?";
|
6
|
-
HoldingSaleMessagesEnum["DELETED"] = "Sale deleted successfully";
|
7
|
-
})(HoldingSaleMessagesEnum || (HoldingSaleMessagesEnum = {}));
|
8
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaG9sZGluZy1zYWxlLW1lc3NhZ2VzLmVudW0uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy90dC1jb3JlL3NyYy9saWIvc2VydmljZXMvaHR0cC9ob2xkaW5nL2hvbGRpbmctc2FsZS1tZXNzYWdlcy5lbnVtLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE1BQU0sQ0FBTixJQUFZLHVCQUtYO0FBTEQsV0FBWSx1QkFBdUI7SUFDakMsZ0VBQXFDLENBQUE7SUFDckMsZ0VBQXFDLENBQUE7SUFDckMsZ0dBQXFFLENBQUE7SUFDckUsZ0VBQXFDLENBQUE7QUFDdkMsQ0FBQyxFQUxXLHVCQUF1QixLQUF2Qix1QkFBdUIsUUFLbEMiLCJzb3VyY2VzQ29udGVudCI6WyJleHBvcnQgZW51bSBIb2xkaW5nU2FsZU1lc3NhZ2VzRW51bSB7XG4gIENSRUFURUQgPSAnSG9sZGluZyBzb2xkIHN1Y2Nlc3NmdWxseScsXG4gIFVQREFURUQgPSAnU2FsZSB1cGRhdGVkIHN1Y2Nlc3NmdWxseScsXG4gIENPTkZJUk1fREVMRVRFID0gJ0FyZSB5b3Ugc3VyZSB5b3Ugd2FudCB0byBkZWxldGUgdGhpcyBob2xkaW5nIHNhbGU/JyxcbiAgREVMRVRFRCA9ICdTYWxlIGRlbGV0ZWQgc3VjY2Vzc2Z1bGx5Jyxcbn1cbiJdfQ==
|
@@ -1,44 +0,0 @@
|
|
1
|
-
import { Inject, Injectable } from '@angular/core';
|
2
|
-
import { AppEventTypeEnum, Holding, HoldingSale } from '../../../models';
|
3
|
-
import { RestService } from '../rest';
|
4
|
-
import { HoldingCollection } from '../../../collections';
|
5
|
-
import { UserRolesEnum } from 'taxtank-core/common';
|
6
|
-
import { HoldingImport } from '../../../models';
|
7
|
-
import { UserEventTypeTypeEnum } from '../../../db/Enums/user-event-type-type.enum';
|
8
|
-
import * as i0 from "@angular/core";
|
9
|
-
export class HoldingService extends RestService {
|
10
|
-
constructor(environment) {
|
11
|
-
super(environment);
|
12
|
-
this.environment = environment;
|
13
|
-
this.modelClass = Holding;
|
14
|
-
this.collectionClass = HoldingCollection;
|
15
|
-
this.endpointUri = 'holdings';
|
16
|
-
this.disabledMethods = ['postBatch', 'putBatch', 'deleteBatch'];
|
17
|
-
this.roles = [UserRolesEnum.HOLDING_TANK];
|
18
|
-
this.listenEvents();
|
19
|
-
this.listenNotifications();
|
20
|
-
}
|
21
|
-
listenEvents() {
|
22
|
-
this.listenCSE(HoldingSale, this.refreshCache, ['post', 'put', 'delete']);
|
23
|
-
this.listenCSE(HoldingImport, this.refreshCache, ['post', 'put', 'delete']);
|
24
|
-
}
|
25
|
-
listenNotifications() {
|
26
|
-
this.eventDispatcherService.on(AppEventTypeEnum.NOTIFICATION_ADDED).subscribe((notification) => {
|
27
|
-
if (!notification.isRead && notification.eventType === UserEventTypeTypeEnum.SHARESIGHT_IMPORT) {
|
28
|
-
this.refreshCache();
|
29
|
-
}
|
30
|
-
});
|
31
|
-
}
|
32
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: HoldingService, deps: [{ token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
33
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: HoldingService, providedIn: 'root' }); }
|
34
|
-
}
|
35
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: HoldingService, decorators: [{
|
36
|
-
type: Injectable,
|
37
|
-
args: [{
|
38
|
-
providedIn: 'root'
|
39
|
-
}]
|
40
|
-
}], ctorParameters: () => [{ type: undefined, decorators: [{
|
41
|
-
type: Inject,
|
42
|
-
args: ['environment']
|
43
|
-
}] }] });
|
44
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaG9sZGluZy5zZXJ2aWNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvdHQtY29yZS9zcmMvbGliL3NlcnZpY2VzL2h0dHAvaG9sZGluZy9ob2xkaW5nLnNlcnZpY2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLE1BQU0sRUFBRSxVQUFVLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFFbkQsT0FBTyxFQUFFLGdCQUFnQixFQUFFLE9BQU8sRUFBRSxXQUFXLEVBQWdCLE1BQU0saUJBQWlCLENBQUM7QUFDdkYsT0FBTyxFQUFjLFdBQVcsRUFBRSxNQUFNLFNBQVMsQ0FBQztBQUNsRCxPQUFPLEVBQUUsaUJBQWlCLEVBQUUsTUFBTSxzQkFBc0IsQ0FBQztBQUV6RCxPQUFPLEVBQUUsYUFBYSxFQUFFLE1BQU0scUJBQXFCLENBQUM7QUFDcEQsT0FBTyxFQUFFLGFBQWEsRUFBRSxNQUFNLGlCQUFp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ddKTtcbiAgfVxuXG4gIHByaXZhdGUgbGlzdGVuTm90aWZpY2F0aW9ucygpOiB2b2lkIHtcbiAgICB0aGlzLmV2ZW50RGlzcGF0Y2hlclNlcnZpY2Uub24oQXBwRXZlbnRUeXBlRW51bS5OT1RJRklDQVRJT05fQURERUQpLnN1YnNjcmliZSgobm90aWZpY2F0aW9uOiBOb3RpZmljYXRpb24pOiB2b2lkID0+IHtcbiAgICAgIGlmICghbm90aWZpY2F0aW9uLmlzUmVhZCAmJiBub3RpZmljYXRpb24uZXZlbnRUeXBlID09PSBVc2VyRXZlbnRUeXBlVHlwZUVudW0uU0hBUkVTSUdIVF9JTVBPUlQpIHtcbiAgICAgICAgdGhpcy5yZWZyZXNoQ2FjaGUoKTtcbiAgICAgIH1cbiAgICB9KTtcbiAgfVxufVxuIl19
|
@@ -1,8 +0,0 @@
|
|
1
|
-
import { AbstractForm } from '../abstract.form';
|
2
|
-
import { IEventListener } from '../../interfaces';
|
3
|
-
import { HoldingImport } from '../../models';
|
4
|
-
export declare class HoldingImportForm extends AbstractForm<HoldingImport> implements IEventListener {
|
5
|
-
constructor();
|
6
|
-
listenEvents(): void;
|
7
|
-
submit(): HoldingImport;
|
8
|
-
}
|
@@ -1,8 +0,0 @@
|
|
1
|
-
import { Holding } from '../../models';
|
2
|
-
import { AbstractForm } from '../abstract.form';
|
3
|
-
import { IEventListener } from '../../interfaces';
|
4
|
-
export declare class HoldingForm extends AbstractForm<Holding> implements IEventListener {
|
5
|
-
constructor(holding: Holding);
|
6
|
-
listenEvents(): void;
|
7
|
-
submit(data?: object, includeDisabledFields?: boolean): Holding;
|
8
|
-
}
|
@@ -1,17 +0,0 @@
|
|
1
|
-
import { RestMethod, RestService } from '../../rest';
|
2
|
-
import { Collection } from '../../../../collections';
|
3
|
-
import { UserRolesEnum } from 'taxtank-core/common';
|
4
|
-
import { HoldingImport as HoldingImportBase } from '../../../../db/Models/holding/holding-import';
|
5
|
-
import { HoldingImport } from '../../../../models/holding/holding-import';
|
6
|
-
import { Observable } from 'rxjs';
|
7
|
-
import * as i0 from "@angular/core";
|
8
|
-
export declare class HoldingImportService extends RestService<HoldingImportBase, HoldingImport, Collection<HoldingImport>> {
|
9
|
-
modelClass: typeof HoldingImport;
|
10
|
-
collectionClass: typeof Collection<HoldingImport>;
|
11
|
-
endpointUri: string;
|
12
|
-
disabledMethods: RestMethod[];
|
13
|
-
roles: UserRolesEnum[];
|
14
|
-
import(file: File, exchangeId: number, isTaxFree: boolean): Observable<HoldingImport>;
|
15
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<HoldingImportService, never>;
|
16
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<HoldingImportService>;
|
17
|
-
}
|
@@ -1,20 +0,0 @@
|
|
1
|
-
import { Holding as HoldingBase } from '../../../db/Models';
|
2
|
-
import { Holding } from '../../../models';
|
3
|
-
import { RestMethod, RestService } from '../rest';
|
4
|
-
import { HoldingCollection } from '../../../collections';
|
5
|
-
import { IEventListener } from '../../../interfaces';
|
6
|
-
import { UserRolesEnum } from 'taxtank-core/common';
|
7
|
-
import * as i0 from "@angular/core";
|
8
|
-
export declare class HoldingService extends RestService<HoldingBase, Holding, HoldingCollection> implements IEventListener {
|
9
|
-
protected environment: any;
|
10
|
-
modelClass: typeof Holding;
|
11
|
-
collectionClass: typeof HoldingCollection;
|
12
|
-
endpointUri: string;
|
13
|
-
disabledMethods: RestMethod[];
|
14
|
-
roles: UserRolesEnum[];
|
15
|
-
constructor(environment: any);
|
16
|
-
listenEvents(): void;
|
17
|
-
private listenNotifications;
|
18
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<HoldingService, never>;
|
19
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<HoldingService>;
|
20
|
-
}
|