taxtank-core 0.30.29 → 0.30.30
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/esm2020/lib/collections/holding.collection.mjs +28 -0
- package/esm2020/lib/collections/index.mjs +2 -1
- package/esm2020/lib/collections/property/property-sale/property-sale.collection.mjs +3 -3
- package/esm2020/lib/db/Enums/holding/holding-type-category.enum.mjs +1 -1
- package/esm2020/lib/db/Enums/index.mjs +2 -1
- package/esm2020/lib/db/Models/client/annual-client-details.mjs +3 -0
- package/esm2020/lib/db/Models/client/client-details.mjs +4 -0
- package/esm2020/lib/db/Models/client/client-income-types.mjs +4 -0
- package/esm2020/lib/db/Models/client/index.mjs +5 -0
- package/esm2020/lib/db/Models/client/occupation.mjs +4 -0
- package/esm2020/lib/db/Models/index.mjs +2 -4
- package/esm2020/lib/db/Models/property/property-sale/property-sale.mjs +1 -1
- package/esm2020/lib/db/Models/user/user.mjs +1 -1
- package/esm2020/lib/forms/client/annual-client-details.form.mjs +37 -0
- package/esm2020/lib/forms/client/index.mjs +3 -0
- package/esm2020/lib/forms/holding/holding-sale.form.mjs +39 -0
- package/esm2020/lib/forms/holding/holding-type.form.mjs +16 -0
- package/esm2020/lib/forms/holding/holding.form.mjs +17 -0
- package/esm2020/lib/forms/holding/index.mjs +4 -0
- package/esm2020/lib/forms/index.mjs +3 -2
- package/esm2020/lib/forms/property/property-sale/property-sale-cost-sale.form.mjs +11 -25
- package/esm2020/lib/forms/property/property-sale/property-sale-exemptions.form.mjs +18 -7
- package/esm2020/lib/forms/report/my-tax/my-tax-cgt.form.mjs +4 -1
- package/esm2020/lib/messages/index.mjs +2 -0
- package/esm2020/lib/messages/messages.enum.mjs +16 -0
- package/esm2020/lib/models/client/annual-client-details.mjs +15 -0
- package/esm2020/lib/models/client/client-details.mjs +2 -2
- package/esm2020/lib/models/client/client-income-types.mjs +2 -2
- package/esm2020/lib/models/client/index.mjs +8 -0
- package/esm2020/lib/models/endpoint/endpoints.const.mjs +17 -1
- package/esm2020/lib/models/holding/holding-sale.mjs +18 -1
- package/esm2020/lib/models/holding/holding-type-exchange.mjs +13 -0
- package/esm2020/lib/models/holding/holding-type.mjs +37 -1
- package/esm2020/lib/models/holding/holding.mjs +32 -1
- package/esm2020/lib/models/index.mjs +2 -1
- package/esm2020/lib/models/property/property-sale/property-sale.mjs +19 -6
- package/esm2020/lib/models/property/property-sale/tax-exemption.mjs +5 -1
- package/esm2020/lib/models/property/property.mjs +38 -18
- package/esm2020/lib/models/report/my-tax/my-tax-cgt/my-tax-cgt.mjs +7 -6
- package/esm2020/lib/models/user/occupation.mjs +2 -2
- package/esm2020/lib/services/http/client/capital-gain/annual-client-details.service.mjs +24 -0
- package/esm2020/lib/services/http/client/index.mjs +3 -0
- package/esm2020/lib/services/http/client/occupation/occupation.service.mjs +45 -0
- package/esm2020/lib/services/http/firm/client-income/client-income-types.service.mjs +1 -1
- package/esm2020/lib/services/http/holding/holding-sale.service.mjs +1 -4
- package/esm2020/lib/services/http/holding/holding-type.service.mjs +1 -4
- package/esm2020/lib/services/http/holding/holding.service.mjs +3 -6
- package/esm2020/lib/services/http/index.mjs +2 -1
- package/esm2020/lib/services/http/user/index.mjs +2 -2
- package/esm2020/lib/services/http/user/user.service.mjs +2 -11
- package/esm2020/public-api.mjs +5 -1
- package/fesm2015/taxtank-core.mjs +559 -254
- package/fesm2015/taxtank-core.mjs.map +1 -1
- package/fesm2020/taxtank-core.mjs +556 -252
- package/fesm2020/taxtank-core.mjs.map +1 -1
- package/lib/collections/holding.collection.d.ts +10 -0
- package/lib/collections/index.d.ts +1 -0
- package/lib/collections/property/property-sale/property-sale.collection.d.ts +1 -1
- package/lib/db/Enums/index.d.ts +1 -0
- package/lib/db/Models/client/annual-client-details.d.ts +12 -0
- package/lib/db/Models/{user → client}/client-details.d.ts +1 -2
- package/lib/db/Models/client/index.d.ts +4 -0
- package/lib/db/Models/index.d.ts +1 -3
- package/lib/db/Models/property/property-sale/property-sale.d.ts +2 -3
- package/lib/db/Models/user/user.d.ts +1 -1
- package/lib/forms/client/annual-client-details.form.d.ts +8 -0
- package/lib/forms/client/index.d.ts +2 -0
- package/lib/forms/holding/holding-sale.form.d.ts +11 -0
- package/lib/forms/holding/holding-type.form.d.ts +5 -0
- package/lib/forms/holding/holding.form.d.ts +5 -0
- package/lib/forms/holding/index.d.ts +3 -0
- package/lib/forms/index.d.ts +2 -1
- package/lib/forms/property/property-sale/property-sale-cost-sale.form.d.ts +1 -3
- package/lib/forms/property/property-sale/property-sale-exemptions.form.d.ts +6 -6
- package/lib/forms/report/my-tax/my-tax-cgt.form.d.ts +4 -1
- package/lib/messages/index.d.ts +1 -0
- package/lib/messages/messages.enum.d.ts +14 -0
- package/lib/models/client/annual-client-details.d.ts +12 -0
- package/lib/models/client/client-details.d.ts +1 -1
- package/lib/models/client/client-income-types.d.ts +1 -1
- package/lib/models/client/index.d.ts +7 -0
- package/lib/models/holding/holding-sale.d.ts +6 -1
- package/lib/models/holding/holding-type-exchange.d.ts +11 -0
- package/lib/models/holding/holding-type.d.ts +31 -8
- package/lib/models/holding/holding.d.ts +16 -1
- package/lib/models/index.d.ts +1 -0
- package/lib/models/property/property-sale/property-sale.d.ts +7 -2
- package/lib/models/property/property-sale/tax-exemption.d.ts +1 -0
- package/lib/models/property/property.d.ts +12 -6
- package/lib/models/report/my-tax/my-tax-cgt/my-tax-cgt.d.ts +2 -2
- package/lib/models/user/occupation.d.ts +1 -1
- package/lib/services/http/client/capital-gain/annual-client-details.service.d.ts +14 -0
- package/lib/services/http/client/index.d.ts +2 -0
- package/lib/services/http/firm/client-income/client-income-types.service.d.ts +1 -1
- package/lib/services/http/holding/holding-sale.service.d.ts +0 -3
- package/lib/services/http/holding/holding-type.service.d.ts +0 -3
- package/lib/services/http/holding/holding.service.d.ts +3 -6
- package/lib/services/http/index.d.ts +1 -0
- package/lib/services/http/user/index.d.ts +1 -1
- package/lib/services/http/user/user.service.d.ts +0 -4
- package/package.json +1 -1
- package/public-api.d.ts +4 -0
- package/esm2020/lib/db/Models/user/client-details.mjs +0 -4
- package/esm2020/lib/db/Models/user/client-income-types.mjs +0 -4
- package/esm2020/lib/db/Models/user/occupation.mjs +0 -4
- package/esm2020/lib/services/http/user/occupation/occupation.service.mjs +0 -45
- /package/lib/db/Models/{user → client}/client-income-types.d.ts +0 -0
- /package/lib/db/Models/{user → client}/occupation.d.ts +0 -0
- /package/lib/services/http/{user → client}/occupation/occupation.service.d.ts +0 -0
|
@@ -657,16 +657,19 @@ let TransactionReceipt$1 = class TransactionReceipt extends AbstractModel {
|
|
|
657
657
|
let Transaction$1 = class Transaction extends TransactionBase {
|
|
658
658
|
};
|
|
659
659
|
|
|
660
|
+
let AnnualClientDetails$1 = class AnnualClientDetails {
|
|
661
|
+
};
|
|
662
|
+
|
|
660
663
|
let ClientDetails$1 = class ClientDetails extends AbstractModel {
|
|
661
664
|
};
|
|
662
665
|
|
|
663
666
|
let ClientIncomeTypes$1 = class ClientIncomeTypes extends ObservableModel {
|
|
664
667
|
};
|
|
665
668
|
|
|
666
|
-
let
|
|
669
|
+
let Occupation$1 = class Occupation extends AbstractModel {
|
|
667
670
|
};
|
|
668
671
|
|
|
669
|
-
let
|
|
672
|
+
let EmployeeDetails$1 = class EmployeeDetails extends AbstractModel {
|
|
670
673
|
};
|
|
671
674
|
|
|
672
675
|
let RegistrationInvite$1 = class RegistrationInvite extends AbstractModel {
|
|
@@ -1631,8 +1634,8 @@ class LoanCollection extends Collection {
|
|
|
1631
1634
|
}
|
|
1632
1635
|
|
|
1633
1636
|
class PropertySaleCollection extends Collection {
|
|
1634
|
-
get
|
|
1635
|
-
return this.create(this.items.filter((propertySale) => propertySale.
|
|
1637
|
+
get grossCapitalGain() {
|
|
1638
|
+
return this.create(this.items.filter((propertySale) => propertySale.grossCapitalGain > 0)).sumBy('grossCapitalGain');
|
|
1636
1639
|
}
|
|
1637
1640
|
/**
|
|
1638
1641
|
* Property sales are CGT applicable unless it has "Principle place of residence" exemption type
|
|
@@ -2163,6 +2166,16 @@ var DocumentTypeEnum;
|
|
|
2163
2166
|
DocumentTypeEnum[DocumentTypeEnum["INVOICE"] = 1] = "INVOICE";
|
|
2164
2167
|
})(DocumentTypeEnum || (DocumentTypeEnum = {}));
|
|
2165
2168
|
|
|
2169
|
+
var HoldingTypeCategoryEnum;
|
|
2170
|
+
(function (HoldingTypeCategoryEnum) {
|
|
2171
|
+
HoldingTypeCategoryEnum[HoldingTypeCategoryEnum["CRYPTO"] = 1] = "CRYPTO";
|
|
2172
|
+
HoldingTypeCategoryEnum[HoldingTypeCategoryEnum["STOCK"] = 2] = "STOCK";
|
|
2173
|
+
HoldingTypeCategoryEnum[HoldingTypeCategoryEnum["UNLISTED_STOCK"] = 3] = "UNLISTED_STOCK";
|
|
2174
|
+
HoldingTypeCategoryEnum[HoldingTypeCategoryEnum["UNLISTED_UNIT"] = 4] = "UNLISTED_UNIT";
|
|
2175
|
+
HoldingTypeCategoryEnum[HoldingTypeCategoryEnum["COLLECTIBLE"] = 5] = "COLLECTIBLE";
|
|
2176
|
+
HoldingTypeCategoryEnum[HoldingTypeCategoryEnum["OTHER"] = 6] = "OTHER";
|
|
2177
|
+
})(HoldingTypeCategoryEnum || (HoldingTypeCategoryEnum = {}));
|
|
2178
|
+
|
|
2166
2179
|
// @TODO Artem TT-2308 move everything
|
|
2167
2180
|
|
|
2168
2181
|
class DepreciationCapitalProject extends DepreciationCapitalProject$1 {
|
|
@@ -3580,6 +3593,12 @@ var TaxExemptionEnum;
|
|
|
3580
3593
|
TaxExemptionEnum[TaxExemptionEnum["OTHER"] = 7] = "OTHER";
|
|
3581
3594
|
})(TaxExemptionEnum || (TaxExemptionEnum = {}));
|
|
3582
3595
|
|
|
3596
|
+
class TaxExemption extends TaxExemption$1 {
|
|
3597
|
+
isPartial() {
|
|
3598
|
+
return [TaxExemptionEnum.INVESTMENT_TO_PPR, TaxExemptionEnum.PPR_TO_INVESTMENT].includes(this.id);
|
|
3599
|
+
}
|
|
3600
|
+
}
|
|
3601
|
+
|
|
3583
3602
|
class PropertySale extends PropertySale$1 {
|
|
3584
3603
|
get saleCostsTotalAmount() {
|
|
3585
3604
|
return this.commission + this.legalFees + this.otherCost;
|
|
@@ -3592,13 +3611,22 @@ class PropertySale extends PropertySale$1 {
|
|
|
3592
3611
|
var _a;
|
|
3593
3612
|
return ((_a = this.taxExemption) === null || _a === void 0 ? void 0 : _a.id) !== TaxExemptionEnum.PPR;
|
|
3594
3613
|
}
|
|
3595
|
-
get
|
|
3596
|
-
return this.
|
|
3597
|
-
}
|
|
3598
|
-
get grossCGTAfterLoss() {
|
|
3599
|
-
return this.grossCGT - this.lossApplied;
|
|
3614
|
+
get netPrice() {
|
|
3615
|
+
return this.price - this.saleCostsTotalAmount;
|
|
3600
3616
|
}
|
|
3601
3617
|
}
|
|
3618
|
+
__decorate([
|
|
3619
|
+
Type(() => Number)
|
|
3620
|
+
], PropertySale.prototype, "holdingCosts", void 0);
|
|
3621
|
+
__decorate([
|
|
3622
|
+
Type(() => Number)
|
|
3623
|
+
], PropertySale.prototype, "structuralImprovementsWDV", void 0);
|
|
3624
|
+
__decorate([
|
|
3625
|
+
Type(() => Number)
|
|
3626
|
+
], PropertySale.prototype, "buildingAtCostClaimed", void 0);
|
|
3627
|
+
__decorate([
|
|
3628
|
+
Type(() => Number)
|
|
3629
|
+
], PropertySale.prototype, "price", void 0);
|
|
3602
3630
|
__decorate([
|
|
3603
3631
|
Type(() => Number)
|
|
3604
3632
|
], PropertySale.prototype, "commission", void 0);
|
|
@@ -3614,6 +3642,9 @@ __decorate([
|
|
|
3614
3642
|
__decorate([
|
|
3615
3643
|
Type(() => Date)
|
|
3616
3644
|
], PropertySale.prototype, "contractDate", void 0);
|
|
3645
|
+
__decorate([
|
|
3646
|
+
Type(() => TaxExemption)
|
|
3647
|
+
], PropertySale.prototype, "taxExemption", void 0);
|
|
3617
3648
|
__decorate([
|
|
3618
3649
|
Type(() => PropertySaleTaxExemptionMetaField$1)
|
|
3619
3650
|
], PropertySale.prototype, "taxExemptionMetaFields", void 0);
|
|
@@ -3638,9 +3669,6 @@ class PropertySaleCostBase {
|
|
|
3638
3669
|
class PropertySaleTaxExemptionMetaField extends PropertySaleTaxExemptionMetaField$1 {
|
|
3639
3670
|
}
|
|
3640
3671
|
|
|
3641
|
-
class TaxExemption extends TaxExemption$1 {
|
|
3642
|
-
}
|
|
3643
|
-
|
|
3644
3672
|
class TaxExemptionMetaField extends TaxExemptionMetaField$1 {
|
|
3645
3673
|
}
|
|
3646
3674
|
|
|
@@ -7050,6 +7078,32 @@ class UserEventSettingCollection extends Collection {
|
|
|
7050
7078
|
class UserEventTypeCollection extends Collection {
|
|
7051
7079
|
}
|
|
7052
7080
|
|
|
7081
|
+
class HoldingCollection extends Collection {
|
|
7082
|
+
getShares() {
|
|
7083
|
+
return this.filterBy('type.category', HoldingTypeCategoryEnum.STOCK);
|
|
7084
|
+
}
|
|
7085
|
+
getCryptos() {
|
|
7086
|
+
return this.filterBy('type.category', HoldingTypeCategoryEnum.CRYPTO);
|
|
7087
|
+
}
|
|
7088
|
+
getOthers() {
|
|
7089
|
+
return this.filterBy('type.category', [
|
|
7090
|
+
HoldingTypeCategoryEnum.COLLECTIBLE,
|
|
7091
|
+
HoldingTypeCategoryEnum.UNLISTED_STOCK,
|
|
7092
|
+
HoldingTypeCategoryEnum.UNLISTED_UNIT,
|
|
7093
|
+
HoldingTypeCategoryEnum.OTHER
|
|
7094
|
+
]);
|
|
7095
|
+
}
|
|
7096
|
+
getPurchaseValue() {
|
|
7097
|
+
return this.sumBy('purchaseValue');
|
|
7098
|
+
}
|
|
7099
|
+
getMarketValue(holdingTypesById) {
|
|
7100
|
+
return this.items.reduce((sum, holding) => sum + holding.getMarketValue(holdingTypesById.get(holding.type.id)), 0);
|
|
7101
|
+
}
|
|
7102
|
+
getGrowthCoefficient(holdingTypesById) {
|
|
7103
|
+
return this.getMarketValue(holdingTypesById) / this.getPurchaseValue() - 1;
|
|
7104
|
+
}
|
|
7105
|
+
}
|
|
7106
|
+
|
|
7053
7107
|
// @TODO Alex move here all collections
|
|
7054
7108
|
|
|
7055
7109
|
class ServiceSubscription extends ServiceSubscription$1 {
|
|
@@ -7442,17 +7496,14 @@ class Property extends Property$1 {
|
|
|
7442
7496
|
}
|
|
7443
7497
|
return this.purchasePrice + this.capitalCostsTotalAmount + sale.holdingCosts + sale.structuralImprovementsWDV - sale.buildingAtCostClaimed;
|
|
7444
7498
|
}
|
|
7445
|
-
|
|
7446
|
-
|
|
7447
|
-
*/
|
|
7448
|
-
calculateGrossCGT(sale) {
|
|
7449
|
-
return (sale.price - sale.saleCostsTotalAmount - this.calculateCostBase(sale)) * this.shareRatio;
|
|
7499
|
+
calculateGrossCapitalGain(sale) {
|
|
7500
|
+
return (sale.netPrice - this.calculateCostBase(sale)) * this.getPartialCGTExemptionRatio(sale) * this.shareRatio;
|
|
7450
7501
|
}
|
|
7451
7502
|
/**
|
|
7452
|
-
* net capital gain
|
|
7503
|
+
* net capital gain includes tax exemption
|
|
7453
7504
|
*/
|
|
7454
|
-
|
|
7455
|
-
return this.getCGTExemptionRatio(sale) * sale.
|
|
7505
|
+
calculateNetCapitalGain(sale) {
|
|
7506
|
+
return this.getCGTExemptionRatio(sale) * sale.grossCapitalGain;
|
|
7456
7507
|
}
|
|
7457
7508
|
/**
|
|
7458
7509
|
* guess tax exemption based on property details
|
|
@@ -7472,25 +7523,31 @@ class Property extends Property$1 {
|
|
|
7472
7523
|
return null;
|
|
7473
7524
|
}
|
|
7474
7525
|
}
|
|
7526
|
+
getPartialCGTExemptionRatio(sale) {
|
|
7527
|
+
var _a;
|
|
7528
|
+
const metaFields = new PropertySaleTaxExemptionMetaFieldCollection(sale.taxExemptionMetaFields);
|
|
7529
|
+
switch ((_a = sale.taxExemption) === null || _a === void 0 ? void 0 : _a.id) {
|
|
7530
|
+
case TaxExemptionEnum.INVESTMENT_TO_PPR:
|
|
7531
|
+
const ownershipDays = this.getOwnershipDuration(sale);
|
|
7532
|
+
return (ownershipDays - metaFields.getPPRDays()) / ownershipDays;
|
|
7533
|
+
case TaxExemptionEnum.PPR_TO_INVESTMENT:
|
|
7534
|
+
return metaFields.getClaimPercent() / 100;
|
|
7535
|
+
default:
|
|
7536
|
+
return 1;
|
|
7537
|
+
}
|
|
7538
|
+
}
|
|
7475
7539
|
/**
|
|
7476
7540
|
* tax exemption can reduce cgt from 100% to less (up to zero)
|
|
7477
7541
|
*/
|
|
7478
7542
|
getCGTExemptionRatio(sale) {
|
|
7479
7543
|
var _a;
|
|
7480
|
-
const metaFields = new PropertySaleTaxExemptionMetaFieldCollection(sale.taxExemptionMetaFields);
|
|
7481
7544
|
switch ((_a = sale.taxExemption) === null || _a === void 0 ? void 0 : _a.id) {
|
|
7482
7545
|
// 50% exemption for investments owned for at least one year
|
|
7483
7546
|
case TaxExemptionEnum.ONE_YEAR_RULE:
|
|
7484
7547
|
return 0.5;
|
|
7485
|
-
// investment property become main residence (exemption for main residence ownership duration)
|
|
7486
7548
|
case TaxExemptionEnum.INVESTMENT_TO_PPR:
|
|
7487
|
-
const ownershipDays = this.getOwnershipDuration(sale);
|
|
7488
|
-
return (ownershipDays - metaFields.getPPRDays()) / ownershipDays;
|
|
7489
|
-
// main residence become investment (exemption for home office percent usage)
|
|
7490
7549
|
case TaxExemptionEnum.PPR_TO_INVESTMENT:
|
|
7491
|
-
|
|
7492
|
-
const ratio = this.isOneYearExemptionApplicable(sale) ? 0.5 : 1;
|
|
7493
|
-
return metaFields.getClaimPercent() / 100 * ratio;
|
|
7550
|
+
return this.isOneYearExemptionApplicable(sale) ? 0.5 : 1;
|
|
7494
7551
|
// full exemption
|
|
7495
7552
|
case TaxExemptionEnum.PPR:
|
|
7496
7553
|
case TaxExemptionEnum.SIX_YEARS_RULE:
|
|
@@ -7502,8 +7559,11 @@ class Property extends Property$1 {
|
|
|
7502
7559
|
return 1;
|
|
7503
7560
|
}
|
|
7504
7561
|
}
|
|
7562
|
+
/**
|
|
7563
|
+
* in cgt report we apply losses, which can reset 1 year rule (in case if there is no profit after loss)
|
|
7564
|
+
*/
|
|
7505
7565
|
isOneYearExemptionApplicable(sale) {
|
|
7506
|
-
return sale.
|
|
7566
|
+
return sale.grossCapitalGain > 0 && this.getOwnershipDuration(sale, 'years') > 0;
|
|
7507
7567
|
}
|
|
7508
7568
|
/**
|
|
7509
7569
|
* CGT is not applicable for properties acquired before 20.09.1985 (tax didn't exist before this date).
|
|
@@ -7532,6 +7592,12 @@ class Property extends Property$1 {
|
|
|
7532
7592
|
* Any assets acquired before this day are CGT exempt (because the tax didn't exist before this date).
|
|
7533
7593
|
*/
|
|
7534
7594
|
Property.preCGTAssetDate = new Date(1985, 9, 20);
|
|
7595
|
+
__decorate([
|
|
7596
|
+
Type(() => Number)
|
|
7597
|
+
], Property.prototype, "purchasePrice", void 0);
|
|
7598
|
+
__decorate([
|
|
7599
|
+
Type(() => Number)
|
|
7600
|
+
], Property.prototype, "growthPercent", void 0);
|
|
7535
7601
|
__decorate([
|
|
7536
7602
|
Type(() => Date)
|
|
7537
7603
|
], Property.prototype, "contractDate", void 0);
|
|
@@ -7544,6 +7610,15 @@ __decorate([
|
|
|
7544
7610
|
__decorate([
|
|
7545
7611
|
Type(() => PropertyCategory)
|
|
7546
7612
|
], Property.prototype, "category", void 0);
|
|
7613
|
+
__decorate([
|
|
7614
|
+
Type(() => Number)
|
|
7615
|
+
], Property.prototype, "stampDuty", void 0);
|
|
7616
|
+
__decorate([
|
|
7617
|
+
Type(() => Number)
|
|
7618
|
+
], Property.prototype, "legalFees", void 0);
|
|
7619
|
+
__decorate([
|
|
7620
|
+
Type(() => Number)
|
|
7621
|
+
], Property.prototype, "otherCapitalCosts", void 0);
|
|
7547
7622
|
__decorate([
|
|
7548
7623
|
Type(() => PropertyValuation)
|
|
7549
7624
|
], Property.prototype, "valuations", void 0);
|
|
@@ -8302,19 +8377,109 @@ __decorate([
|
|
|
8302
8377
|
Type(() => Document)
|
|
8303
8378
|
], DocumentFolder.prototype, "documents", void 0);
|
|
8304
8379
|
|
|
8380
|
+
class HoldingTypeExchange extends AbstractModel {
|
|
8381
|
+
}
|
|
8382
|
+
__decorate([
|
|
8383
|
+
Type(() => Date)
|
|
8384
|
+
], HoldingTypeExchange.prototype, "updateDate", void 0);
|
|
8385
|
+
__decorate([
|
|
8386
|
+
Type(() => HoldingType)
|
|
8387
|
+
], HoldingTypeExchange.prototype, "holdingTypes", void 0);
|
|
8388
|
+
|
|
8305
8389
|
class HoldingType extends AbstractModel {
|
|
8390
|
+
get categoryLabel() {
|
|
8391
|
+
switch (this.category) {
|
|
8392
|
+
case HoldingTypeCategoryEnum.STOCK:
|
|
8393
|
+
return 'Shares';
|
|
8394
|
+
case HoldingTypeCategoryEnum.CRYPTO:
|
|
8395
|
+
return 'Cryptos';
|
|
8396
|
+
case HoldingTypeCategoryEnum.COLLECTIBLE:
|
|
8397
|
+
return 'Collectibles';
|
|
8398
|
+
case HoldingTypeCategoryEnum.UNLISTED_STOCK:
|
|
8399
|
+
return 'Unlisted stock';
|
|
8400
|
+
case HoldingTypeCategoryEnum.UNLISTED_UNIT:
|
|
8401
|
+
return 'Unlisted unit';
|
|
8402
|
+
case HoldingTypeCategoryEnum.OTHER:
|
|
8403
|
+
return 'Other';
|
|
8404
|
+
}
|
|
8405
|
+
}
|
|
8406
|
+
isOther() {
|
|
8407
|
+
return !this.isShare() && !this.isCrypto();
|
|
8408
|
+
}
|
|
8409
|
+
isShare() {
|
|
8410
|
+
return this.category === HoldingTypeCategoryEnum.STOCK;
|
|
8411
|
+
}
|
|
8412
|
+
isCrypto() {
|
|
8413
|
+
return this.category === HoldingTypeCategoryEnum.CRYPTO;
|
|
8414
|
+
}
|
|
8306
8415
|
}
|
|
8416
|
+
__decorate([
|
|
8417
|
+
Type(() => Date)
|
|
8418
|
+
], HoldingType.prototype, "lastUpdateDateOnExchange", void 0);
|
|
8419
|
+
__decorate([
|
|
8420
|
+
Type(() => Date)
|
|
8421
|
+
], HoldingType.prototype, "updatedAt", void 0);
|
|
8307
8422
|
__decorate([
|
|
8308
8423
|
Type(() => User)
|
|
8309
8424
|
], HoldingType.prototype, "user", void 0);
|
|
8425
|
+
__decorate([
|
|
8426
|
+
Type(() => HoldingTypeExchange)
|
|
8427
|
+
], HoldingType.prototype, "exchange", void 0);
|
|
8310
8428
|
|
|
8311
8429
|
class HoldingSale extends AbstractModel {
|
|
8430
|
+
getCapitalGain(holding) {
|
|
8431
|
+
if (!this.price || !this.holding) {
|
|
8432
|
+
return 0;
|
|
8433
|
+
}
|
|
8434
|
+
return (this.price - holding.price) * this.quantity;
|
|
8435
|
+
}
|
|
8436
|
+
getNetCapitalGain(holding) {
|
|
8437
|
+
const capitalGain = this.getCapitalGain(holding);
|
|
8438
|
+
// 50% discount for holdings purchased over a year ago
|
|
8439
|
+
if (holding.heldMoreYear()) {
|
|
8440
|
+
return capitalGain / 2;
|
|
8441
|
+
}
|
|
8442
|
+
return capitalGain;
|
|
8443
|
+
}
|
|
8312
8444
|
}
|
|
8445
|
+
__decorate([
|
|
8446
|
+
Type(() => Date)
|
|
8447
|
+
], HoldingSale.prototype, "date", void 0);
|
|
8313
8448
|
__decorate([
|
|
8314
8449
|
Type(() => AppFile)
|
|
8315
8450
|
], HoldingSale.prototype, "file", void 0);
|
|
8316
8451
|
|
|
8317
8452
|
class Holding extends AbstractModel {
|
|
8453
|
+
constructor() {
|
|
8454
|
+
super(...arguments);
|
|
8455
|
+
this.isTaxFree = false;
|
|
8456
|
+
}
|
|
8457
|
+
/**
|
|
8458
|
+
* Get total purchasing price
|
|
8459
|
+
*/
|
|
8460
|
+
get purchaseValue() {
|
|
8461
|
+
// Price and entity may be empty when we use HoldingForm.currentValue
|
|
8462
|
+
if (!this.price || !this.quantity) {
|
|
8463
|
+
return 0;
|
|
8464
|
+
}
|
|
8465
|
+
return this.price * this.quantity;
|
|
8466
|
+
}
|
|
8467
|
+
/**
|
|
8468
|
+
* Get current market price
|
|
8469
|
+
*/
|
|
8470
|
+
getMarketValue(holdingType) {
|
|
8471
|
+
return this.quantity * holdingType.price;
|
|
8472
|
+
}
|
|
8473
|
+
/**
|
|
8474
|
+
* Get percent difference between current and buy price
|
|
8475
|
+
*/
|
|
8476
|
+
getGrowthCoefficient(holdingType) {
|
|
8477
|
+
return holdingType.price / this.price - 1;
|
|
8478
|
+
}
|
|
8479
|
+
heldMoreYear() {
|
|
8480
|
+
const yearTime = 1000 * 60 * 60 * 24 * 365;
|
|
8481
|
+
return (new FinancialYear().startDate.getTime() - this.date.getTime()) > yearTime;
|
|
8482
|
+
}
|
|
8318
8483
|
}
|
|
8319
8484
|
__decorate([
|
|
8320
8485
|
Type(() => Date)
|
|
@@ -8333,6 +8498,178 @@ __decorate([
|
|
|
8333
8498
|
Transform(({ value }) => new Collection(value))
|
|
8334
8499
|
], Holding.prototype, "sales", void 0);
|
|
8335
8500
|
|
|
8501
|
+
class AnnualClientDetails extends AbstractModel {
|
|
8502
|
+
constructor() {
|
|
8503
|
+
super(...arguments);
|
|
8504
|
+
this.financialYear = new FinancialYear().year;
|
|
8505
|
+
}
|
|
8506
|
+
}
|
|
8507
|
+
__decorate([
|
|
8508
|
+
Type(() => ClientDetails)
|
|
8509
|
+
], AnnualClientDetails.prototype, "clientDetails", void 0);
|
|
8510
|
+
|
|
8511
|
+
class ClientIncomeTypes extends ClientIncomeTypes$1 {
|
|
8512
|
+
/**
|
|
8513
|
+
* Get count of selected income types
|
|
8514
|
+
*/
|
|
8515
|
+
get length() {
|
|
8516
|
+
return Object.values(this).filter((value) => typeof value === 'boolean' && value).length;
|
|
8517
|
+
}
|
|
8518
|
+
}
|
|
8519
|
+
|
|
8520
|
+
var ClientInviteStatusEnum;
|
|
8521
|
+
(function (ClientInviteStatusEnum) {
|
|
8522
|
+
ClientInviteStatusEnum[ClientInviteStatusEnum["PENDING"] = 1] = "PENDING";
|
|
8523
|
+
ClientInviteStatusEnum[ClientInviteStatusEnum["REJECTED"] = 2] = "REJECTED";
|
|
8524
|
+
})(ClientInviteStatusEnum || (ClientInviteStatusEnum = {}));
|
|
8525
|
+
|
|
8526
|
+
var ClientInviteTypeEnum;
|
|
8527
|
+
(function (ClientInviteTypeEnum) {
|
|
8528
|
+
ClientInviteTypeEnum[ClientInviteTypeEnum["FROM_CLIENT"] = 1] = "FROM_CLIENT";
|
|
8529
|
+
ClientInviteTypeEnum[ClientInviteTypeEnum["FROM_EMPLOYEE"] = 2] = "FROM_EMPLOYEE";
|
|
8530
|
+
})(ClientInviteTypeEnum || (ClientInviteTypeEnum = {}));
|
|
8531
|
+
|
|
8532
|
+
class ClientInvite extends ClientInvite$1 {
|
|
8533
|
+
/**
|
|
8534
|
+
* Check if client invite status is pending
|
|
8535
|
+
*/
|
|
8536
|
+
isPending() {
|
|
8537
|
+
return this.status === ClientInviteStatusEnum.PENDING;
|
|
8538
|
+
}
|
|
8539
|
+
/**
|
|
8540
|
+
* Check if client invite status is accepted
|
|
8541
|
+
*/
|
|
8542
|
+
isAccepted() {
|
|
8543
|
+
return !this.isPending() && !this.isRejected();
|
|
8544
|
+
}
|
|
8545
|
+
/**
|
|
8546
|
+
* Check if client invite status is rejected
|
|
8547
|
+
*/
|
|
8548
|
+
isRejected() {
|
|
8549
|
+
return this.status === ClientInviteStatusEnum.REJECTED;
|
|
8550
|
+
}
|
|
8551
|
+
/**
|
|
8552
|
+
* Check if client invite initiated by firm
|
|
8553
|
+
*/
|
|
8554
|
+
isFromEmployee() {
|
|
8555
|
+
return this.type === ClientInviteTypeEnum.FROM_EMPLOYEE;
|
|
8556
|
+
}
|
|
8557
|
+
/**
|
|
8558
|
+
* Check if client invite initiated by client
|
|
8559
|
+
*/
|
|
8560
|
+
isFromClient() {
|
|
8561
|
+
return this.type === ClientInviteTypeEnum.FROM_CLIENT;
|
|
8562
|
+
}
|
|
8563
|
+
get firstName() {
|
|
8564
|
+
var _a;
|
|
8565
|
+
return this.client ? this.client.firstName : (_a = this.registrationInvite) === null || _a === void 0 ? void 0 : _a.firstName;
|
|
8566
|
+
}
|
|
8567
|
+
get email() {
|
|
8568
|
+
var _a;
|
|
8569
|
+
return this.client ? this.client.email : (_a = this.registrationInvite) === null || _a === void 0 ? void 0 : _a.email;
|
|
8570
|
+
}
|
|
8571
|
+
}
|
|
8572
|
+
__decorate([
|
|
8573
|
+
Type(() => Date)
|
|
8574
|
+
], ClientInvite.prototype, "sentOn", void 0);
|
|
8575
|
+
__decorate([
|
|
8576
|
+
Type(() => Date)
|
|
8577
|
+
], ClientInvite.prototype, "updatedAt", void 0);
|
|
8578
|
+
__decorate([
|
|
8579
|
+
Type(() => Firm)
|
|
8580
|
+
], ClientInvite.prototype, "firm", void 0);
|
|
8581
|
+
__decorate([
|
|
8582
|
+
Type(() => User)
|
|
8583
|
+
], ClientInvite.prototype, "client", void 0);
|
|
8584
|
+
__decorate([
|
|
8585
|
+
Type(() => User)
|
|
8586
|
+
], ClientInvite.prototype, "employee", void 0);
|
|
8587
|
+
__decorate([
|
|
8588
|
+
Type(() => RegistrationInvite)
|
|
8589
|
+
], ClientInvite.prototype, "registrationInvite", void 0);
|
|
8590
|
+
|
|
8591
|
+
class ClientMovement extends ClientMovement$1 {
|
|
8592
|
+
}
|
|
8593
|
+
__decorate([
|
|
8594
|
+
Type(() => Firm)
|
|
8595
|
+
], ClientMovement.prototype, "firm", void 0);
|
|
8596
|
+
__decorate([
|
|
8597
|
+
Type(() => User)
|
|
8598
|
+
], ClientMovement.prototype, "client", void 0);
|
|
8599
|
+
__decorate([
|
|
8600
|
+
Type(() => User)
|
|
8601
|
+
], ClientMovement.prototype, "employee", void 0);
|
|
8602
|
+
__decorate([
|
|
8603
|
+
Type(() => ServiceSubscription)
|
|
8604
|
+
], ClientMovement.prototype, "subscription", void 0);
|
|
8605
|
+
__decorate([
|
|
8606
|
+
Type(() => Date)
|
|
8607
|
+
], ClientMovement.prototype, "dateFrom", void 0);
|
|
8608
|
+
__decorate([
|
|
8609
|
+
Type(() => Date)
|
|
8610
|
+
], ClientMovement.prototype, "dateTo", void 0);
|
|
8611
|
+
|
|
8612
|
+
/**
|
|
8613
|
+
* Client portfolio charts data based on ClientPortfolioReportCollection
|
|
8614
|
+
*/
|
|
8615
|
+
class ClientPortfolioChartData {
|
|
8616
|
+
constructor(clientsPortfolioReportCollection) {
|
|
8617
|
+
this.clientsPortfolioReportCollection = clientsPortfolioReportCollection;
|
|
8618
|
+
}
|
|
8619
|
+
getPieChartData() {
|
|
8620
|
+
return this.clientsPortfolioReportCollection.items.map((clientPortfolioReport) => {
|
|
8621
|
+
return plainToClass(ChartData, {
|
|
8622
|
+
name: clientPortfolioReport.category,
|
|
8623
|
+
data: clientPortfolioReport.count
|
|
8624
|
+
});
|
|
8625
|
+
});
|
|
8626
|
+
}
|
|
8627
|
+
getBarChartData() {
|
|
8628
|
+
return [
|
|
8629
|
+
plainToClass(ChartData, {
|
|
8630
|
+
name: 'Total',
|
|
8631
|
+
data: [
|
|
8632
|
+
{
|
|
8633
|
+
label: 'Market value',
|
|
8634
|
+
value: this.clientsPortfolioReportCollection.marketValue
|
|
8635
|
+
},
|
|
8636
|
+
{
|
|
8637
|
+
label: 'Loan balance',
|
|
8638
|
+
value: this.clientsPortfolioReportCollection.loanBalance
|
|
8639
|
+
},
|
|
8640
|
+
{
|
|
8641
|
+
label: 'Equity position',
|
|
8642
|
+
value: this.clientsPortfolioReportCollection.equityPosition
|
|
8643
|
+
}
|
|
8644
|
+
]
|
|
8645
|
+
}),
|
|
8646
|
+
plainToClass(ChartData, {
|
|
8647
|
+
name: 'Average',
|
|
8648
|
+
data: [
|
|
8649
|
+
{
|
|
8650
|
+
label: 'Market value',
|
|
8651
|
+
value: this.clientsPortfolioReportCollection.averageMarketValue
|
|
8652
|
+
},
|
|
8653
|
+
{
|
|
8654
|
+
label: 'Loan balance',
|
|
8655
|
+
value: this.clientsPortfolioReportCollection.averageLoanBalance
|
|
8656
|
+
},
|
|
8657
|
+
{
|
|
8658
|
+
label: 'Equity position',
|
|
8659
|
+
value: this.clientsPortfolioReportCollection.averageEquityPosition
|
|
8660
|
+
}
|
|
8661
|
+
]
|
|
8662
|
+
})
|
|
8663
|
+
];
|
|
8664
|
+
}
|
|
8665
|
+
}
|
|
8666
|
+
|
|
8667
|
+
/**
|
|
8668
|
+
* Class describes client's portfolio report information
|
|
8669
|
+
*/
|
|
8670
|
+
class ClientPortfolioReport extends AbstractModel {
|
|
8671
|
+
}
|
|
8672
|
+
|
|
8336
8673
|
const NAME_TOKEN = 'token';
|
|
8337
8674
|
const NAME_REFRESH_TOKEN = 'refreshToken';
|
|
8338
8675
|
class JwtService extends JwtHelperService {
|
|
@@ -8748,6 +9085,10 @@ const ENDPOINTS = {
|
|
|
8748
9085
|
CLIENT_INCOME_TYPES_POST: new Endpoint('POST', '\\/client-income-types'),
|
|
8749
9086
|
COUNTRIES_GET: new Endpoint('GET', '\\/countries'),
|
|
8750
9087
|
CORELOGIC_TOKEN_GET: new Endpoint('GET', '/access\\/oauth\\/token.*$'),
|
|
9088
|
+
ANNUAL_CLIENT_DETAILS_GET: new Endpoint('GET', '\\/annual-client-details'),
|
|
9089
|
+
ANNUAL_CLIENT_DETAILS_POST: new Endpoint('POST', '\\/annual-client-details'),
|
|
9090
|
+
ANNUAL_CLIENT_DETAILS_PUT: new Endpoint('PUT', '\\/annual-client-details\\/\\d+'),
|
|
9091
|
+
ANNUAL_CLIENT_DETAILS_DELETE: new Endpoint('DELETE', '\\/annual-client-details\\/\\d+'),
|
|
8751
9092
|
DEPRECIATIONS_OPENING_GET: new Endpoint('GET', '\\/depreciations\\/\\opening-balance\.\*'),
|
|
8752
9093
|
DEPRECIATIONS_GET: new Endpoint('GET', '\\/depreciations'),
|
|
8753
9094
|
DEPRECIATIONS_POST: new Endpoint('POST', '\\/depreciations'),
|
|
@@ -8790,6 +9131,18 @@ const ENDPOINTS = {
|
|
|
8790
9131
|
LOANS_PAYOUT_DELETE: new Endpoint('DELETE', '\\/loans\\/\\d+\\/payout\\/\\d+'),
|
|
8791
9132
|
LOANS_CALCULATION_POST: new Endpoint('POST', '\\/bank-accounts\\/loans\\/calculation'),
|
|
8792
9133
|
LOGIN_POST: new Endpoint('POST', '\\/login'),
|
|
9134
|
+
HOLDINGS_GET: new Endpoint('GET', '\\/holdings'),
|
|
9135
|
+
HOLDINGS_POST: new Endpoint('POST', '\\/holdings'),
|
|
9136
|
+
HOLDINGS_PUT: new Endpoint('PUT', '\\/holdings\\/\\d+'),
|
|
9137
|
+
HOLDINGS_DELETE: new Endpoint('DELETE', '\\/holdings\\/\\d+'),
|
|
9138
|
+
HOLDING_TYPES_GET: new Endpoint('GET', '\\/holding-types'),
|
|
9139
|
+
HOLDING_TYPES_POST: new Endpoint('POST', '\\/holding-types'),
|
|
9140
|
+
HOLDING_TYPES_PUT: new Endpoint('PUT', '\\/holding-types\\/\\d+'),
|
|
9141
|
+
HOLDING_TYPES_DELETE: new Endpoint('DELETE', '\\/holding-types\\/\\d+'),
|
|
9142
|
+
HOLDING_SALES_GET: new Endpoint('GET', '\\/holding-sales'),
|
|
9143
|
+
HOLDING_SALES_POST: new Endpoint('POST', '\\/holding-sales'),
|
|
9144
|
+
HOLDING_SALES_PUT: new Endpoint('PUT', '\\/holding-sales\\/\\d+'),
|
|
9145
|
+
HOLDING_SALES_DELETE: new Endpoint('DELETE', '\\/holding-sales\\/\\d+'),
|
|
8793
9146
|
NOTIFICATIONS_GET: new Endpoint('GET', '\\/service-notifications'),
|
|
8794
9147
|
OCCUPATIONS_GET: new Endpoint('GET', '\\/occupations'),
|
|
8795
9148
|
PROPERTIES_GET: new Endpoint('GET', '\\/properties'),
|
|
@@ -9661,7 +10014,6 @@ class UserService {
|
|
|
9661
10014
|
}
|
|
9662
10015
|
listenEvents() {
|
|
9663
10016
|
this.listenServiceSubscriptionUpdated();
|
|
9664
|
-
this.listenPropertySale();
|
|
9665
10017
|
}
|
|
9666
10018
|
get() {
|
|
9667
10019
|
if (!this.cache) {
|
|
@@ -9797,14 +10149,6 @@ class UserService {
|
|
|
9797
10149
|
listenServiceSubscriptionUpdated() {
|
|
9798
10150
|
this.eventDispatcherService.on(AppEventTypeEnum.SERVICE_SUBSCRIPTION_UPDATED).subscribe(() => this.resetCache());
|
|
9799
10151
|
}
|
|
9800
|
-
/**
|
|
9801
|
-
* capital losses updates on property sale
|
|
9802
|
-
*/
|
|
9803
|
-
listenPropertySale() {
|
|
9804
|
-
this.eventDispatcherService.on2(...PropertySale.getEventNames('post', 'delete')).subscribe(() => {
|
|
9805
|
-
this.resetCache();
|
|
9806
|
-
});
|
|
9807
|
-
}
|
|
9808
10152
|
/**
|
|
9809
10153
|
* @TODO remove when the class refactored on RestService
|
|
9810
10154
|
* Subscribe to http events and run callback.
|
|
@@ -9998,18 +10342,6 @@ var ClientDetailsWorkingHolidayMakerEnum;
|
|
|
9998
10342
|
ClientDetailsWorkingHolidayMakerEnum[ClientDetailsWorkingHolidayMakerEnum["VISA462"] = 2] = "VISA462";
|
|
9999
10343
|
})(ClientDetailsWorkingHolidayMakerEnum || (ClientDetailsWorkingHolidayMakerEnum = {}));
|
|
10000
10344
|
|
|
10001
|
-
var ClientInviteStatusEnum;
|
|
10002
|
-
(function (ClientInviteStatusEnum) {
|
|
10003
|
-
ClientInviteStatusEnum[ClientInviteStatusEnum["PENDING"] = 1] = "PENDING";
|
|
10004
|
-
ClientInviteStatusEnum[ClientInviteStatusEnum["REJECTED"] = 2] = "REJECTED";
|
|
10005
|
-
})(ClientInviteStatusEnum || (ClientInviteStatusEnum = {}));
|
|
10006
|
-
|
|
10007
|
-
var ClientInviteTypeEnum;
|
|
10008
|
-
(function (ClientInviteTypeEnum) {
|
|
10009
|
-
ClientInviteTypeEnum[ClientInviteTypeEnum["FROM_CLIENT"] = 1] = "FROM_CLIENT";
|
|
10010
|
-
ClientInviteTypeEnum[ClientInviteTypeEnum["FROM_EMPLOYEE"] = 2] = "FROM_EMPLOYEE";
|
|
10011
|
-
})(ClientInviteTypeEnum || (ClientInviteTypeEnum = {}));
|
|
10012
|
-
|
|
10013
10345
|
var DepreciationCalculationPercentEnum;
|
|
10014
10346
|
(function (DepreciationCalculationPercentEnum) {
|
|
10015
10347
|
DepreciationCalculationPercentEnum[DepreciationCalculationPercentEnum["PRIME_COST"] = 100] = "PRIME_COST";
|
|
@@ -10390,156 +10722,6 @@ class Badge extends AbstractModel {
|
|
|
10390
10722
|
}
|
|
10391
10723
|
}
|
|
10392
10724
|
|
|
10393
|
-
class ClientIncomeTypes extends ClientIncomeTypes$1 {
|
|
10394
|
-
/**
|
|
10395
|
-
* Get count of selected income types
|
|
10396
|
-
*/
|
|
10397
|
-
get length() {
|
|
10398
|
-
return Object.values(this).filter((value) => typeof value === 'boolean' && value).length;
|
|
10399
|
-
}
|
|
10400
|
-
}
|
|
10401
|
-
|
|
10402
|
-
class ClientInvite extends ClientInvite$1 {
|
|
10403
|
-
/**
|
|
10404
|
-
* Check if client invite status is pending
|
|
10405
|
-
*/
|
|
10406
|
-
isPending() {
|
|
10407
|
-
return this.status === ClientInviteStatusEnum.PENDING;
|
|
10408
|
-
}
|
|
10409
|
-
/**
|
|
10410
|
-
* Check if client invite status is accepted
|
|
10411
|
-
*/
|
|
10412
|
-
isAccepted() {
|
|
10413
|
-
return !this.isPending() && !this.isRejected();
|
|
10414
|
-
}
|
|
10415
|
-
/**
|
|
10416
|
-
* Check if client invite status is rejected
|
|
10417
|
-
*/
|
|
10418
|
-
isRejected() {
|
|
10419
|
-
return this.status === ClientInviteStatusEnum.REJECTED;
|
|
10420
|
-
}
|
|
10421
|
-
/**
|
|
10422
|
-
* Check if client invite initiated by firm
|
|
10423
|
-
*/
|
|
10424
|
-
isFromEmployee() {
|
|
10425
|
-
return this.type === ClientInviteTypeEnum.FROM_EMPLOYEE;
|
|
10426
|
-
}
|
|
10427
|
-
/**
|
|
10428
|
-
* Check if client invite initiated by client
|
|
10429
|
-
*/
|
|
10430
|
-
isFromClient() {
|
|
10431
|
-
return this.type === ClientInviteTypeEnum.FROM_CLIENT;
|
|
10432
|
-
}
|
|
10433
|
-
get firstName() {
|
|
10434
|
-
var _a;
|
|
10435
|
-
return this.client ? this.client.firstName : (_a = this.registrationInvite) === null || _a === void 0 ? void 0 : _a.firstName;
|
|
10436
|
-
}
|
|
10437
|
-
get email() {
|
|
10438
|
-
var _a;
|
|
10439
|
-
return this.client ? this.client.email : (_a = this.registrationInvite) === null || _a === void 0 ? void 0 : _a.email;
|
|
10440
|
-
}
|
|
10441
|
-
}
|
|
10442
|
-
__decorate([
|
|
10443
|
-
Type(() => Date)
|
|
10444
|
-
], ClientInvite.prototype, "sentOn", void 0);
|
|
10445
|
-
__decorate([
|
|
10446
|
-
Type(() => Date)
|
|
10447
|
-
], ClientInvite.prototype, "updatedAt", void 0);
|
|
10448
|
-
__decorate([
|
|
10449
|
-
Type(() => Firm)
|
|
10450
|
-
], ClientInvite.prototype, "firm", void 0);
|
|
10451
|
-
__decorate([
|
|
10452
|
-
Type(() => User)
|
|
10453
|
-
], ClientInvite.prototype, "client", void 0);
|
|
10454
|
-
__decorate([
|
|
10455
|
-
Type(() => User)
|
|
10456
|
-
], ClientInvite.prototype, "employee", void 0);
|
|
10457
|
-
__decorate([
|
|
10458
|
-
Type(() => RegistrationInvite)
|
|
10459
|
-
], ClientInvite.prototype, "registrationInvite", void 0);
|
|
10460
|
-
|
|
10461
|
-
class ClientMovement extends ClientMovement$1 {
|
|
10462
|
-
}
|
|
10463
|
-
__decorate([
|
|
10464
|
-
Type(() => Firm)
|
|
10465
|
-
], ClientMovement.prototype, "firm", void 0);
|
|
10466
|
-
__decorate([
|
|
10467
|
-
Type(() => User)
|
|
10468
|
-
], ClientMovement.prototype, "client", void 0);
|
|
10469
|
-
__decorate([
|
|
10470
|
-
Type(() => User)
|
|
10471
|
-
], ClientMovement.prototype, "employee", void 0);
|
|
10472
|
-
__decorate([
|
|
10473
|
-
Type(() => ServiceSubscription)
|
|
10474
|
-
], ClientMovement.prototype, "subscription", void 0);
|
|
10475
|
-
__decorate([
|
|
10476
|
-
Type(() => Date)
|
|
10477
|
-
], ClientMovement.prototype, "dateFrom", void 0);
|
|
10478
|
-
__decorate([
|
|
10479
|
-
Type(() => Date)
|
|
10480
|
-
], ClientMovement.prototype, "dateTo", void 0);
|
|
10481
|
-
|
|
10482
|
-
/**
|
|
10483
|
-
* Client portfolio charts data based on ClientPortfolioReportCollection
|
|
10484
|
-
*/
|
|
10485
|
-
class ClientPortfolioChartData {
|
|
10486
|
-
constructor(clientsPortfolioReportCollection) {
|
|
10487
|
-
this.clientsPortfolioReportCollection = clientsPortfolioReportCollection;
|
|
10488
|
-
}
|
|
10489
|
-
getPieChartData() {
|
|
10490
|
-
return this.clientsPortfolioReportCollection.items.map((clientPortfolioReport) => {
|
|
10491
|
-
return plainToClass(ChartData, {
|
|
10492
|
-
name: clientPortfolioReport.category,
|
|
10493
|
-
data: clientPortfolioReport.count
|
|
10494
|
-
});
|
|
10495
|
-
});
|
|
10496
|
-
}
|
|
10497
|
-
getBarChartData() {
|
|
10498
|
-
return [
|
|
10499
|
-
plainToClass(ChartData, {
|
|
10500
|
-
name: 'Total',
|
|
10501
|
-
data: [
|
|
10502
|
-
{
|
|
10503
|
-
label: 'Market value',
|
|
10504
|
-
value: this.clientsPortfolioReportCollection.marketValue
|
|
10505
|
-
},
|
|
10506
|
-
{
|
|
10507
|
-
label: 'Loan balance',
|
|
10508
|
-
value: this.clientsPortfolioReportCollection.loanBalance
|
|
10509
|
-
},
|
|
10510
|
-
{
|
|
10511
|
-
label: 'Equity position',
|
|
10512
|
-
value: this.clientsPortfolioReportCollection.equityPosition
|
|
10513
|
-
}
|
|
10514
|
-
]
|
|
10515
|
-
}),
|
|
10516
|
-
plainToClass(ChartData, {
|
|
10517
|
-
name: 'Average',
|
|
10518
|
-
data: [
|
|
10519
|
-
{
|
|
10520
|
-
label: 'Market value',
|
|
10521
|
-
value: this.clientsPortfolioReportCollection.averageMarketValue
|
|
10522
|
-
},
|
|
10523
|
-
{
|
|
10524
|
-
label: 'Loan balance',
|
|
10525
|
-
value: this.clientsPortfolioReportCollection.averageLoanBalance
|
|
10526
|
-
},
|
|
10527
|
-
{
|
|
10528
|
-
label: 'Equity position',
|
|
10529
|
-
value: this.clientsPortfolioReportCollection.averageEquityPosition
|
|
10530
|
-
}
|
|
10531
|
-
]
|
|
10532
|
-
})
|
|
10533
|
-
];
|
|
10534
|
-
}
|
|
10535
|
-
}
|
|
10536
|
-
|
|
10537
|
-
/**
|
|
10538
|
-
* Class describes client's portfolio report information
|
|
10539
|
-
*/
|
|
10540
|
-
class ClientPortfolioReport extends AbstractModel {
|
|
10541
|
-
}
|
|
10542
|
-
|
|
10543
10725
|
var AlphabetColorsEnum;
|
|
10544
10726
|
(function (AlphabetColorsEnum) {
|
|
10545
10727
|
AlphabetColorsEnum["A"] = "#9CC3D5";
|
|
@@ -10864,8 +11046,8 @@ class MyTaxBusinessLosses {
|
|
|
10864
11046
|
}
|
|
10865
11047
|
}
|
|
10866
11048
|
|
|
10867
|
-
;
|
|
10868
11049
|
/**
|
|
11050
|
+
* @TODO vik/nicole test
|
|
10869
11051
|
* Report related to Property sales CGT details.
|
|
10870
11052
|
* All fields are about current year, except netCapitalLoss
|
|
10871
11053
|
*
|
|
@@ -10873,10 +11055,11 @@ class MyTaxBusinessLosses {
|
|
|
10873
11055
|
class MyTaxCgt {
|
|
10874
11056
|
static createFrom(propertySales, properties, clientCapitalLoss) {
|
|
10875
11057
|
return plainToClass(MyTaxCgt, {
|
|
10876
|
-
|
|
10877
|
-
|
|
10878
|
-
|
|
10879
|
-
|
|
11058
|
+
// @TODO vik losses should be applied
|
|
11059
|
+
hasCapitalGain: !!propertySales.grossCapitalGain,
|
|
11060
|
+
hasExemption: !!propertySales.grossCapitalGain && this.isCGTApplicable(propertySales, properties),
|
|
11061
|
+
netCapitalGain: propertySales.sumBy('netCapitalGain'),
|
|
11062
|
+
grossCapitalGain: propertySales.grossCapitalGain,
|
|
10880
11063
|
netCapitalLoss: clientCapitalLoss
|
|
10881
11064
|
});
|
|
10882
11065
|
}
|
|
@@ -14138,12 +14321,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImpor
|
|
|
14138
14321
|
}] }, { type: ToastService }, { type: SseService }];
|
|
14139
14322
|
} });
|
|
14140
14323
|
|
|
14141
|
-
var MessagesEnum$
|
|
14324
|
+
var MessagesEnum$3;
|
|
14142
14325
|
(function (MessagesEnum) {
|
|
14143
14326
|
MessagesEnum["LOGO_UPDATED"] = "Logo updated successfully";
|
|
14144
14327
|
MessagesEnum["LOGO_ERROR_FORMAT"] = "Wrong file format. Allowed extensions: jpg, img, png";
|
|
14145
14328
|
MessagesEnum["LOGO_ERROR_SIZE"] = "The file is too big. Maximum size is 2mb";
|
|
14146
|
-
})(MessagesEnum$
|
|
14329
|
+
})(MessagesEnum$3 || (MessagesEnum$3 = {}));
|
|
14147
14330
|
|
|
14148
14331
|
class SoleBusinessService extends RestService {
|
|
14149
14332
|
constructor() {
|
|
@@ -14167,7 +14350,7 @@ class SoleBusinessService extends RestService {
|
|
|
14167
14350
|
replace(tempCache, plainToClass(SoleBusiness, updatedBusiness));
|
|
14168
14351
|
this.cache = tempCache;
|
|
14169
14352
|
this.cacheSubject.next(this.cache);
|
|
14170
|
-
this.toastService.success(MessagesEnum$
|
|
14353
|
+
this.toastService.success(MessagesEnum$3.LOGO_UPDATED);
|
|
14171
14354
|
}), catchError((error) => {
|
|
14172
14355
|
// Show error when user provided wrong image (format or size)
|
|
14173
14356
|
if (error.status === 422) {
|
|
@@ -15629,6 +15812,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImpor
|
|
|
15629
15812
|
}]
|
|
15630
15813
|
}] });
|
|
15631
15814
|
|
|
15815
|
+
class AnnualClientDetailsService extends RestService$1 {
|
|
15816
|
+
constructor() {
|
|
15817
|
+
super(...arguments);
|
|
15818
|
+
this.modelClass = AnnualClientDetails;
|
|
15819
|
+
this.collectionClass = Collection;
|
|
15820
|
+
this.endpointUri = 'annual-client-details';
|
|
15821
|
+
this.isApiPlatform = true;
|
|
15822
|
+
this.disabledMethods = ['postBatch', 'putBatch', 'deleteBatch', 'delete'];
|
|
15823
|
+
}
|
|
15824
|
+
}
|
|
15825
|
+
AnnualClientDetailsService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: AnnualClientDetailsService, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
|
|
15826
|
+
AnnualClientDetailsService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: AnnualClientDetailsService, providedIn: 'root' });
|
|
15827
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: AnnualClientDetailsService, decorators: [{
|
|
15828
|
+
type: Injectable,
|
|
15829
|
+
args: [{
|
|
15830
|
+
providedIn: 'root'
|
|
15831
|
+
}]
|
|
15832
|
+
}] });
|
|
15833
|
+
|
|
15632
15834
|
/**
|
|
15633
15835
|
* Service that works with Occupations
|
|
15634
15836
|
*/
|
|
@@ -15748,14 +15950,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImpor
|
|
|
15748
15950
|
}]
|
|
15749
15951
|
}] });
|
|
15750
15952
|
|
|
15751
|
-
/**
|
|
15752
|
-
* Service that handling banks logic
|
|
15753
|
-
*/
|
|
15754
15953
|
class HoldingService extends RestService$1 {
|
|
15755
15954
|
constructor() {
|
|
15756
15955
|
super(...arguments);
|
|
15757
15956
|
this.modelClass = Holding;
|
|
15758
|
-
this.collectionClass =
|
|
15957
|
+
this.collectionClass = HoldingCollection;
|
|
15759
15958
|
this.endpointUri = 'holdings';
|
|
15760
15959
|
this.isApiPlatform = true;
|
|
15761
15960
|
this.disabledMethods = ['postBatch', 'putBatch', 'deleteBatch'];
|
|
@@ -15770,9 +15969,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImpor
|
|
|
15770
15969
|
}]
|
|
15771
15970
|
}] });
|
|
15772
15971
|
|
|
15773
|
-
/**
|
|
15774
|
-
* Service that handling banks logic
|
|
15775
|
-
*/
|
|
15776
15972
|
class HoldingTypeService extends RestService$1 {
|
|
15777
15973
|
constructor() {
|
|
15778
15974
|
super(...arguments);
|
|
@@ -15792,9 +15988,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImpor
|
|
|
15792
15988
|
}]
|
|
15793
15989
|
}] });
|
|
15794
15990
|
|
|
15795
|
-
/**
|
|
15796
|
-
* Service that handling banks logic
|
|
15797
|
-
*/
|
|
15798
15991
|
class HoldingSaleService extends RestService$1 {
|
|
15799
15992
|
constructor() {
|
|
15800
15993
|
super(...arguments);
|
|
@@ -17469,15 +17662,15 @@ function passwordMatchValidator(newPassControlName, confirmPassControlName) {
|
|
|
17469
17662
|
};
|
|
17470
17663
|
}
|
|
17471
17664
|
|
|
17472
|
-
var MessagesEnum$
|
|
17665
|
+
var MessagesEnum$2;
|
|
17473
17666
|
(function (MessagesEnum) {
|
|
17474
17667
|
MessagesEnum["INVALID_DATE"] = "The date should not be before $1";
|
|
17475
|
-
})(MessagesEnum$
|
|
17668
|
+
})(MessagesEnum$2 || (MessagesEnum$2 = {}));
|
|
17476
17669
|
|
|
17477
17670
|
/**
|
|
17478
17671
|
* Validation function, that checks If date form value is more than provided date
|
|
17479
17672
|
*/
|
|
17480
|
-
function minDateValidator(date, message = MessagesEnum$
|
|
17673
|
+
function minDateValidator(date, message = MessagesEnum$2.INVALID_DATE.replace('$1', new DatePipe('en-US').transform(date))) {
|
|
17481
17674
|
return (control) => {
|
|
17482
17675
|
if (!control.value) {
|
|
17483
17676
|
return null;
|
|
@@ -18240,6 +18433,38 @@ class BankLoginForm extends AbstractForm {
|
|
|
18240
18433
|
}
|
|
18241
18434
|
}
|
|
18242
18435
|
|
|
18436
|
+
class AnnualClientDetailsForm extends AbstractForm {
|
|
18437
|
+
constructor(annualClientDetails = plainToClass(AnnualClientDetails, {})) {
|
|
18438
|
+
super({
|
|
18439
|
+
capitalLoss: new UntypedFormControl(annualClientDetails.capitalLoss, Validators.required),
|
|
18440
|
+
privateHealthCare: new UntypedFormControl(annualClientDetails.privateHealthCare, Validators.required),
|
|
18441
|
+
spouse: new UntypedFormControl(annualClientDetails.spouse, Validators.required),
|
|
18442
|
+
spouseAnnualIncome: new UntypedFormControl(annualClientDetails.spouseAnnualIncome, conditionalValidator(() => this.get('spouse').value, Validators.required)),
|
|
18443
|
+
hasDependants: new UntypedFormControl(!!annualClientDetails.spouseAnnualIncome, Validators.required),
|
|
18444
|
+
dependants: new UntypedFormControl(annualClientDetails.dependants, conditionalValidator(() => this.get('hasDependants').value, Validators.required)),
|
|
18445
|
+
hasStudentLoan: new UntypedFormControl(!!annualClientDetails.studentLoanAmount, Validators.required),
|
|
18446
|
+
studentLoanAmount: new UntypedFormControl(annualClientDetails.studentLoanAmount, conditionalValidator(() => this.get('hasStudentLoan').value, Validators.required)),
|
|
18447
|
+
}, annualClientDetails);
|
|
18448
|
+
this.annualClientDetails = annualClientDetails;
|
|
18449
|
+
this.watchFieldForToggle('spouse', 'spouseAnnualIncome');
|
|
18450
|
+
this.watchFieldForToggle('hasDependants', 'dependants');
|
|
18451
|
+
this.watchFieldForToggle('hasStudentLoan', 'studentLoanAmount');
|
|
18452
|
+
this.emitValues();
|
|
18453
|
+
}
|
|
18454
|
+
watchFieldForToggle(field, dependantField) {
|
|
18455
|
+
this.get(field).valueChanges.subscribe((value) => this.toggleField(dependantField, !!value));
|
|
18456
|
+
}
|
|
18457
|
+
toggleField(field, enable) {
|
|
18458
|
+
if (enable) {
|
|
18459
|
+
this.get(field).enable();
|
|
18460
|
+
}
|
|
18461
|
+
else {
|
|
18462
|
+
this.get(field).setValue(0);
|
|
18463
|
+
this.get(field).disable();
|
|
18464
|
+
}
|
|
18465
|
+
}
|
|
18466
|
+
}
|
|
18467
|
+
|
|
18243
18468
|
class ClientIncomeTypesForm extends AbstractForm {
|
|
18244
18469
|
constructor(clientIncomeTypes = plainToClass(ClientIncomeTypes, {})) {
|
|
18245
18470
|
super({
|
|
@@ -18395,22 +18620,18 @@ class PropertySaleCostSaleForm extends AbstractForm {
|
|
|
18395
18620
|
commission: new UntypedFormControl(propertySale.commission || 0, Validators.required),
|
|
18396
18621
|
legalFees: new UntypedFormControl(propertySale.legalFees || 0, Validators.required),
|
|
18397
18622
|
otherCost: new UntypedFormControl(propertySale.otherCost || 0, Validators.required),
|
|
18398
|
-
|
|
18399
|
-
grossCGT: new UntypedFormControl({ value: propertySale.grossCGT, disabled: true }, Validators.required),
|
|
18400
|
-
grossCGTAfterLoss: new UntypedFormControl({ value: propertySale.grossCGTAfterLoss, disabled: true }, Validators.required),
|
|
18623
|
+
grossCapitalGain: new UntypedFormControl({ value: propertySale.grossCapitalGain, disabled: true }, Validators.required),
|
|
18401
18624
|
}, propertySale);
|
|
18402
18625
|
this.propertySale = propertySale;
|
|
18403
18626
|
this.property = property;
|
|
18404
18627
|
this.listenEvents();
|
|
18405
|
-
this.
|
|
18628
|
+
this.updateGrossCapitalGain();
|
|
18406
18629
|
}
|
|
18407
18630
|
listenEvents() {
|
|
18408
18631
|
this.listenCommissionUpdated();
|
|
18409
18632
|
this.listenLegalFeesUpdated();
|
|
18410
18633
|
this.listenOtherCostUpdated();
|
|
18411
18634
|
this.listenPriceUpdated();
|
|
18412
|
-
this.listenCapitalLossUpdated();
|
|
18413
|
-
this.listenGrossCGT();
|
|
18414
18635
|
}
|
|
18415
18636
|
/**
|
|
18416
18637
|
* Get property instance based on provided property and form value to get actual form calculations
|
|
@@ -18420,41 +18641,31 @@ class PropertySaleCostSaleForm extends AbstractForm {
|
|
|
18420
18641
|
return plainToClass(PropertySale, Object.assign({}, this.propertySale, this.getRawValue()));
|
|
18421
18642
|
}
|
|
18422
18643
|
submit(data = {}) {
|
|
18423
|
-
// '
|
|
18424
|
-
Object.assign(data, {
|
|
18644
|
+
// 'grossCapitalGain' field is always disabled, but we need it to submit result
|
|
18645
|
+
Object.assign(data, { grossCapitalGain: this.get('grossCapitalGain').value });
|
|
18425
18646
|
return super.submit(data);
|
|
18426
18647
|
}
|
|
18427
|
-
|
|
18428
|
-
this.get('
|
|
18648
|
+
updateGrossCapitalGain() {
|
|
18649
|
+
this.get('grossCapitalGain').setValue(Math.round(this.property.calculateGrossCapitalGain(this.getPropertySale())).toFixed());
|
|
18429
18650
|
}
|
|
18430
18651
|
listenCommissionUpdated() {
|
|
18431
18652
|
this.get('commission').valueChanges.subscribe(() => {
|
|
18432
|
-
this.
|
|
18653
|
+
this.updateGrossCapitalGain();
|
|
18433
18654
|
});
|
|
18434
18655
|
}
|
|
18435
18656
|
listenLegalFeesUpdated() {
|
|
18436
18657
|
this.get('legalFees').valueChanges.subscribe(() => {
|
|
18437
|
-
this.
|
|
18658
|
+
this.updateGrossCapitalGain();
|
|
18438
18659
|
});
|
|
18439
18660
|
}
|
|
18440
18661
|
listenOtherCostUpdated() {
|
|
18441
18662
|
this.get('otherCost').valueChanges.subscribe(() => {
|
|
18442
|
-
this.
|
|
18663
|
+
this.updateGrossCapitalGain();
|
|
18443
18664
|
});
|
|
18444
18665
|
}
|
|
18445
18666
|
listenPriceUpdated() {
|
|
18446
18667
|
this.get('price').valueChanges.subscribe(() => {
|
|
18447
|
-
this.
|
|
18448
|
-
});
|
|
18449
|
-
}
|
|
18450
|
-
listenCapitalLossUpdated() {
|
|
18451
|
-
this.get('capitalLoss').valueChanges.subscribe(() => {
|
|
18452
|
-
this.updateGrossCGT();
|
|
18453
|
-
});
|
|
18454
|
-
}
|
|
18455
|
-
listenGrossCGT() {
|
|
18456
|
-
this.get('grossCGT').valueChanges.subscribe((grossCGT) => {
|
|
18457
|
-
this.get('grossCGTAfterLoss').setValue(this.getPropertySale().grossCGTAfterLoss);
|
|
18668
|
+
this.updateGrossCapitalGain();
|
|
18458
18669
|
});
|
|
18459
18670
|
}
|
|
18460
18671
|
}
|
|
@@ -18468,7 +18679,8 @@ class PropertySaleExemptionsForm extends AbstractForm {
|
|
|
18468
18679
|
super({
|
|
18469
18680
|
taxExemption: new UntypedFormControl(taxExemptions.findBy('id', (_b = (_a = propertySale.taxExemption) === null || _a === void 0 ? void 0 : _a.id) !== null && _b !== void 0 ? _b : property.getCGTExemption(propertySale))),
|
|
18470
18681
|
taxExemptionMetaFields: new UntypedFormArray([]),
|
|
18471
|
-
|
|
18682
|
+
grossCapitalGain: new UntypedFormControl(propertySale.grossCapitalGain),
|
|
18683
|
+
netCapitalGain: new UntypedFormControl(propertySale.netCapitalGain),
|
|
18472
18684
|
}, propertySale);
|
|
18473
18685
|
this.propertySale = propertySale;
|
|
18474
18686
|
this.property = property;
|
|
@@ -18476,7 +18688,7 @@ class PropertySaleExemptionsForm extends AbstractForm {
|
|
|
18476
18688
|
if (propertySale.taxExemption) {
|
|
18477
18689
|
this.setFormMetaFieldsControls();
|
|
18478
18690
|
}
|
|
18479
|
-
this.
|
|
18691
|
+
this.updateCapitalGains();
|
|
18480
18692
|
this.listenEvents();
|
|
18481
18693
|
}
|
|
18482
18694
|
listenEvents() {
|
|
@@ -18488,12 +18700,19 @@ class PropertySaleExemptionsForm extends AbstractForm {
|
|
|
18488
18700
|
getPropertySale() {
|
|
18489
18701
|
return plainToClass(PropertySale, Object.assign({}, this.propertySale, this.getRawValue()));
|
|
18490
18702
|
}
|
|
18491
|
-
|
|
18492
|
-
this.
|
|
18703
|
+
updateCapitalGains() {
|
|
18704
|
+
this.updateGrossCapitalGain();
|
|
18705
|
+
this.updateNetCapitalGain();
|
|
18706
|
+
}
|
|
18707
|
+
updateNetCapitalGain() {
|
|
18708
|
+
this.get('netCapitalGain').setValue(this.property.calculateNetCapitalGain(this.getPropertySale()));
|
|
18709
|
+
}
|
|
18710
|
+
updateGrossCapitalGain() {
|
|
18711
|
+
this.get('grossCapitalGain').setValue(this.property.calculateGrossCapitalGain(this.getPropertySale()));
|
|
18493
18712
|
}
|
|
18494
18713
|
listenTaxExemptionUpdated() {
|
|
18495
18714
|
this.get('taxExemption').valueChanges.subscribe((taxExemption) => {
|
|
18496
|
-
this.
|
|
18715
|
+
this.updateCapitalGains();
|
|
18497
18716
|
this.setFormMetaFieldsControls(taxExemption);
|
|
18498
18717
|
});
|
|
18499
18718
|
}
|
|
@@ -18508,6 +18727,9 @@ class PropertySaleExemptionsForm extends AbstractForm {
|
|
|
18508
18727
|
const formArray = this.get('taxExemptionMetaFields');
|
|
18509
18728
|
// clean up
|
|
18510
18729
|
formArray.clear();
|
|
18730
|
+
if (!currentTaxExemption) {
|
|
18731
|
+
return;
|
|
18732
|
+
}
|
|
18511
18733
|
// show all tax exemption meta fields
|
|
18512
18734
|
currentTaxExemption.metaFields.forEach((metaField) => {
|
|
18513
18735
|
// use property sale tax exemption meta field value if it exists
|
|
@@ -18725,6 +18947,9 @@ class MyTaxBusinessIncomeOrLossesForm extends AbstractForm {
|
|
|
18725
18947
|
}
|
|
18726
18948
|
}
|
|
18727
18949
|
|
|
18950
|
+
/**
|
|
18951
|
+
* @TODO vik/nicole test
|
|
18952
|
+
*/
|
|
18728
18953
|
class MyTaxCgtForm extends AbstractForm {
|
|
18729
18954
|
constructor(gainsOrLosses) {
|
|
18730
18955
|
super({
|
|
@@ -19606,10 +19831,10 @@ class TransactionBaseForm extends AbstractForm {
|
|
|
19606
19831
|
}
|
|
19607
19832
|
}
|
|
19608
19833
|
|
|
19609
|
-
var MessagesEnum;
|
|
19834
|
+
var MessagesEnum$1;
|
|
19610
19835
|
(function (MessagesEnum) {
|
|
19611
19836
|
MessagesEnum["DATE_VALIDATION_ERROR"] = "The transaction date is before the ownership date, please update the date to confirm";
|
|
19612
|
-
})(MessagesEnum || (MessagesEnum = {}));
|
|
19837
|
+
})(MessagesEnum$1 || (MessagesEnum$1 = {}));
|
|
19613
19838
|
|
|
19614
19839
|
class TransactionForm extends TransactionBaseForm {
|
|
19615
19840
|
constructor(transaction, registeredForGst, allocations, controls = {}) {
|
|
@@ -19624,7 +19849,7 @@ class TransactionForm extends TransactionBaseForm {
|
|
|
19624
19849
|
});
|
|
19625
19850
|
// forbid to add transactions before property ownership
|
|
19626
19851
|
if (transaction.property) {
|
|
19627
|
-
this.get('date').addValidators(minDateValidator(transaction.property.myShare.fromDate, MessagesEnum.DATE_VALIDATION_ERROR));
|
|
19852
|
+
this.get('date').addValidators(minDateValidator(transaction.property.myShare.fromDate, MessagesEnum$1.DATE_VALIDATION_ERROR));
|
|
19628
19853
|
}
|
|
19629
19854
|
// property income usually comes with fees, add empty control for new transactions
|
|
19630
19855
|
if (!transaction.id && transaction.property && !transaction.transactions.length && transaction.isCredit()) {
|
|
@@ -19883,11 +20108,91 @@ class DepreciationForm extends TransactionBaseForm {
|
|
|
19883
20108
|
}
|
|
19884
20109
|
}
|
|
19885
20110
|
|
|
20111
|
+
class HoldingSaleForm extends AbstractForm {
|
|
20112
|
+
constructor(sale, holding, type) {
|
|
20113
|
+
super({
|
|
20114
|
+
quantity: new UntypedFormControl(sale.quantity, [Validators.required, Validators.max(holding.currentQuantity)]),
|
|
20115
|
+
price: new UntypedFormControl(sale.price || type.price, Validators.required),
|
|
20116
|
+
fee: new UntypedFormControl(sale.fee, Validators.required),
|
|
20117
|
+
date: new UntypedFormControl(sale.date, Validators.required),
|
|
20118
|
+
grossCapitalGain: new UntypedFormControl({ value: sale.grossCapitalGain, disabled: true }),
|
|
20119
|
+
netCapitalGain: new UntypedFormControl({ value: sale.netCapitalGain, disabled: true }),
|
|
20120
|
+
file: new UntypedFormControl(sale.file)
|
|
20121
|
+
}, sale);
|
|
20122
|
+
this.holding = holding;
|
|
20123
|
+
if (sale.id) {
|
|
20124
|
+
this.emitValues();
|
|
20125
|
+
}
|
|
20126
|
+
this.listenEvents();
|
|
20127
|
+
}
|
|
20128
|
+
listenEvents() {
|
|
20129
|
+
this.listenQuantityChanges();
|
|
20130
|
+
this.listenPriceChanges();
|
|
20131
|
+
}
|
|
20132
|
+
listenQuantityChanges() {
|
|
20133
|
+
this.get('quantity').valueChanges.subscribe(() => {
|
|
20134
|
+
this.updateGainFields();
|
|
20135
|
+
});
|
|
20136
|
+
}
|
|
20137
|
+
listenPriceChanges() {
|
|
20138
|
+
this.get('price').valueChanges.subscribe(() => {
|
|
20139
|
+
this.updateGainFields();
|
|
20140
|
+
});
|
|
20141
|
+
}
|
|
20142
|
+
updateGainFields() {
|
|
20143
|
+
this.get('grossCapitalGain').setValue(this.currentValue.getCapitalGain(this.holding));
|
|
20144
|
+
this.get('netCapitalGain').setValue(this.currentValue.getNetCapitalGain(this.holding));
|
|
20145
|
+
}
|
|
20146
|
+
}
|
|
20147
|
+
|
|
20148
|
+
class HoldingTypeForm extends AbstractForm {
|
|
20149
|
+
constructor(holdingType = plainToClass(HoldingType, {})) {
|
|
20150
|
+
super({
|
|
20151
|
+
category: new UntypedFormControl(holdingType.category, Validators.required),
|
|
20152
|
+
name: new UntypedFormControl(holdingType.name, Validators.required),
|
|
20153
|
+
description: new UntypedFormControl(holdingType.description, Validators.required),
|
|
20154
|
+
price: new UntypedFormControl(holdingType.price, [Validators.required, Validators.min(0)]),
|
|
20155
|
+
dividendPercent: new UntypedFormControl(holdingType.dividendPercent, Validators.min(0))
|
|
20156
|
+
}, holdingType);
|
|
20157
|
+
}
|
|
20158
|
+
}
|
|
20159
|
+
|
|
20160
|
+
class HoldingForm extends AbstractForm {
|
|
20161
|
+
constructor(holding) {
|
|
20162
|
+
super({
|
|
20163
|
+
isTaxFree: new UntypedFormControl(holding.isTaxFree, Validators.required),
|
|
20164
|
+
quantity: new UntypedFormControl(holding.quantity, [Validators.required, Validators.min(0)]),
|
|
20165
|
+
price: new UntypedFormControl(holding.price, [Validators.required, Validators.min(0)]),
|
|
20166
|
+
fee: new UntypedFormControl(holding.fee, [Validators.required, Validators.min(0)]),
|
|
20167
|
+
date: new UntypedFormControl(holding.date, Validators.required),
|
|
20168
|
+
type: new UntypedFormControl(holding.type, Validators.required),
|
|
20169
|
+
ownershipPercent: new UntypedFormControl(holding.ownershipPercent || 100, Validators.required),
|
|
20170
|
+
file: new UntypedFormControl(holding.file)
|
|
20171
|
+
}, holding);
|
|
20172
|
+
}
|
|
20173
|
+
}
|
|
20174
|
+
|
|
20175
|
+
var MessagesEnum;
|
|
20176
|
+
(function (MessagesEnum) {
|
|
20177
|
+
MessagesEnum["HOLDING_CREATED"] = "Holding created";
|
|
20178
|
+
MessagesEnum["HOLDING_UPDATED"] = "Holding updated";
|
|
20179
|
+
MessagesEnum["HOLDING_CONFIRM_DELETE"] = "Are you sure you want to delete this holding?";
|
|
20180
|
+
MessagesEnum["HOLDING_DELETED"] = "Holding deleted";
|
|
20181
|
+
MessagesEnum["HOLDING_SALE_CREATED"] = "Holding sale created";
|
|
20182
|
+
MessagesEnum["HOLDING_SALE_UPDATED"] = "Holding sale updated";
|
|
20183
|
+
MessagesEnum["HOLDING_SALE_CONFIRM_DELETE"] = "Are you sure you want to delete this holding sale?";
|
|
20184
|
+
MessagesEnum["HOLDING_SALE_DELETED"] = "Holding sale deleted";
|
|
20185
|
+
MessagesEnum["HOLDING_TYPE_CREATED"] = "Holding type created";
|
|
20186
|
+
MessagesEnum["HOLDING_TYPE_UPDATED"] = "Holding type updated";
|
|
20187
|
+
MessagesEnum["HOLDING_TYPE_CONFIRM_DELETE"] = "Are you sure you want to delete this holding type?";
|
|
20188
|
+
MessagesEnum["HOLDING_TYPE_DELETED"] = "Holding type deleted";
|
|
20189
|
+
})(MessagesEnum || (MessagesEnum = {}));
|
|
20190
|
+
|
|
19886
20191
|
// @TODO Alex: Create indexes everywhere and break this file to imports from indexes
|
|
19887
20192
|
|
|
19888
20193
|
/**
|
|
19889
20194
|
* Generated bundle index. Do not edit.
|
|
19890
20195
|
*/
|
|
19891
20196
|
|
|
19892
|
-
export { AbstractForm, AbstractModel, AccountSetupItem, AccountSetupItemCollection, AccountSetupService, Address, AddressForm, AddressService, AddressTypeEnum, AllocationGroup, AllocationGroupCollection, AllocationRule, AllocationRuleCollection, AllocationRuleConditionComparisonOperatorEnum, AllocationRuleConditionFieldEnum, AllocationRuleConditionOperatorEnum, AllocationRuleForm, AllocationRuleService, AllocationRuleTransaction, AllocationRuleTransactionMetaField, AllocationRuleTypeEnum, AlphabetColorsEnum, AnnualFrequencyEnum, AppEvent, AppEvent2, AppEventTypeEnum, AppFile, AssetEntityTypeEnum, AssetTypeEnum, AssetsService, AuthService, BANK_ACCOUNT_TYPES, Badge, BadgeColorEnum, Bank, BankAccount, BankAccountAddManualForm, BankAccountAllocationForm, BankAccountCalculationService, BankAccountChartData, BankAccountCollection, BankAccountImportForm, BankAccountPropertiesForm, BankAccountProperty, BankAccountService, BankAccountStatusEnum, BankAccountTypeEnum, BankAccountsImportForm, BankConnection, BankConnectionService, BankConnectionStatusEnum, BankExternalStats, BankLoginData, BankLoginForm, BankService, BankTransaction, BankTransactionCalculationService, BankTransactionChartData, BankTransactionCollection, BankTransactionService, BankTransactionSummaryFieldsEnum, BankTransactionTypeEnum, BasReport, BasReportForm, BasReportService, BasiqConfig, BasiqJob, BasiqJobResponse, BasiqJobStep, BasiqService, BasiqToken, BasiqTokenService, BorrowingExpense, BorrowingExpenseLoan, BorrowingExpenseService, BusinessTypeEnum, CAPITAL_COSTS_ITEMS, CHART_ACCOUNTS_CATEGORIES, CalculationFormItem, CalculationFormTypeEnum, CgtExemptionAndRolloverCodeEnum, ChartAccounts, ChartAccountsCategoryECollection, ChartAccountsCategoryEnum, ChartAccountsCollection, ChartAccountsDepreciation, ChartAccountsDepreciationService, ChartAccountsEtpEnum, ChartAccountsHeading, ChartAccountsHeadingListEnum, ChartAccountsHeadingTaxDeductibleEnum, ChartAccountsHeadingTaxableEnum, ChartAccountsHeadingVehicleListEnum, ChartAccountsKeepSign, ChartAccountsListEnum, ChartAccountsMetaField, ChartAccountsMetaFieldListEnum, ChartAccountsMetaFieldTypeEnum, ChartAccountsSalaryAdjustmentsListEnum, ChartAccountsSalaryIncludedListEnum, ChartAccountsService, ChartAccountsTaxLabelsEnum, ChartAccountsTypeEnum, ChartAccountsValue, ChartData, ChartSerie, Chat, ChatCollection, ChatService, ChatStatusEnum, ChatViewTypeEnum, ClientCollection, ClientDetails, ClientDetailsMedicareExemptionEnum, ClientDetailsWorkDepreciationCalculationEnum, ClientDetailsWorkingHolidayMakerEnum, ClientIncomeTypes, ClientIncomeTypesForm, ClientIncomeTypesService, ClientInvite, ClientInviteCollection, ClientInviteService, ClientInviteStatusEnum, ClientInviteTypeEnum, ClientMovement, ClientMovementCollection, ClientMovementService, ClientPortfolioChartData, ClientPortfolioReport, ClientPortfolioReportCollection, ClientPortfolioReportService, Collection, CollectionDictionary, CorelogicService, CorelogicSuggestion, Country, DEDUCTION_CATEGORIES, DEPRECIATION_GROUPS, DOCUMENT_FILE_TYPES, DeductionClothingTypeEnum, DeductionSelfEducationTypeEnum, Depreciation, DepreciationCalculationEnum, DepreciationCalculationPercentEnum, DepreciationCapitalProject, DepreciationCapitalProjectService, DepreciationCollection, DepreciationForecast, DepreciationForecastCollection, DepreciationForm, DepreciationGroup, DepreciationGroupEnum, DepreciationGroupItem, DepreciationLvpAssetTypeEnum, DepreciationLvpRateEnum, DepreciationLvpReportItem, DepreciationLvpReportItemCollection, DepreciationReceipt, DepreciationReceiptService, DepreciationReportItem, DepreciationReportItemCollection, DepreciationService, DepreciationTypeEnum, DepreciationWriteOffAmountEnum, Dictionary, Document, DocumentApiUrlPrefixEnum, DocumentFolder, DocumentFolderService, DocumentService, DocumentTypeEnum, ENDPOINTS, EmployeeCollection, EmployeeDetails, EmployeeInvite, EmployeeInviteService, EmployeeService, Endpoint, EquityPositionChartService, EventDispatcherService, ExportDataTable, ExportFormatEnum, ExportFormatterService, ExportableCollection, FacebookService, FileService, FileValidator, FinancialYear, Firm, FirmService, FirmTypeEnum, FormValidationsEnum, GoogleService, HeaderTitleService, Holding, HoldingSale, HoldingSaleService, HoldingService, HoldingType, HoldingTypeService, IconsFileEnum, IncomeAmountTypeEnum, IncomePosition, IncomeSource, IncomeSourceChartData, IncomeSourceCollection, IncomeSourceForecast, IncomeSourceForecastService, IncomeSourceForecastTrustTypeEnum, IncomeSourceService, IncomeSourceType, IncomeSourceTypeEnum, IncomeSourceTypeListOtherEnum, IncomeSourceTypeListSoleEnum, IncomeSourceTypeListWorkEnum, InterceptorsModule, IntercomService, InviteStatusEnum, JsPdf, JwtService, Loan, LoanBankTypeEnum, LoanCollection, LoanForm, LoanFrequencyEnum, LoanInterestTypeEnum, LoanMaxNumberOfPaymentsEnum, LoanPayment, LoanPaymentCollection, LoanPayout, LoanPayoutTypeEnum, LoanRepaymentFrequencyEnum, LoanRepaymentTypeEnum, LoanService, LoanTypeEnum, LoanVehicleTypeEnum, LogbookBestPeriodService, LogbookPeriod, LoginForm, LossTypeEnum, MODULE_URL_LIST, MONTHS, Message, MessageCollection, MessageDocument, MessageDocumentCollection, MessageDocumentService, MessageService, MonthNameShortEnum, MonthNumberEnum, MyAccountHistory, MyAccountHistoryInitiatedByEnum, MyAccountHistoryStatusEnum, MyAccountHistoryTypeEnum, MyTaxBusinessDetails, MyTaxBusinessDetailsForm, MyTaxBusinessIncome, MyTaxBusinessIncomeForm, MyTaxBusinessIncomeOrLossesForm, MyTaxBusinessLosses, MyTaxBusinessLossesForm, MyTaxCgt, MyTaxCgtForm, MyTaxDeductions, MyTaxDeductionsForm, MyTaxDividends, MyTaxDividendsForm, MyTaxEstimate, MyTaxIncomeStatements, MyTaxIncomeStatementsForm, MyTaxIncomeTests, MyTaxIncomeTestsForm, MyTaxInterest, MyTaxInterestForm, MyTaxLosses, MyTaxLossesForm, MyTaxMedicareForm, MyTaxOffsets, MyTaxOffsetsForm, MyTaxOtherIncome, MyTaxOtherIncomeForm, MyTaxPartnershipsAndTrusts, MyTaxPartnershipsAndTrustsForm, MyTaxRent, MyTaxRentForm, Notification, Occupation, OccupationService, PASSWORD_REGEXPS, PasswordForm, PdfFromDataTableService, PdfFromDomElementService, PdfFromHtmlTableService, PdfFromTableService, PdfOrientationEnum, PdfSettings, Phone, PhoneForm, PhoneTypeEnum, PreloaderService, Property, PropertyCalculationService, PropertyCategory, PropertyCategoryListEnum, PropertyCategoryMovement, PropertyCategoryMovementCollection, PropertyCategoryMovementService, PropertyCategoryService, PropertyCollection, PropertyDepreciationCalculationEnum, PropertyDocument, PropertyDocumentService, PropertyEquityChartData, PropertyEquityChartItem, PropertyEquityChartTypeEnum, PropertyForecast, PropertyReportItem, PropertyReportItemCollection, PropertyReportItemDepreciation, PropertyReportItemDepreciationCollection, PropertyReportItemTransaction, PropertyReportItemTransactionCollection, PropertySale, PropertySaleCollection, PropertySaleCostBase, PropertySaleCostBaseForm, PropertySaleCostSaleForm, PropertySaleExemptionsForm, PropertySaleService, PropertySaleTaxExemptionMetaField, PropertySaleTaxExemptionMetaFieldCollection, PropertyService, PropertyShare, PropertyShareAccessEnum, PropertyShareCollection, PropertyShareService, PropertyShareStatusEnum, PropertySubscription, PropertyTransactionReportService, PropertyValuation, ReceiptService, RegisterClientForm, RegisterFirmForm, RegistrationInvite, RegistrationInviteStatusEnum, ReportItem, ReportItemCollection, ReportItemDetails, ResetPasswordForm, RestService$1 as RestService, RewardfulService, SalaryForecast, SalaryForecastFrequencyEnum, SalaryForecastService, ServiceNotificationService, ServiceNotificationStatusEnum, ServiceNotificationTypeEnum, ServicePayment, ServicePaymentMethod, ServicePaymentMethodService, ServicePaymentService, ServicePaymentStatusEnum, ServicePrice, ServicePriceCollection, ServicePriceRecurringIntervalEnum, ServicePriceService, ServicePriceTypeEnum, ServiceProduct, ServiceProductCollection, ServiceProductIdEnum, ServiceProductService, ServiceProductStatusEnum, ServiceSubscription, ServiceSubscriptionCollection, ServiceSubscriptionItem, ServiceSubscriptionStatusEnum, ShareFilterOptionsEnum, SoleBusiness, SoleBusinessActivity, SoleBusinessActivityService, SoleBusinessAllocation, SoleBusinessAllocationsForm, SoleBusinessForm, SoleBusinessLoss, SoleBusinessLossForm, SoleBusinessLossOffsetRule, SoleBusinessLossOffsetRuleService, SoleBusinessLossReport, SoleBusinessLossService, SoleBusinessLossesCollection, SoleBusinessService, SoleContact, SoleContactForm, SoleContactService, SoleDepreciationMethod, SoleDepreciationMethodEnum, SoleDepreciationMethodForm, SoleDepreciationMethodService, SoleDetails, SoleDetailsForm, SoleDetailsService, SoleForecast, SoleForecastService, SoleInvoice, SoleInvoiceCollection, SoleInvoiceForm, SoleInvoiceItem, SoleInvoiceItemCollection, SoleInvoiceItemForm, SoleInvoiceService, SoleInvoiceStatusesEnum, SoleInvoiceTaxTypeEnum, SoleInvoiceTemplate, SoleInvoiceTemplateForm, SoleInvoiceTemplateService, SoleInvoiceTemplateTaxTypeEnum, SpareDocumentSpareTypeEnum, SseService, StatesEnum, StripePromoCode, SubscriptionItemCollection, SubscriptionService, TAX_RETURN_CATEGORIES, TYPE_LOAN, TankTypeEnum, TaxCalculationMedicareExemptionEnum, TaxCalculationTypeEnum, TaxExemption, TaxExemptionEnum, TaxExemptionMetaField, TaxExemptionMetaFieldEnum, TaxExemptionService, TaxReturnCategoryListEnum, TaxReturnCategorySectionEnum, TaxReview, TaxReviewCollection, TaxReviewHistoryService, TaxReviewService, TaxReviewStatusEnum, TaxSummary, TaxSummaryListEnum, TaxSummarySection, TaxSummarySectionEnum, TaxSummaryService, TaxSummaryTaxSummaryEnum, TaxSummaryTypeEnum, TicketFeedbackEnum, TicketStatusEnum, TicketTypesEnum, Toast, ToastService, ToastTypeEnum, Transaction, TransactionAllocation, TransactionAllocationCollection, TransactionAllocationService, TransactionBase, TransactionBaseForm, TransactionCalculationService, TransactionCategoryEnum, TransactionCollection, TransactionForm, TransactionMetaField, TransactionOperationEnum, TransactionReceipt, TransactionReceiptService, TransactionService, TransactionSourceEnum, TransactionTypeEnum, TtCoreModule, TutorialVideoService, USER_ROLES, USER_WORK_POSITION, User, UserEventSetting, UserEventSettingCollection, UserEventSettingFieldEnum, UserEventSettingService, UserEventStatusEnum, UserEventType, UserEventTypeCategory, UserEventTypeClientTypeEnum, UserEventTypeCollection, UserEventTypeEmployeeTypeEnum, UserEventTypeFrequencyEnum, UserEventTypeService, UserEventTypeUserTypeEnum, UserInviteForm, UserMedicareExemptionEnum, UserRolesEnum, UserService, UserStatusEnum, UserSwitcherService, UserTitleEnum, UserToRegister, UserWorkDepreciationCalculationEnum, UserWorkingHolidayMakerEnum, UsersInviteService, Vehicle, VehicleClaim, VehicleClaimCollection, VehicleClaimDetails, VehicleClaimDetailsForm, VehicleClaimDetailsMethodEnum, VehicleClaimDetailsService, VehicleClaimForm, VehicleClaimService, VehicleExpense, VehicleExpenseCollection, VehicleForm, VehicleLogbook, VehicleLogbookCollection, VehicleLogbookForm, VehicleLogbookPurposeEnum, VehicleLogbookService, VehicleService, WorkExpenseForm, WorkIncomeForm, XlsxService, atLeastOneCheckedValidator, atoLinks, autocompleteValidator, cloneDeep, compare, compareMatOptions, conditionalValidator, createDate, currentFinYearValidator, displayMatOptions, enumToList, fieldsSumValidator, getDocIcon, minDateValidator, passwordMatchValidator, passwordValidator, replace, roundTo, sort, sortDeep, taxReviewFilterPredicate, toArray };
|
|
20197
|
+
export { AbstractForm, AbstractModel, AccountSetupItem, AccountSetupItemCollection, AccountSetupService, Address, AddressForm, AddressService, AddressTypeEnum, AllocationGroup, AllocationGroupCollection, AllocationRule, AllocationRuleCollection, AllocationRuleConditionComparisonOperatorEnum, AllocationRuleConditionFieldEnum, AllocationRuleConditionOperatorEnum, AllocationRuleForm, AllocationRuleService, AllocationRuleTransaction, AllocationRuleTransactionMetaField, AllocationRuleTypeEnum, AlphabetColorsEnum, AnnualClientDetails, AnnualClientDetailsForm, AnnualClientDetailsService, AnnualFrequencyEnum, AppEvent, AppEvent2, AppEventTypeEnum, AppFile, AssetEntityTypeEnum, AssetTypeEnum, AssetsService, AuthService, BANK_ACCOUNT_TYPES, Badge, BadgeColorEnum, Bank, BankAccount, BankAccountAddManualForm, BankAccountAllocationForm, BankAccountCalculationService, BankAccountChartData, BankAccountCollection, BankAccountImportForm, BankAccountPropertiesForm, BankAccountProperty, BankAccountService, BankAccountStatusEnum, BankAccountTypeEnum, BankAccountsImportForm, BankConnection, BankConnectionService, BankConnectionStatusEnum, BankExternalStats, BankLoginData, BankLoginForm, BankService, BankTransaction, BankTransactionCalculationService, BankTransactionChartData, BankTransactionCollection, BankTransactionService, BankTransactionSummaryFieldsEnum, BankTransactionTypeEnum, BasReport, BasReportForm, BasReportService, BasiqConfig, BasiqJob, BasiqJobResponse, BasiqJobStep, BasiqService, BasiqToken, BasiqTokenService, BorrowingExpense, BorrowingExpenseLoan, BorrowingExpenseService, BusinessTypeEnum, CAPITAL_COSTS_ITEMS, CHART_ACCOUNTS_CATEGORIES, CalculationFormItem, CalculationFormTypeEnum, CgtExemptionAndRolloverCodeEnum, ChartAccounts, ChartAccountsCategoryECollection, ChartAccountsCategoryEnum, ChartAccountsCollection, ChartAccountsDepreciation, ChartAccountsDepreciationService, ChartAccountsEtpEnum, ChartAccountsHeading, ChartAccountsHeadingListEnum, ChartAccountsHeadingTaxDeductibleEnum, ChartAccountsHeadingTaxableEnum, ChartAccountsHeadingVehicleListEnum, ChartAccountsKeepSign, ChartAccountsListEnum, ChartAccountsMetaField, ChartAccountsMetaFieldListEnum, ChartAccountsMetaFieldTypeEnum, ChartAccountsSalaryAdjustmentsListEnum, ChartAccountsSalaryIncludedListEnum, ChartAccountsService, ChartAccountsTaxLabelsEnum, ChartAccountsTypeEnum, ChartAccountsValue, ChartData, ChartSerie, Chat, ChatCollection, ChatService, ChatStatusEnum, ChatViewTypeEnum, ClientCollection, ClientDetails, ClientDetailsMedicareExemptionEnum, ClientDetailsWorkDepreciationCalculationEnum, ClientDetailsWorkingHolidayMakerEnum, ClientIncomeTypes, ClientIncomeTypesForm, ClientIncomeTypesService, ClientInvite, ClientInviteCollection, ClientInviteService, ClientInviteStatusEnum, ClientInviteTypeEnum, ClientMovement, ClientMovementCollection, ClientMovementService, ClientPortfolioChartData, ClientPortfolioReport, ClientPortfolioReportCollection, ClientPortfolioReportService, Collection, CollectionDictionary, CorelogicService, CorelogicSuggestion, Country, DEDUCTION_CATEGORIES, DEPRECIATION_GROUPS, DOCUMENT_FILE_TYPES, DeductionClothingTypeEnum, DeductionSelfEducationTypeEnum, Depreciation, DepreciationCalculationEnum, DepreciationCalculationPercentEnum, DepreciationCapitalProject, DepreciationCapitalProjectService, DepreciationCollection, DepreciationForecast, DepreciationForecastCollection, DepreciationForm, DepreciationGroup, DepreciationGroupEnum, DepreciationGroupItem, DepreciationLvpAssetTypeEnum, DepreciationLvpRateEnum, DepreciationLvpReportItem, DepreciationLvpReportItemCollection, DepreciationReceipt, DepreciationReceiptService, DepreciationReportItem, DepreciationReportItemCollection, DepreciationService, DepreciationTypeEnum, DepreciationWriteOffAmountEnum, Dictionary, Document, DocumentApiUrlPrefixEnum, DocumentFolder, DocumentFolderService, DocumentService, DocumentTypeEnum, ENDPOINTS, EmployeeCollection, EmployeeDetails, EmployeeInvite, EmployeeInviteService, EmployeeService, Endpoint, EquityPositionChartService, EventDispatcherService, ExportDataTable, ExportFormatEnum, ExportFormatterService, ExportableCollection, FacebookService, FileService, FileValidator, FinancialYear, Firm, FirmService, FirmTypeEnum, FormValidationsEnum, GoogleService, HeaderTitleService, Holding, HoldingCollection, HoldingForm, HoldingSale, HoldingSaleForm, HoldingSaleService, HoldingService, HoldingType, HoldingTypeCategoryEnum, HoldingTypeForm, HoldingTypeService, IconsFileEnum, IncomeAmountTypeEnum, IncomePosition, IncomeSource, IncomeSourceChartData, IncomeSourceCollection, IncomeSourceForecast, IncomeSourceForecastService, IncomeSourceForecastTrustTypeEnum, IncomeSourceService, IncomeSourceType, IncomeSourceTypeEnum, IncomeSourceTypeListOtherEnum, IncomeSourceTypeListSoleEnum, IncomeSourceTypeListWorkEnum, InterceptorsModule, IntercomService, InviteStatusEnum, JsPdf, JwtService, Loan, LoanBankTypeEnum, LoanCollection, LoanForm, LoanFrequencyEnum, LoanInterestTypeEnum, LoanMaxNumberOfPaymentsEnum, LoanPayment, LoanPaymentCollection, LoanPayout, LoanPayoutTypeEnum, LoanRepaymentFrequencyEnum, LoanRepaymentTypeEnum, LoanService, LoanTypeEnum, LoanVehicleTypeEnum, LogbookBestPeriodService, LogbookPeriod, LoginForm, LossTypeEnum, MODULE_URL_LIST, MONTHS, Message, MessageCollection, MessageDocument, MessageDocumentCollection, MessageDocumentService, MessageService, MessagesEnum, MonthNameShortEnum, MonthNumberEnum, MyAccountHistory, MyAccountHistoryInitiatedByEnum, MyAccountHistoryStatusEnum, MyAccountHistoryTypeEnum, MyTaxBusinessDetails, MyTaxBusinessDetailsForm, MyTaxBusinessIncome, MyTaxBusinessIncomeForm, MyTaxBusinessIncomeOrLossesForm, MyTaxBusinessLosses, MyTaxBusinessLossesForm, MyTaxCgt, MyTaxCgtForm, MyTaxDeductions, MyTaxDeductionsForm, MyTaxDividends, MyTaxDividendsForm, MyTaxEstimate, MyTaxIncomeStatements, MyTaxIncomeStatementsForm, MyTaxIncomeTests, MyTaxIncomeTestsForm, MyTaxInterest, MyTaxInterestForm, MyTaxLosses, MyTaxLossesForm, MyTaxMedicareForm, MyTaxOffsets, MyTaxOffsetsForm, MyTaxOtherIncome, MyTaxOtherIncomeForm, MyTaxPartnershipsAndTrusts, MyTaxPartnershipsAndTrustsForm, MyTaxRent, MyTaxRentForm, Notification, Occupation, OccupationService, PASSWORD_REGEXPS, PasswordForm, PdfFromDataTableService, PdfFromDomElementService, PdfFromHtmlTableService, PdfFromTableService, PdfOrientationEnum, PdfSettings, Phone, PhoneForm, PhoneTypeEnum, PreloaderService, Property, PropertyCalculationService, PropertyCategory, PropertyCategoryListEnum, PropertyCategoryMovement, PropertyCategoryMovementCollection, PropertyCategoryMovementService, PropertyCategoryService, PropertyCollection, PropertyDepreciationCalculationEnum, PropertyDocument, PropertyDocumentService, PropertyEquityChartData, PropertyEquityChartItem, PropertyEquityChartTypeEnum, PropertyForecast, PropertyReportItem, PropertyReportItemCollection, PropertyReportItemDepreciation, PropertyReportItemDepreciationCollection, PropertyReportItemTransaction, PropertyReportItemTransactionCollection, PropertySale, PropertySaleCollection, PropertySaleCostBase, PropertySaleCostBaseForm, PropertySaleCostSaleForm, PropertySaleExemptionsForm, PropertySaleService, PropertySaleTaxExemptionMetaField, PropertySaleTaxExemptionMetaFieldCollection, PropertyService, PropertyShare, PropertyShareAccessEnum, PropertyShareCollection, PropertyShareService, PropertyShareStatusEnum, PropertySubscription, PropertyTransactionReportService, PropertyValuation, ReceiptService, RegisterClientForm, RegisterFirmForm, RegistrationInvite, RegistrationInviteStatusEnum, ReportItem, ReportItemCollection, ReportItemDetails, ResetPasswordForm, RestService$1 as RestService, RewardfulService, SalaryForecast, SalaryForecastFrequencyEnum, SalaryForecastService, ServiceNotificationService, ServiceNotificationStatusEnum, ServiceNotificationTypeEnum, ServicePayment, ServicePaymentMethod, ServicePaymentMethodService, ServicePaymentService, ServicePaymentStatusEnum, ServicePrice, ServicePriceCollection, ServicePriceRecurringIntervalEnum, ServicePriceService, ServicePriceTypeEnum, ServiceProduct, ServiceProductCollection, ServiceProductIdEnum, ServiceProductService, ServiceProductStatusEnum, ServiceSubscription, ServiceSubscriptionCollection, ServiceSubscriptionItem, ServiceSubscriptionStatusEnum, ShareFilterOptionsEnum, SoleBusiness, SoleBusinessActivity, SoleBusinessActivityService, SoleBusinessAllocation, SoleBusinessAllocationsForm, SoleBusinessForm, SoleBusinessLoss, SoleBusinessLossForm, SoleBusinessLossOffsetRule, SoleBusinessLossOffsetRuleService, SoleBusinessLossReport, SoleBusinessLossService, SoleBusinessLossesCollection, SoleBusinessService, SoleContact, SoleContactForm, SoleContactService, SoleDepreciationMethod, SoleDepreciationMethodEnum, SoleDepreciationMethodForm, SoleDepreciationMethodService, SoleDetails, SoleDetailsForm, SoleDetailsService, SoleForecast, SoleForecastService, SoleInvoice, SoleInvoiceCollection, SoleInvoiceForm, SoleInvoiceItem, SoleInvoiceItemCollection, SoleInvoiceItemForm, SoleInvoiceService, SoleInvoiceStatusesEnum, SoleInvoiceTaxTypeEnum, SoleInvoiceTemplate, SoleInvoiceTemplateForm, SoleInvoiceTemplateService, SoleInvoiceTemplateTaxTypeEnum, SpareDocumentSpareTypeEnum, SseService, StatesEnum, StripePromoCode, SubscriptionItemCollection, SubscriptionService, TAX_RETURN_CATEGORIES, TYPE_LOAN, TankTypeEnum, TaxCalculationMedicareExemptionEnum, TaxCalculationTypeEnum, TaxExemption, TaxExemptionEnum, TaxExemptionMetaField, TaxExemptionMetaFieldEnum, TaxExemptionService, TaxReturnCategoryListEnum, TaxReturnCategorySectionEnum, TaxReview, TaxReviewCollection, TaxReviewHistoryService, TaxReviewService, TaxReviewStatusEnum, TaxSummary, TaxSummaryListEnum, TaxSummarySection, TaxSummarySectionEnum, TaxSummaryService, TaxSummaryTaxSummaryEnum, TaxSummaryTypeEnum, TicketFeedbackEnum, TicketStatusEnum, TicketTypesEnum, Toast, ToastService, ToastTypeEnum, Transaction, TransactionAllocation, TransactionAllocationCollection, TransactionAllocationService, TransactionBase, TransactionBaseForm, TransactionCalculationService, TransactionCategoryEnum, TransactionCollection, TransactionForm, TransactionMetaField, TransactionOperationEnum, TransactionReceipt, TransactionReceiptService, TransactionService, TransactionSourceEnum, TransactionTypeEnum, TtCoreModule, TutorialVideoService, USER_ROLES, USER_WORK_POSITION, User, UserEventSetting, UserEventSettingCollection, UserEventSettingFieldEnum, UserEventSettingService, UserEventStatusEnum, UserEventType, UserEventTypeCategory, UserEventTypeClientTypeEnum, UserEventTypeCollection, UserEventTypeEmployeeTypeEnum, UserEventTypeFrequencyEnum, UserEventTypeService, UserEventTypeUserTypeEnum, UserInviteForm, UserMedicareExemptionEnum, UserRolesEnum, UserService, UserStatusEnum, UserSwitcherService, UserTitleEnum, UserToRegister, UserWorkDepreciationCalculationEnum, UserWorkingHolidayMakerEnum, UsersInviteService, Vehicle, VehicleClaim, VehicleClaimCollection, VehicleClaimDetails, VehicleClaimDetailsForm, VehicleClaimDetailsMethodEnum, VehicleClaimDetailsService, VehicleClaimForm, VehicleClaimService, VehicleExpense, VehicleExpenseCollection, VehicleForm, VehicleLogbook, VehicleLogbookCollection, VehicleLogbookForm, VehicleLogbookPurposeEnum, VehicleLogbookService, VehicleService, WorkExpenseForm, WorkIncomeForm, XlsxService, atLeastOneCheckedValidator, atoLinks, autocompleteValidator, cloneDeep, compare, compareMatOptions, conditionalValidator, createDate, currentFinYearValidator, displayMatOptions, enumToList, fieldsSumValidator, getDocIcon, minDateValidator, passwordMatchValidator, passwordValidator, replace, roundTo, sort, sortDeep, taxReviewFilterPredicate, toArray };
|
|
19893
20198
|
//# sourceMappingURL=taxtank-core.mjs.map
|