taxtank-core 0.21.8 → 0.21.11

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.
Files changed (50) hide show
  1. package/bundles/taxtank-core.umd.js +264 -128
  2. package/bundles/taxtank-core.umd.js.map +1 -1
  3. package/esm2015/lib/collections/collection.js +7 -1
  4. package/esm2015/lib/db/Enums/chart-accounts-heading-list.enum.js +8 -1
  5. package/esm2015/lib/db/Enums/income-source-forecast-trust-type.enum.js +15 -0
  6. package/esm2015/lib/db/Enums/income-source-type-list-other.enum.js +3 -2
  7. package/esm2015/lib/db/Models/incomeSource/income-source-forecast.js +1 -1
  8. package/esm2015/lib/forms/abstract.form.js +6 -1
  9. package/esm2015/lib/forms/bank/bank-account/bank-account-add-manual.form.js +9 -42
  10. package/esm2015/lib/forms/bank/bank-account/bank-account-allocation.form.js +31 -0
  11. package/esm2015/lib/forms/bank/bank-account/bank-account-import.form.js +4 -30
  12. package/esm2015/lib/forms/bank/bank-account/bank-account-properties.form.js +28 -7
  13. package/esm2015/lib/forms/index.js +2 -1
  14. package/esm2015/lib/forms/report/my-tax/my-tax-deductions.form.js +9 -3
  15. package/esm2015/lib/forms/report/my-tax/my-tax-partnerships-and-trusts.form.js +5 -2
  16. package/esm2015/lib/interfaces/income-source-forecast.interface.js +1 -1
  17. package/esm2015/lib/models/income-source/income-source-type.js +3 -3
  18. package/esm2015/lib/models/report/my-tax/my-tax-deductions/deduction-fields.const.js +9 -2
  19. package/esm2015/lib/models/report/my-tax/my-tax-deductions/my-tax-deductions.js +16 -16
  20. package/esm2015/lib/models/report/my-tax/my-tax-estimate/my-tax-estimate.js +3 -3
  21. package/esm2015/lib/models/report/my-tax/my-tax-interest/my-tax-interest.js +2 -2
  22. package/esm2015/lib/models/report/my-tax/my-tax-partnerships-and-trusts/my-tax-partnerships-and-trusts.js +20 -2
  23. package/esm2015/lib/models/report/my-tax/my-tax-rent/my-tax-rent.js +35 -9
  24. package/esm2015/lib/validators/conditional.validator.js +26 -0
  25. package/esm2015/lib/validators/fields-sum.validator.js +26 -0
  26. package/esm2015/lib/validators/index.js +2 -1
  27. package/esm2015/public-api.js +2 -1
  28. package/fesm2015/taxtank-core.js +255 -124
  29. package/fesm2015/taxtank-core.js.map +1 -1
  30. package/lib/collections/collection.d.ts +2 -0
  31. package/lib/db/Enums/chart-accounts-heading-list.enum.d.ts +7 -0
  32. package/lib/db/Enums/income-source-forecast-trust-type.enum.d.ts +13 -0
  33. package/lib/db/Enums/income-source-type-list-other.enum.d.ts +3 -2
  34. package/lib/db/Models/incomeSource/income-source-forecast.d.ts +3 -1
  35. package/lib/forms/abstract.form.d.ts +4 -0
  36. package/lib/forms/bank/bank-account/bank-account-add-manual.form.d.ts +2 -6
  37. package/lib/forms/bank/bank-account/bank-account-allocation.form.d.ts +7 -0
  38. package/lib/forms/bank/bank-account/bank-account-import.form.d.ts +2 -8
  39. package/lib/forms/bank/bank-account/bank-account-properties.form.d.ts +1 -0
  40. package/lib/forms/index.d.ts +1 -0
  41. package/lib/forms/report/my-tax/my-tax-deductions.form.d.ts +1 -1
  42. package/lib/forms/report/my-tax/my-tax-partnerships-and-trusts.form.d.ts +1 -1
  43. package/lib/interfaces/income-source-forecast.interface.d.ts +2 -0
  44. package/lib/models/report/my-tax/my-tax-partnerships-and-trusts/my-tax-partnerships-and-trusts.d.ts +9 -1
  45. package/lib/models/report/my-tax/my-tax-rent/my-tax-rent.d.ts +11 -1
  46. package/lib/validators/conditional.validator.d.ts +2 -0
  47. package/lib/validators/fields-sum.validator.d.ts +8 -0
  48. package/lib/validators/index.d.ts +1 -0
  49. package/package.json +1 -1
  50. package/public-api.d.ts +1 -0
@@ -5,7 +5,7 @@ import { CommonModule } from '@angular/common';
5
5
  import * as i1 from '@angular/common/http';
6
6
  import { HttpParams, HttpErrorResponse, HTTP_INTERCEPTORS } from '@angular/common/http';
7
7
  import { ReplaySubject, Subject, BehaviorSubject, throwError, combineLatest, of, Observable, forkJoin, from } from 'rxjs';
8
- import { map, filter, catchError, take, switchMap, finalize, mergeMap } from 'rxjs/operators';
8
+ import { map, filter, catchError, take, switchMap, finalize, mergeMap, distinctUntilChanged } from 'rxjs/operators';
9
9
  import { plainToClass, classToPlain, Type, Exclude, Transform, Expose } from 'class-transformer';
10
10
  import { JwtHelperService } from '@auth0/angular-jwt';
11
11
  import { __decorate, __awaiter } from 'tslib';
@@ -21,7 +21,7 @@ import { throwError as throwError$1 } from 'rxjs/internal/observable/throwError'
21
21
  import cloneDeep$1 from 'lodash/cloneDeep';
22
22
  import compact from 'lodash/compact';
23
23
  import { DateRange } from 'moment-range';
24
- import { Validators, FormGroup, FormControl, FormArray } from '@angular/forms';
24
+ import { Validators, FormGroup, FormArray, FormControl } from '@angular/forms';
25
25
  import fromPairs from 'lodash/fromPairs';
26
26
  import _ from 'lodash';
27
27
  import { EventSourcePolyfill } from 'event-source-polyfill/src/eventsource.min.js';
@@ -2107,6 +2107,12 @@ class Collection {
2107
2107
  removeBy(path, values) {
2108
2108
  return this.filter((item) => !(Array.isArray(values) ? values : [values]).includes(get(item, path)));
2109
2109
  }
2110
+ minBy(path) {
2111
+ return this.items.reduce((prev, current) => (get(prev, path) < get(current, path) ? prev : current));
2112
+ }
2113
+ maxBy(path) {
2114
+ return this.items.reduce((prev, current) => (get(prev, path) > get(current, path) ? prev : current));
2115
+ }
2110
2116
  }
2111
2117
 
2112
2118
  var TaxExemptionMetadataEnum;
@@ -4389,10 +4395,16 @@ var IncomeSourceTypeListOtherEnum;
4389
4395
  (function (IncomeSourceTypeListOtherEnum) {
4390
4396
  IncomeSourceTypeListOtherEnum[IncomeSourceTypeListOtherEnum["PSI"] = 6] = "PSI";
4391
4397
  IncomeSourceTypeListOtherEnum[IncomeSourceTypeListOtherEnum["SOLE_TRADER"] = 7] = "SOLE_TRADER";
4392
- IncomeSourceTypeListOtherEnum[IncomeSourceTypeListOtherEnum["PARTNERSHIPS_AND_TRUSTS"] = 9] = "PARTNERSHIPS_AND_TRUSTS";
4398
+ IncomeSourceTypeListOtherEnum[IncomeSourceTypeListOtherEnum["TRUSTS"] = 9] = "TRUSTS";
4393
4399
  IncomeSourceTypeListOtherEnum[IncomeSourceTypeListOtherEnum["OTHER_INCOME"] = 10] = "OTHER_INCOME";
4400
+ IncomeSourceTypeListOtherEnum[IncomeSourceTypeListOtherEnum["PARTNERSHIPS"] = 12] = "PARTNERSHIPS";
4394
4401
  })(IncomeSourceTypeListOtherEnum || (IncomeSourceTypeListOtherEnum = {}));
4395
4402
 
4403
+ var IncomeSourceTypeListSoleEnum;
4404
+ (function (IncomeSourceTypeListSoleEnum) {
4405
+ IncomeSourceTypeListSoleEnum[IncomeSourceTypeListSoleEnum["SOLE_TRADER"] = 7] = "SOLE_TRADER";
4406
+ })(IncomeSourceTypeListSoleEnum || (IncomeSourceTypeListSoleEnum = {}));
4407
+
4396
4408
  class IncomeSourceType extends IncomeSourceType$1 {
4397
4409
  isBonuses() {
4398
4410
  return this.id === IncomeSourceTypeListWorkEnum.BONUSES;
@@ -4404,8 +4416,7 @@ class IncomeSourceType extends IncomeSourceType$1 {
4404
4416
  return !!IncomeSourceTypeListOtherEnum[this.id];
4405
4417
  }
4406
4418
  isSole() {
4407
- // @TODO use IncomeSourceTypeListSoleEnum when sole tank ready
4408
- return !!IncomeSourceTypeListOtherEnum[this.id];
4419
+ return !!IncomeSourceTypeListSoleEnum[this.id];
4409
4420
  }
4410
4421
  get type() {
4411
4422
  switch (true) {
@@ -5567,6 +5578,13 @@ var ChartAccountsHeadingListEnum;
5567
5578
  ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["HOME_OFFICE_RUNNING"] = 17] = "HOME_OFFICE_RUNNING";
5568
5579
  ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["TOOLS_EQUIPMENT"] = 18] = "TOOLS_EQUIPMENT";
5569
5580
  ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["HOME_OFFICE_OCCUPANCY"] = 19] = "HOME_OFFICE_OCCUPANCY";
5581
+ ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["AWARD_OVERTIME_MEAL_ALLOWANCE_EXPENSE"] = 20] = "AWARD_OVERTIME_MEAL_ALLOWANCE_EXPENSE";
5582
+ ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["NEWSPAPER"] = 21] = "NEWSPAPER";
5583
+ ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["PRINTING_POSTAGE_STATIONERY"] = 22] = "PRINTING_POSTAGE_STATIONERY";
5584
+ ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["SEMINARS_ETC"] = 23] = "SEMINARS_ETC";
5585
+ ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["TELEPHONE"] = 24] = "TELEPHONE";
5586
+ ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["UNION_FEES"] = 25] = "UNION_FEES";
5587
+ ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["OTHER"] = 26] = "OTHER";
5570
5588
  ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["DONATIONS"] = 27] = "DONATIONS";
5571
5589
  ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["PSI"] = 30] = "PSI";
5572
5590
  ChartAccountsHeadingListEnum[ChartAccountsHeadingListEnum["BONUSES"] = 34] = "BONUSES";
@@ -5657,10 +5675,20 @@ var DepreciationWriteOffAmountEnum;
5657
5675
  DepreciationWriteOffAmountEnum[DepreciationWriteOffAmountEnum["BORROWING_EXPENSES"] = 100] = "BORROWING_EXPENSES";
5658
5676
  })(DepreciationWriteOffAmountEnum || (DepreciationWriteOffAmountEnum = {}));
5659
5677
 
5660
- var IncomeSourceTypeListSoleEnum;
5661
- (function (IncomeSourceTypeListSoleEnum) {
5662
- IncomeSourceTypeListSoleEnum[IncomeSourceTypeListSoleEnum["SOLE_TRADER"] = 7] = "SOLE_TRADER";
5663
- })(IncomeSourceTypeListSoleEnum || (IncomeSourceTypeListSoleEnum = {}));
5678
+ var IncomeSourceForecastTrustTypeEnum;
5679
+ (function (IncomeSourceForecastTrustTypeEnum) {
5680
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["SPECIAL_DISABILITY_TRUST"] = 1] = "SPECIAL_DISABILITY_TRUST";
5681
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["DECEASED_ESTATE"] = 2] = "DECEASED_ESTATE";
5682
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["FIXED_TRUST"] = 3] = "FIXED_TRUST";
5683
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["HYBRID_TRUST"] = 4] = "HYBRID_TRUST";
5684
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["DISCRETIONARY_SERVICE_TRUST"] = 5] = "DISCRETIONARY_SERVICE_TRUST";
5685
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["DISCRETIONARY_TRADING_TRUST"] = 6] = "DISCRETIONARY_TRADING_TRUST";
5686
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["DISCRETIONARY_INVESTMENT_TRUST"] = 7] = "DISCRETIONARY_INVESTMENT_TRUST";
5687
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["CASH_MANAGEMENT_UNIT_TRUST"] = 8] = "CASH_MANAGEMENT_UNIT_TRUST";
5688
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["PUBLIC_UNIT_TRUST_LISTED"] = 9] = "PUBLIC_UNIT_TRUST_LISTED";
5689
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["PUBLIC_UNIT_TRUST_UNLISTED"] = 10] = "PUBLIC_UNIT_TRUST_UNLISTED";
5690
+ IncomeSourceForecastTrustTypeEnum[IncomeSourceForecastTrustTypeEnum["TESTAMENTARY_TRUST"] = 11] = "TESTAMENTARY_TRUST";
5691
+ })(IncomeSourceForecastTrustTypeEnum || (IncomeSourceForecastTrustTypeEnum = {}));
5664
5692
 
5665
5693
  var InviteStatusEnum;
5666
5694
  (function (InviteStatusEnum) {
@@ -7429,7 +7457,14 @@ const DEDUCTION_CATEGORIES = {
7429
7457
  ChartAccountsHeadingListEnum.OTHER_WORK_RELATED_EXPENSES,
7430
7458
  ChartAccountsHeadingListEnum.SUBSCRIPTIONS,
7431
7459
  ChartAccountsHeadingListEnum.HOME_OFFICE_RUNNING,
7432
- ChartAccountsHeadingListEnum.HOME_OFFICE_OCCUPANCY
7460
+ ChartAccountsHeadingListEnum.HOME_OFFICE_OCCUPANCY,
7461
+ ChartAccountsHeadingListEnum.AWARD_OVERTIME_MEAL_ALLOWANCE_EXPENSE,
7462
+ ChartAccountsHeadingListEnum.NEWSPAPER,
7463
+ ChartAccountsHeadingListEnum.PRINTING_POSTAGE_STATIONERY,
7464
+ ChartAccountsHeadingListEnum.SEMINARS_ETC,
7465
+ ChartAccountsHeadingListEnum.TELEPHONE,
7466
+ ChartAccountsHeadingListEnum.UNION_FEES,
7467
+ ChartAccountsHeadingListEnum.OTHER
7433
7468
  ],
7434
7469
  workRelatedSelfEducationExpenses: [
7435
7470
  ChartAccountsHeadingListEnum.SELF_EDUCATIONAL_EXPENSES
@@ -7505,45 +7540,45 @@ class MyTaxDeductions {
7505
7540
  this.workRelatedClothingExpenses = this.transactions
7506
7541
  .filterBy('chartAccounts.heading.id', DEDUCTION_CATEGORIES.workRelatedClothingExpenses);
7507
7542
  this.personalSuperContributions = this.transactions
7508
- .filterBy('chartAccounts.heading.id', DEDUCTION_CATEGORIES.personalSuperContributions);
7543
+ .filterBy('chartAccounts.id', DEDUCTION_CATEGORIES.personalSuperContributions);
7509
7544
  this.workRelatedSelfEducationExpenses = this.transactions
7510
7545
  .filterBy('chartAccounts.heading.id', DEDUCTION_CATEGORIES.workRelatedSelfEducationExpenses);
7511
7546
  this.vehicleExpensesTotalAmount = this.getVehicleExpensesTotalAmount();
7512
7547
  this.workRelatedTravelExpensesTotalAmount = this.transactions
7513
7548
  .filterBy('chartAccounts.heading.id', ChartAccountsHeadingListEnum.WORK_RELATED_TRAVEL_EXPENSES)
7514
- .sumBy('amount');
7549
+ .sumBy('claimAmount');
7515
7550
  this.workRelatedClothingType = this.workRelatedClothingExpenses.length ? DeductionClothingTypeEnum.COMPULSORY_C : null;
7516
- this.workRelatedClothingTotalAmount = this.workRelatedClothingExpenses.sumBy('amount');
7551
+ this.workRelatedClothingTotalAmount = this.workRelatedClothingExpenses.sumBy('claimAmount');
7517
7552
  this.workRelatedSelfEducationType = this.workRelatedSelfEducationExpenses.length ?
7518
7553
  DeductionSelfEducationTypeEnum.IMPROVE_SKILLS_FOR_CURRENT_EARNINGS_K : null;
7519
- this.workRelatedSelfEducationTotalAmount = this.workRelatedSelfEducationExpenses.sumBy('amount');
7554
+ this.workRelatedSelfEducationTotalAmount = this.workRelatedSelfEducationExpenses.sumBy('claimAmount');
7520
7555
  this.lowValuePoolDeductionTotalAmount = this.depreciations.getByTankType(TankTypeEnum.WORK)
7521
7556
  .getLowValuePoolDepreciations().sumBy('claimAmount');
7522
7557
  this.interestExpensesTotalAmount = this.transactions
7523
7558
  .filterBy('chartAccounts.heading.id', DEDUCTION_CATEGORIES.interestExpenses)
7524
- .sumBy('amount');
7559
+ .sumBy('claimAmount');
7525
7560
  this.dividendExpensesTotalAmount = this.transactions
7526
7561
  .filterBy('chartAccounts.heading.id', DEDUCTION_CATEGORIES.dividendExpenses)
7527
- .sumBy('amount');
7562
+ .sumBy('claimAmount');
7528
7563
  this.donationsTotalAmount = this.transactions
7529
7564
  .filterBy('chartAccounts.heading.id', DEDUCTION_CATEGORIES.donations)
7530
- .sumBy('amount');
7565
+ .sumBy('claimAmount');
7531
7566
  this.interestsChargedByATOTotalAmount = this.transactions
7532
7567
  .filterBy('chartAccounts.id', DEDUCTION_CATEGORIES.interestsChargedByATO)
7533
- .sumBy('amount');
7568
+ .sumBy('claimAmount');
7534
7569
  this.litigationCostsTotalAmount = this.transactions
7535
7570
  .filterBy('chartAccounts.id', DEDUCTION_CATEGORIES.litigationCosts)
7536
- .sumBy('amount');
7571
+ .sumBy('claimAmount');
7537
7572
  this.otherManagingCostsTotalAmount = this.transactions
7538
7573
  .filterBy('chartAccounts.id', DEDUCTION_CATEGORIES.otherManagingCosts)
7539
- .sumBy('amount');
7540
- this.personalSuperContributionsTotalAmount = this.personalSuperContributions.sumBy('amount');
7574
+ .sumBy('claimAmount');
7575
+ this.personalSuperContributionsTotalAmount = this.personalSuperContributions.sumBy('claimAmount');
7541
7576
  this.forestryManagedInvestmentSchemesDeductionsTotalAmount = this.transactions
7542
7577
  .filterBy('chartAccounts.id', DEDUCTION_CATEGORIES.forestryManagedInvestmentSchemesDeductions)
7543
- .sumBy('amount');
7578
+ .sumBy('claimAmount');
7544
7579
  this.otherDeductionsTotalAmount = this.transactions
7545
7580
  .filterBy('chartAccounts.id', DEDUCTION_CATEGORIES.otherDeductions)
7546
- .sumBy('amount');
7581
+ .sumBy('claimAmount');
7547
7582
  }
7548
7583
  getVehicleExpensesTotalAmount() {
7549
7584
  var _a;
@@ -7554,7 +7589,7 @@ class MyTaxDeductions {
7554
7589
  }
7555
7590
  setVehicleClaimData() {
7556
7591
  this.klmsMethodClaimAmount = this.vehicleClaim.getKLMsClaimAmount(this.vehicleClaimRate);
7557
- this.totalExpensesAmount = new VehicleExpenseCollection(this.transactions.getByTankType(this.vehicleClaim.tankType), this.depreciations.getByTankType(this.vehicleClaim.tankType), this.vehicleClaim).sumBy('amount');
7592
+ this.totalExpensesAmount = new VehicleExpenseCollection(this.transactions.getByTankType(this.vehicleClaim.tankType), this.depreciations.getByTankType(this.vehicleClaim.tankType), this.vehicleClaim).sumBy('claimAmount');
7558
7593
  }
7559
7594
  /**
7560
7595
  * Total amount from Other work related expenses and Tools & equipment depreciations
@@ -7562,7 +7597,7 @@ class MyTaxDeductions {
7562
7597
  setOtherWorkRelatedExpensesTotalAmount() {
7563
7598
  const otherIncomeRelatedExpenses = this.transactions
7564
7599
  .filterBy('chartAccounts.heading.id', DEDUCTION_CATEGORIES.otherIncomeRelatedExpenses);
7565
- this.otherWorkRelatedExpensesTotalAmount = Math.abs(otherIncomeRelatedExpenses.sumBy('amount')) +
7600
+ this.otherWorkRelatedExpensesTotalAmount = Math.abs(otherIncomeRelatedExpenses.sumBy('claimAmount')) +
7566
7601
  this.depreciations.filterBy('chartAccounts.heading.id', ChartAccountsHeadingListEnum.TOOLS_EQUIPMENT).sumBy('claimAmount');
7567
7602
  }
7568
7603
  }
@@ -7616,8 +7651,8 @@ class MyTaxEstimate {
7616
7651
  const taxOffsetsReportItem = summarySection.items.findBy('taxReturnCategory.id', TaxReturnCategoryListEnum.TAX_OFFSETS);
7617
7652
  const lowMiddleIncomeTaxOffsets = this.getLowMiddleIncomeTaxOffsets(taxOffsetsReportItem);
7618
7653
  const taxPayable = grossTaxPayableReportItem.items.findBy('taxReturnCategory.id', TaxReturnCategoryListEnum.TAX_ON_TAXABLE_INCOME).amount;
7619
- const medicareLevy = medicareReportItem.details.findBy('name', 'Medicare Levy Surcharge').amount;
7620
- const medicareLevySurcharge = medicareReportItem.details.findBy('name', 'Medicare Levy (based on single)').amount;
7654
+ const medicareLevy = medicareReportItem.details.findBy('name', 'Medicare Levy (based on single)').amount;
7655
+ const medicareLevySurcharge = medicareReportItem.details.findBy('name', 'Medicare Levy Surcharge').amount;
7621
7656
  const taxCredits = summarySection.items.findBy('taxReturnCategory.id', TaxReturnCategoryListEnum.TAX_CREDITS).amount;
7622
7657
  const taxOffsets = this.getTaxOffsets(taxOffsetsReportItem.amount, lowMiddleIncomeTaxOffsets);
7623
7658
  return plainToClass(MyTaxEstimate, {
@@ -7722,7 +7757,7 @@ class MyTaxInterest {
7722
7757
  this.interestPaidTransactions = transactions.filterBy('chartAccounts.id', ChartAccountsListEnum.ATO_INTEREST_PAID);
7723
7758
  this.interestEarnedTotalAmount = this.interestEarnedTransactions.sumBy('amount');
7724
7759
  this.interestEarnedTotalTax = this.interestEarnedTransactions.sumBy('tax');
7725
- this.interestPaidTotalAmount = this.interestEarnedTransactions.sumBy('amount');
7760
+ this.interestPaidTotalAmount = this.interestPaidTransactions.sumBy('amount');
7726
7761
  }
7727
7762
  }
7728
7763
 
@@ -7770,12 +7805,14 @@ class MyTaxOtherIncome {
7770
7805
  }
7771
7806
 
7772
7807
  class MyTaxPartnershipsAndTrusts {
7773
- constructor(transactions) {
7808
+ constructor(transactions, incomeSources) {
7774
7809
  this.transactions = transactions;
7810
+ this.incomeSources = incomeSources;
7775
7811
  this.partnershipIncomes = this.transactions.filterBy('chartAccounts.id', ChartAccountsListEnum.PARTNERSHIP_INCOME);
7776
7812
  this.partnershipExpenses = this.transactions.filterBy('chartAccounts.id', ChartAccountsListEnum.PARTNERSHIP_EXPENSES);
7777
7813
  this.trustsIncomes = this.transactions.filterBy('chartAccounts.id', ChartAccountsListEnum.TRUST_INCOME);
7778
7814
  this.trustsExpenses = this.transactions.filterBy('chartAccounts.id', ChartAccountsListEnum.TRUST_EXPENSES);
7815
+ this.trustType = this.getTrustType();
7779
7816
  this.netNonPrimaryProductionAmount = (this.partnershipIncomes.sumBy('amount') - this.partnershipExpenses.sumBy('amount')) +
7780
7817
  (this.trustsIncomes.sumBy('amount') - this.trustsExpenses.sumBy('amount'));
7781
7818
  this.partnershipsNetIncome = this.partnershipIncomes.sumBy('amount') -
@@ -7795,29 +7832,70 @@ class MyTaxPartnershipsAndTrusts {
7795
7832
  .sumBy('value');
7796
7833
  this.taxOffsetNRASTotalAmount = this.transactions.filterBy('chartAccounts.id', ChartAccountsListEnum.TAX_OFFSETS_N_R_A_S).sumBy('amount');
7797
7834
  }
7835
+ /**
7836
+ * Get Income source forecast trust type, related to trust income with max amount
7837
+ */
7838
+ getTrustType() {
7839
+ const filteredTrustIncomes = this.trustsIncomes
7840
+ .filterBy('incomeSource.id', this.incomeSources
7841
+ .removeBy('actualForecast.trustType', null)
7842
+ .getIds());
7843
+ if (!filteredTrustIncomes.length) {
7844
+ return null;
7845
+ }
7846
+ return this.incomeSources
7847
+ .findBy('id', filteredTrustIncomes.maxBy('amount').incomeSource.id)
7848
+ .actualForecast
7849
+ .trustType;
7850
+ }
7798
7851
  }
7799
7852
 
7800
7853
  class MyTaxRent {
7801
- constructor(transactions, depreciations) {
7854
+ constructor(transactions, depreciations, taxSummary) {
7802
7855
  this.propertyExpenses = transactions.getPropertyTransactions().getExpenseTransactions();
7856
+ this.taxSummaryPropertySection = taxSummary.property;
7803
7857
  this.grossRentAmount = transactions
7858
+ .getPropertyTransactions()
7804
7859
  .getIncomeTransactions()
7805
7860
  .filterBy('chartAccounts.id', ChartAccountsListEnum.RENTAL_INCOME)
7806
- .sumBy('amount') +
7807
- transactions.
7808
- getIncomeTransactions()
7861
+ .sumBy('claimAmount') +
7862
+ transactions
7863
+ .getPropertyTransactions()
7864
+ .getIncomeTransactions()
7809
7865
  .filterBy('chartAccounts.id', ChartAccountsListEnum.OTHER_RENTAL_INCOME)
7810
- .sumBy('amount');
7866
+ .sumBy('claimAmount');
7811
7867
  this.interestDeductionsAmount = Math.abs(transactions.getInterestTransactions().sumBy('amount'));
7812
7868
  this.capitalWorksDeductionsAmount = Math.abs(depreciations.getCapitalDepreciations().sumBy('claimAmount'));
7813
- this.otherRentalDeductionsAmount = Math.abs(depreciations.getAssets().sumBy('claimAmount') +
7814
- depreciations.getBorrowingExpenseDepreciations().sumBy('claimAmount') +
7815
- this.propertyExpenses.sumBy('amount'));
7869
+ this.otherRentalDeductionsAmount = this.calculateOtherRentalDeductionsAmount();
7870
+ /**
7871
+ * @Todo Vik uncomment when task TT-2009 will be implemented
7872
+ */
7873
+ // this.otherRentalDeductionsAmount = depreciations.getByTankType(TankTypeEnum.PROPERTY).getAssets().claimAmount +
7874
+ // depreciations.getByTankType(TankTypeEnum.PROPERTY).getBorrowingExpenseDepreciations().claimAmount +
7875
+ // Math.abs(this.propertyExpenses.sumBy('claimAmount'));
7816
7876
  this.netRent = this.grossRentAmount -
7817
7877
  this.interestDeductionsAmount -
7818
7878
  this.capitalWorksDeductionsAmount -
7819
7879
  this.otherRentalDeductionsAmount;
7820
7880
  }
7881
+ /**
7882
+ * @Todo Vik remove when TT-2009 will be implemented.
7883
+ * We use tax summary data here because claim amount from depreciation is different
7884
+ * from the claim amount that we get from tax summary (depreciation claim amount is not affected by property share,
7885
+ * property contract date, e.t.c.). Details in the TT-2009 task
7886
+ */
7887
+ calculateOtherRentalDeductionsAmount() {
7888
+ const plantAndEquipmentAmount = Math.abs(this.taxSummaryPropertySection.items
7889
+ .findBy('taxReturnCategory.id', TaxReturnCategoryListEnum.DEPRECIATION)
7890
+ .amount);
7891
+ const borrowingExpensesAmount = Math.abs(this.taxSummaryPropertySection.items
7892
+ .findBy('taxReturnCategory.id', TaxReturnCategoryListEnum.BORROWING_EXPENSES)
7893
+ .amount);
7894
+ const otherRentalDeductionsAmount = Math.abs(this.taxSummaryPropertySection.items
7895
+ .findBy('taxReturnCategory.id', TaxReturnCategoryListEnum.OTHER_RENTAL_DEDUCTIONS)
7896
+ .amount);
7897
+ return +Math.floor(plantAndEquipmentAmount + borrowingExpensesAmount + otherRentalDeductionsAmount).toFixed(2);
7898
+ }
7821
7899
  }
7822
7900
 
7823
7901
  /**
@@ -12541,6 +12619,7 @@ function taxReviewFilterPredicate(data, filter) {
12541
12619
 
12542
12620
  /**
12543
12621
  * Abstract form class
12622
+ * @TODO rename to AbstractFormGroup
12544
12623
  */
12545
12624
  class AbstractForm extends FormGroup {
12546
12625
  constructor(controls, model, validatorOrOpts, asyncValidator) {
@@ -12564,51 +12643,105 @@ class AbstractForm extends FormGroup {
12564
12643
  this.onSubmit.emit(model);
12565
12644
  return model;
12566
12645
  }
12646
+ addControl(name, control, options) {
12647
+ super.addControl(name, control, options);
12648
+ return this;
12649
+ }
12567
12650
  createModelInstance(data = {}) {
12568
12651
  return plainToClass(this.modelClass, data);
12569
12652
  }
12570
12653
  }
12571
12654
 
12655
+ function conditionalValidator(condition, validator) {
12656
+ return function (control) {
12657
+ revalidateOnChanges(control);
12658
+ if (control && control.parent) {
12659
+ if (condition(control.parent)) {
12660
+ return validator(control);
12661
+ }
12662
+ }
12663
+ return null;
12664
+ };
12665
+ }
12572
12666
  /**
12573
- * Form with bank account loan details
12667
+ * Conditional validator depends on other fields and should be updated on each form value change
12574
12668
  */
12575
- class BankAccountLoanForm extends AbstractForm {
12576
- constructor(loan = plainToClass(Loan, {})) {
12577
- super({
12578
- type: new FormControl(loan.type, Validators.required),
12579
- amount: new FormControl(loan.amount, Validators.required),
12580
- repaymentType: new FormControl(loan.repaymentType, Validators.required),
12581
- interestRate: new FormControl(loan.interestRate, [Validators.required, Validators.min(0), Validators.max(100)]),
12582
- interestType: new FormControl(loan.interestType, Validators.required),
12583
- availableRedraw: new FormControl(loan.availableRedraw, Validators.required),
12584
- commencementDate: new FormControl(loan.commencementDate, Validators.required),
12585
- repaymentAmount: new FormControl(loan.repaymentAmount, Validators.required),
12586
- repaymentFrequency: new FormControl(loan.repaymentFrequency, Validators.required)
12587
- }, loan);
12669
+ function revalidateOnChanges(control) {
12670
+ if (control && control.parent && !control['_revalidateOnChanges']) {
12671
+ control['_revalidateOnChanges'] = true;
12672
+ control.parent.valueChanges.pipe(distinctUntilChanged((a, b) => JSON.stringify(a) === JSON.stringify(b)))
12673
+ .subscribe(() => {
12674
+ control.updateValueAndValidity({ emitEvent: false });
12675
+ });
12588
12676
  }
12677
+ return;
12678
+ }
12679
+
12680
+ /**
12681
+ * Validator that check if sum amount of provided fields is greater than provided sum
12682
+ * @param field to check in each formArray element
12683
+ * @param summary to compare with fields sum
12684
+ * @param fieldAlias to show it in error message
12685
+ */
12686
+ function fieldsSumValidator(field, summary = 100, fieldAlias) {
12687
+ return (formArray) => {
12688
+ // calculate sum of desired fields in formArray control
12689
+ const fieldsSum = formArray['controls']
12690
+ .reduce((acc, group) => acc += group.get(field).value, 0);
12691
+ if (fieldsSum <= summary) {
12692
+ return null;
12693
+ }
12694
+ else {
12695
+ return {
12696
+ fieldsSum: {
12697
+ name: field,
12698
+ alias: fieldAlias,
12699
+ summary
12700
+ }
12701
+ };
12702
+ }
12703
+ };
12589
12704
  }
12590
12705
 
12591
12706
  /**
12592
12707
  * Form array with bank account properties
12708
+ * @TODO create AbstractFormArray
12593
12709
  */
12594
12710
  class BankAccountPropertiesForm extends FormArray {
12595
12711
  constructor(bankAccountProperties = [plainToClass(BankAccountProperty, {})]) {
12596
12712
  super(bankAccountProperties.map((bankAccountProperty) => {
12597
12713
  return new FormGroup({
12598
- property: new FormControl(bankAccountProperty.property, Validators.required),
12714
+ property: new FormControl(bankAccountProperty === null || bankAccountProperty === void 0 ? void 0 : bankAccountProperty.property, Validators.required),
12599
12715
  percent: new FormControl(bankAccountProperty.percent, Validators.required)
12600
12716
  });
12601
- }));
12717
+ }), [
12718
+ conditionalValidator((control) => control.get('tankType').value === TankTypeEnum.PROPERTY, Validators.required),
12719
+ fieldsSumValidator('percent', 100)
12720
+ ]);
12602
12721
  }
12603
12722
  add() {
12604
12723
  this.push(new FormGroup({
12605
12724
  property: new FormControl(null, Validators.required),
12606
- percent: new FormControl({
12607
- value: 100,
12608
- disabled: !this.at(0).contains('percent')
12609
- }, Validators.required)
12610
- }));
12611
- }
12725
+ // @TODO disable for loans
12726
+ percent: new FormControl({ value: 100, disabled: !this.at(0).contains('percent') }, Validators.required),
12727
+ // @TODO enable for loans
12728
+ // amount: new FormControl(
12729
+ // {value: this.bankAccount.currentBalance * bankAccountProperty.percent / 100},
12730
+ // [Validators.required, Validators.max(Math.abs(this.bankAccount.currentBalance))]
12731
+ // ),
12732
+ }));
12733
+ }
12734
+ // @TODO enable for loans
12735
+ // /**
12736
+ // * Recalculate property percentage for current property form group and round to no more than 3 decimal places
12737
+ // * @param amount: new control value
12738
+ // * @param currentPropertyGroup for which amount will be recalculated
12739
+ // */
12740
+ // recalculatePropertyPercentage(amount: number, currentPropertyGroup: FormGroup): void {
12741
+ // currentPropertyGroup.get('percent').setValue(
12742
+ // roundTo(amount / this.bankAccount.currentBalance, 3)
12743
+ // );
12744
+ // }
12612
12745
  enablePercent() {
12613
12746
  this.controls.forEach((propertyFormGroup) => {
12614
12747
  propertyFormGroup.get('percent').enable();
@@ -12621,36 +12754,23 @@ class BankAccountPropertiesForm extends FormArray {
12621
12754
  }
12622
12755
  }
12623
12756
 
12624
- /**
12625
- * Form is using for import basiq bank accounts.
12626
- * Basiq accounts has all data except tank type, properties and loan partially
12627
- */
12628
- class BankAccountImportForm extends AbstractForm {
12757
+ class BankAccountAllocationForm extends AbstractForm {
12629
12758
  constructor(bankAccount) {
12630
12759
  super({
12631
- tankType: new FormControl(bankAccount.tankType, Validators.required),
12632
- }, bankAccount);
12633
- if (bankAccount.isLoan()) {
12634
- this.addControl('loan', new BankAccountLoanForm(bankAccount.loan));
12760
+ tankType: new FormControl(bankAccount ? bankAccount.tankType : null, Validators.required),
12761
+ }, plainToClass(BankAccount, bankAccount || {}));
12762
+ this.bankAccount = bankAccount;
12763
+ if (bankAccount === null || bankAccount === void 0 ? void 0 : bankAccount.isPropertyTank()) {
12764
+ this.addControl('bankAccountProperties', new BankAccountPropertiesForm(bankAccount.bankAccountProperties));
12635
12765
  }
12636
- // basiq account import form should be disabled (unchecked) by default
12637
- this.disable();
12638
- this.listenEvents();
12639
- }
12640
- listenEvents() {
12641
- this.listenTankTypeChanges();
12766
+ this.watchTankType();
12642
12767
  }
12643
- /**
12644
- * Add/Remove bank account properties form depends on selected tank type
12645
- */
12646
- listenTankTypeChanges() {
12768
+ watchTankType() {
12647
12769
  this.get('tankType').valueChanges.subscribe((tankType) => {
12770
+ var _a;
12771
+ // @TODO vik add businessAllocation
12648
12772
  if (tankType === TankTypeEnum.PROPERTY) {
12649
- this.addControl('bankAccountProperties', new BankAccountPropertiesForm());
12650
- // property percent allowed only for loan bank accounts
12651
- if (!this.contains('loan')) {
12652
- this.get('bankAccountProperties').disablePercent();
12653
- }
12773
+ this.addControl('bankAccountProperties', new BankAccountPropertiesForm((_a = this.bankAccount) === null || _a === void 0 ? void 0 : _a.bankAccountProperties));
12654
12774
  }
12655
12775
  else {
12656
12776
  this.removeControl('bankAccountProperties');
@@ -12659,24 +12779,56 @@ class BankAccountImportForm extends AbstractForm {
12659
12779
  }
12660
12780
  }
12661
12781
 
12782
+ /**
12783
+ * Form with bank account loan details
12784
+ */
12785
+ class BankAccountLoanForm extends AbstractForm {
12786
+ constructor(loan = plainToClass(Loan, {})) {
12787
+ super({
12788
+ type: new FormControl(loan.type, Validators.required),
12789
+ amount: new FormControl(loan.amount, Validators.required),
12790
+ repaymentType: new FormControl(loan.repaymentType, Validators.required),
12791
+ interestRate: new FormControl(loan.interestRate, [Validators.required, Validators.min(0), Validators.max(100)]),
12792
+ interestType: new FormControl(loan.interestType, Validators.required),
12793
+ availableRedraw: new FormControl(loan.availableRedraw, Validators.required),
12794
+ commencementDate: new FormControl(loan.commencementDate, Validators.required),
12795
+ repaymentAmount: new FormControl(loan.repaymentAmount, Validators.required),
12796
+ repaymentFrequency: new FormControl(loan.repaymentFrequency, Validators.required)
12797
+ }, loan);
12798
+ }
12799
+ }
12800
+
12801
+ /**
12802
+ * Form is using for import basiq bank accounts.
12803
+ * Basiq accounts has all data except tank type, properties and loan partially
12804
+ */
12805
+ class BankAccountImportForm extends BankAccountAllocationForm {
12806
+ constructor(bankAccount) {
12807
+ super(bankAccount);
12808
+ if (bankAccount.isLoan()) {
12809
+ this.addControl('loan', new BankAccountLoanForm(bankAccount.loan));
12810
+ }
12811
+ // basiq account import form should be disabled (unchecked) by default
12812
+ this.disable();
12813
+ }
12814
+ }
12815
+
12662
12816
  /**
12663
12817
  * Form is using for single manual bank account creation (not Basiq)
12664
12818
  */
12665
- class BankAccountAddManualForm extends AbstractForm {
12819
+ class BankAccountAddManualForm extends BankAccountAllocationForm {
12666
12820
  constructor(connection) {
12667
- super({
12668
- type: new FormControl(null, Validators.required),
12669
- accountName: new FormControl(null, Validators.required),
12670
- currentBalance: new FormControl(null, Validators.required),
12671
- accountNumber: new FormControl(null, [Validators.required, Validators.pattern(BankAccountAddManualForm.accountNumberPattern)]),
12672
- tankType: new FormControl(null, Validators.required),
12673
- }, plainToClass(BankAccount, {}));
12821
+ super();
12674
12822
  this.connection = connection;
12823
+ this
12824
+ .addControl('type', new FormControl(null, Validators.required))
12825
+ .addControl('accountName', new FormControl(null, Validators.required))
12826
+ .addControl('currentBalance', new FormControl(null, Validators.required))
12827
+ .addControl('accountNumber', new FormControl(null, [Validators.required, Validators.pattern(BankAccountAddManualForm.accountNumberPattern)]));
12675
12828
  this.listenEvents();
12676
12829
  }
12677
12830
  listenEvents() {
12678
12831
  this.listenTypeChanges();
12679
- this.listenTankTypeChanges();
12680
12832
  }
12681
12833
  /**
12682
12834
  * Add/Remove loan form depends on selected bank account type
@@ -12685,37 +12837,9 @@ class BankAccountAddManualForm extends AbstractForm {
12685
12837
  this.get('type').valueChanges.subscribe((type) => {
12686
12838
  if (BankAccount.loanTypes.includes(type)) {
12687
12839
  this.addControl('loan', new BankAccountLoanForm());
12688
- // property percent allowed only for loan bank accounts
12689
- if (this.contains('bankAccountProperties')) {
12690
- this.get('bankAccountProperties').enablePercent();
12691
- }
12692
12840
  }
12693
12841
  else {
12694
12842
  this.removeControl('loan');
12695
- // property percent allowed only for loan bank accounts
12696
- if (this.contains('bankAccountProperties')) {
12697
- this.get('bankAccountProperties').disablePercent();
12698
- }
12699
- }
12700
- });
12701
- }
12702
- /**
12703
- * Add/Remove bank account properties form depends on selected tank type
12704
- */
12705
- listenTankTypeChanges() {
12706
- this.get('tankType').valueChanges.subscribe((tankType) => {
12707
- if (tankType === TankTypeEnum.PROPERTY) {
12708
- this.addControl('bankAccountProperties', new BankAccountPropertiesForm());
12709
- // property percent allowed only for loan bank accounts
12710
- if (this.contains('loan')) {
12711
- this.get('bankAccountProperties').enablePercent();
12712
- }
12713
- else {
12714
- this.get('bankAccountProperties').disablePercent();
12715
- }
12716
- }
12717
- else {
12718
- this.removeControl('bankAccountProperties');
12719
12843
  }
12720
12844
  });
12721
12845
  }
@@ -13099,12 +13223,12 @@ class MyTaxDeductionsForm extends AbstractForm {
13099
13223
  value: deductions.workRelatedTravelExpensesTotalAmount,
13100
13224
  disabled: true
13101
13225
  }),
13102
- workRelatedClothingType: new FormControl(deductions.workRelatedClothingType, Validators.required),
13226
+ workRelatedClothingType: new FormControl(deductions.workRelatedClothingType, conditionalValidator(() => !!deductions.workRelatedClothingTotalAmount, Validators.required)),
13103
13227
  workRelatedClothingTotalAmount: new FormControl({
13104
13228
  value: deductions.workRelatedClothingTotalAmount,
13105
13229
  disabled: true
13106
13230
  }),
13107
- workRelatedSelfEducationType: new FormControl(deductions.workRelatedSelfEducationType, Validators.required),
13231
+ workRelatedSelfEducationType: new FormControl(deductions.workRelatedSelfEducationType, conditionalValidator(() => !!deductions.workRelatedSelfEducationTotalAmount, Validators.required)),
13108
13232
  workRelatedSelfEducationTotalAmount: new FormControl({
13109
13233
  value: deductions.workRelatedSelfEducationTotalAmount,
13110
13234
  disabled: true
@@ -13141,6 +13265,11 @@ class MyTaxDeductionsForm extends AbstractForm {
13141
13265
  value: deductions.otherManagingCostsTotalAmount,
13142
13266
  disabled: true
13143
13267
  }),
13268
+ fundName: new FormControl(''),
13269
+ hasFund: new FormControl(false),
13270
+ fundABN: new FormControl(''),
13271
+ fundTFN: new FormControl(''),
13272
+ fundAccountNumber: new FormControl(''),
13144
13273
  personalSuperContributionsTotalAmount: new FormControl({
13145
13274
  value: deductions.personalSuperContributionsTotalAmount,
13146
13275
  disabled: true
@@ -13394,7 +13523,9 @@ class MyTaxPartnershipsAndTrustsForm extends AbstractForm {
13394
13523
  value: partnershipsAndTrusts.trustsNetIncome,
13395
13524
  disabled: true
13396
13525
  }),
13397
- trustType: new FormControl(1),
13526
+ trustType: new FormControl(partnershipsAndTrusts.trustType, conditionalValidator((control) => {
13527
+ return !!partnershipsAndTrusts.trustsIncomes.length;
13528
+ }, Validators.required)),
13398
13529
  partnershipsSmallBusinessNetIncome: new FormControl(partnershipsAndTrusts.partnershipsSmallBusinessNetIncome, Validators.required),
13399
13530
  trustsSmallBusinessNetIncome: new FormControl(partnershipsAndTrusts.trustsSmallBusinessNetIncome, Validators.required),
13400
13531
  taxPaidTotal: new FormControl({
@@ -13432,5 +13563,5 @@ class MyTaxRentForm extends AbstractForm {
13432
13563
  * Generated bundle index. Do not edit.
13433
13564
  */
13434
13565
 
13435
- export { AbstractForm, AbstractModel, AccountSetupItem, AccountSetupItemCollection, AccountSetupService, Address, AddressService, AddressTypeEnum, AlphabetColorsEnum, AppEvent, AppEventTypeEnum, AssetEntityTypeEnum, AssetTypeEnum, AssetsService, AuthService, BANK_ACCOUNT_TYPES, Badge, BadgeColorEnum, Bank, BankAccount, BankAccountAddManualForm, BankAccountCalculationService, BankAccountChartData, BankAccountCollection, BankAccountImportForm, BankAccountLoanForm, BankAccountPropertiesForm, BankAccountProperty, BankAccountService, BankAccountStatusEnum, BankAccountTypeEnum, BankAccountsImportForm, BankConnection, BankConnectionService, BankConnectionStatusEnum, BankLoginData, BankLoginForm, BankService, BankTransaction, BankTransactionCalculationService, BankTransactionChartData, BankTransactionCollection, BankTransactionService, BankTransactionSummaryFieldsEnum, BankTransactionTypeEnum, BasiqConfig, BasiqJob, BasiqService, BasiqToken, BorrowingExpense, BorrowingExpenseLoan, BorrowingExpenseService, CAPITAL_COSTS_ITEMS, CHART_ACCOUNTS_CATEGORIES, CalculationFormItem, CalculationFormTypeEnum, ChartAccounts, ChartAccountsCategoryEnum, ChartAccountsCollection, ChartAccountsDepreciation, ChartAccountsDepreciationService, ChartAccountsEtpEnum, ChartAccountsHeading, ChartAccountsHeadingListEnum, ChartAccountsHeadingTaxDeductibleEnum, ChartAccountsHeadingTaxableEnum, ChartAccountsHeadingVehicleListEnum, ChartAccountsListEnum, ChartAccountsMetadata, ChartAccountsMetadataListEnum, ChartAccountsMetadataTypeEnum, ChartAccountsService, ChartAccountsTaxLabelsEnum, ChartAccountsTypeEnum, ChartAccountsValue, ChartData, ChartSerie, Chat, ChatService, ChatStatusEnum, ChatViewTypeEnum, ClientCollection, ClientDetails, ClientDetailsMedicareExemptionEnum, ClientDetailsWorkDepreciationCalculationEnum, ClientDetailsWorkingHolidayMakerEnum, ClientIncomeTypes, ClientIncomeTypesForm, ClientIncomeTypesService, ClientInvite, ClientInviteService, ClientInviteStatusEnum, ClientInviteTypeEnum, ClientMovement, ClientMovementCollection, ClientMovementService, ClientPortfolioChartData, ClientPortfolioReport, ClientPortfolioReportCollection, ClientPortfolioReportService, Collection, CollectionDictionary, CorelogicService, CorelogicSuggestion, Country, DEDUCTION_CATEGORIES, DEFAULT_VEHICLE_EXPENSE, DEPRECIATION_GROUPS, DOCUMENT_FILE_TYPES, DeductionClothingTypeEnum, DeductionSelfEducationTypeEnum, Depreciation, DepreciationCalculationEnum, DepreciationCalculationPercentEnum, DepreciationCapitalProject, DepreciationCapitalProjectService, DepreciationCollection, DepreciationForecast, DepreciationForecastCollection, DepreciationGroup, DepreciationGroupEnum, DepreciationGroupItem, DepreciationLvpAssetTypeEnum, DepreciationLvpReportItem, DepreciationLvpReportItemCollection, DepreciationReceipt, DepreciationReportItem, DepreciationReportItemCollection, DepreciationService, DepreciationTypeEnum, DepreciationWriteOffAmountEnum, Dictionary, Document, DocumentApiUrlPrefixEnum, DocumentFolder, DocumentFolderService, ENDPOINTS, EmployeeCollection, EmployeeDetails, EmployeeInvite, EmployeeInviteService, EmployeeService, Endpoint, EquityPositionChartService, EventDispatcherService, ExportDataTable, ExportFormatEnum, ExportFormatterService, ExportableCollection, FacebookService, FinancialYear, Firm, FirmService, FirmTypeEnum, HeaderTitleService, IconsFileEnum, IncomeAmountTypeEnum, IncomePosition, IncomeSource, IncomeSourceChartData, IncomeSourceCollection, IncomeSourceForecast, IncomeSourceForecastService, IncomeSourceService, IncomeSourceType, IncomeSourceTypeEnum, IncomeSourceTypeListOtherEnum, IncomeSourceTypeListSoleEnum, IncomeSourceTypeListWorkEnum, InterceptorsModule, IntercomService, InviteStatusEnum, JwtService, KompassifyService, Loan, LoanBankTypeEnum, LoanCollection, LoanFrequencyEnum, LoanInterestTypeEnum, LoanMaxNumberOfPaymentsEnum, LoanPayment, LoanPaymentCollection, LoanPayout, LoanPayoutTypeEnum, LoanRepaymentFrequencyEnum, LoanRepaymentTypeEnum, LoanService, LoanTypeEnum, LoanVehicleTypeEnum, LogbookPeriod, LoginForm, MODULE_URL_LIST, MONTHS, Message, MessageCollection, MessageDocument, MessageDocumentCollection, MessageDocumentService, MessageService, MonthNameShortEnum, MonthNumberEnum, MyAccountHistory, MyAccountHistoryInitiatedByEnum, MyAccountHistoryStatusEnum, MyAccountHistoryTypeEnum, MyTaxBusinessOrLosses, MyTaxBusinessOrLossesForm, MyTaxDeductions, MyTaxDeductionsForm, MyTaxDividends, MyTaxDividendsForm, MyTaxEmployeeShareSchemes, MyTaxEmployeeShareSchemesForm, 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, PdfOrientationEnum, PdfSettings, Phone, PhoneTypeEnum, PreloaderService, Property, PropertyCalculationService, PropertyCategory, PropertyCategoryListEnum, PropertyCategoryMovement, PropertyCategoryMovementService, PropertyCategoryService, PropertyCollection, PropertyDepreciationCalculationEnum, PropertyDocument, PropertyDocumentService, PropertyEquityChartData, PropertyEquityChartItem, PropertyForecast, PropertyReportItem, PropertyReportItemCollection, PropertyReportItemDepreciationCollection, PropertyReportItemTransaction, PropertyReportItemTransactionCollection, PropertySale, PropertySaleService, PropertySaleTaxExemptionMetadata, PropertyService, PropertyShare, PropertyShareAccessEnum, PropertyShareService, PropertyShareStatusEnum, PropertySubscription, PropertyTransactionReportService, PropertyValuation, RegisterClientForm, RegisterFirmForm, RegistrationInvite, RegistrationInviteStatusEnum, ReportItem, ReportItemCollection, ReportItemDetails, ResetPasswordForm, SUBSCRIPTION_DESCRIPTION, SUBSCRIPTION_TITLE, SalaryForecast, SalaryForecastFrequencyEnum, SalaryForecastService, ServiceNotificationService, ServiceNotificationStatusEnum, ServiceNotificationTypeEnum, ServicePayment, ServicePaymentStatusEnum, ServicePrice, ServicePriceRecurringIntervalEnum, ServicePriceService, ServicePriceTypeEnum, ServiceProduct, ServiceProductIdEnum, ServiceProductStatusEnum, ServiceSubscription, ServiceSubscriptionCollection, ServiceSubscriptionItem, ServiceSubscriptionStatusEnum, ShareFilterOptionsEnum, SoleForecast, SoleForecastService, SpareDocumentSpareTypeEnum, SseService, SubscriptionService, SubscriptionTypeEnum, TAX_RETURN_CATEGORIES, TYPE_LOAN, TankTypeEnum, TaxCalculationMedicareExemptionEnum, TaxCalculationTypeEnum, TaxExemption, TaxExemptionEnum, TaxExemptionMetadata, TaxExemptionMetadataEnum, 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, TransactionCalculationService, TransactionCategoryEnum, TransactionCollection, TransactionMetadata, TransactionOperationEnum, TransactionReceipt, TransactionService, TransactionSourceEnum, TransactionTypeEnum, TtCoreModule, USER_ROLES, USER_WORK_POSITION, User, UserEventSetting, UserEventSettingCollection, UserEventSettingFieldEnum, UserEventSettingService, UserEventStatusEnum, UserEventType, UserEventTypeCategory, UserEventTypeClientTypeEnum, UserEventTypeEmployeeTypeEnum, UserEventTypeFrequencyEnum, UserEventTypeService, UserEventTypeUserTypeEnum, UserMedicareExemptionEnum, UserRolesEnum, UserService, UserStatusEnum, UserSwitcherService, UserTitleEnum, UserToRegister, UserWorkDepreciationCalculationEnum, UserWorkingHolidayMakerEnum, Vehicle, VehicleClaim, VehicleClaimForm, VehicleClaimMethodEnum, VehicleClaimService, VehicleCollection, VehicleExpense, VehicleExpenseCollection, VehicleForm, VehicleLogbook, VehicleLogbookCollection, VehicleLogbookPurposeEnum, VehicleLogbookService, VehicleService, WORK_TANK_LOGBOOK_PURPOSE_OPTIONS, XlsxService, atLeastOneCheckedValidator, atoLinks, autocompleteValidator, cloneDeep, compare, compareMatOptions, createDate, displayMatOptions, enumToList, getDocIcon, passwordMatchValidator, passwordValidator, replace, roundTo, sort, sortDeep, taxReviewFilterPredicate };
13566
+ export { AbstractForm, AbstractModel, AccountSetupItem, AccountSetupItemCollection, AccountSetupService, Address, AddressService, AddressTypeEnum, AlphabetColorsEnum, AppEvent, AppEventTypeEnum, AssetEntityTypeEnum, AssetTypeEnum, AssetsService, AuthService, BANK_ACCOUNT_TYPES, Badge, BadgeColorEnum, Bank, BankAccount, BankAccountAddManualForm, BankAccountAllocationForm, BankAccountCalculationService, BankAccountChartData, BankAccountCollection, BankAccountImportForm, BankAccountLoanForm, BankAccountPropertiesForm, BankAccountProperty, BankAccountService, BankAccountStatusEnum, BankAccountTypeEnum, BankAccountsImportForm, BankConnection, BankConnectionService, BankConnectionStatusEnum, BankLoginData, BankLoginForm, BankService, BankTransaction, BankTransactionCalculationService, BankTransactionChartData, BankTransactionCollection, BankTransactionService, BankTransactionSummaryFieldsEnum, BankTransactionTypeEnum, BasiqConfig, BasiqJob, BasiqService, BasiqToken, BorrowingExpense, BorrowingExpenseLoan, BorrowingExpenseService, CAPITAL_COSTS_ITEMS, CHART_ACCOUNTS_CATEGORIES, CalculationFormItem, CalculationFormTypeEnum, ChartAccounts, ChartAccountsCategoryEnum, ChartAccountsCollection, ChartAccountsDepreciation, ChartAccountsDepreciationService, ChartAccountsEtpEnum, ChartAccountsHeading, ChartAccountsHeadingListEnum, ChartAccountsHeadingTaxDeductibleEnum, ChartAccountsHeadingTaxableEnum, ChartAccountsHeadingVehicleListEnum, ChartAccountsListEnum, ChartAccountsMetadata, ChartAccountsMetadataListEnum, ChartAccountsMetadataTypeEnum, ChartAccountsService, ChartAccountsTaxLabelsEnum, ChartAccountsTypeEnum, ChartAccountsValue, ChartData, ChartSerie, Chat, ChatService, ChatStatusEnum, ChatViewTypeEnum, ClientCollection, ClientDetails, ClientDetailsMedicareExemptionEnum, ClientDetailsWorkDepreciationCalculationEnum, ClientDetailsWorkingHolidayMakerEnum, ClientIncomeTypes, ClientIncomeTypesForm, ClientIncomeTypesService, ClientInvite, ClientInviteService, ClientInviteStatusEnum, ClientInviteTypeEnum, ClientMovement, ClientMovementCollection, ClientMovementService, ClientPortfolioChartData, ClientPortfolioReport, ClientPortfolioReportCollection, ClientPortfolioReportService, Collection, CollectionDictionary, CorelogicService, CorelogicSuggestion, Country, DEDUCTION_CATEGORIES, DEFAULT_VEHICLE_EXPENSE, DEPRECIATION_GROUPS, DOCUMENT_FILE_TYPES, DeductionClothingTypeEnum, DeductionSelfEducationTypeEnum, Depreciation, DepreciationCalculationEnum, DepreciationCalculationPercentEnum, DepreciationCapitalProject, DepreciationCapitalProjectService, DepreciationCollection, DepreciationForecast, DepreciationForecastCollection, DepreciationGroup, DepreciationGroupEnum, DepreciationGroupItem, DepreciationLvpAssetTypeEnum, DepreciationLvpReportItem, DepreciationLvpReportItemCollection, DepreciationReceipt, DepreciationReportItem, DepreciationReportItemCollection, DepreciationService, DepreciationTypeEnum, DepreciationWriteOffAmountEnum, Dictionary, Document, DocumentApiUrlPrefixEnum, DocumentFolder, DocumentFolderService, ENDPOINTS, EmployeeCollection, EmployeeDetails, EmployeeInvite, EmployeeInviteService, EmployeeService, Endpoint, EquityPositionChartService, EventDispatcherService, ExportDataTable, ExportFormatEnum, ExportFormatterService, ExportableCollection, FacebookService, FinancialYear, Firm, FirmService, FirmTypeEnum, HeaderTitleService, IconsFileEnum, IncomeAmountTypeEnum, IncomePosition, IncomeSource, IncomeSourceChartData, IncomeSourceCollection, IncomeSourceForecast, IncomeSourceForecastService, IncomeSourceForecastTrustTypeEnum, IncomeSourceService, IncomeSourceType, IncomeSourceTypeEnum, IncomeSourceTypeListOtherEnum, IncomeSourceTypeListSoleEnum, IncomeSourceTypeListWorkEnum, InterceptorsModule, IntercomService, InviteStatusEnum, JwtService, KompassifyService, Loan, LoanBankTypeEnum, LoanCollection, LoanFrequencyEnum, LoanInterestTypeEnum, LoanMaxNumberOfPaymentsEnum, LoanPayment, LoanPaymentCollection, LoanPayout, LoanPayoutTypeEnum, LoanRepaymentFrequencyEnum, LoanRepaymentTypeEnum, LoanService, LoanTypeEnum, LoanVehicleTypeEnum, LogbookPeriod, LoginForm, MODULE_URL_LIST, MONTHS, Message, MessageCollection, MessageDocument, MessageDocumentCollection, MessageDocumentService, MessageService, MonthNameShortEnum, MonthNumberEnum, MyAccountHistory, MyAccountHistoryInitiatedByEnum, MyAccountHistoryStatusEnum, MyAccountHistoryTypeEnum, MyTaxBusinessOrLosses, MyTaxBusinessOrLossesForm, MyTaxDeductions, MyTaxDeductionsForm, MyTaxDividends, MyTaxDividendsForm, MyTaxEmployeeShareSchemes, MyTaxEmployeeShareSchemesForm, 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, PdfOrientationEnum, PdfSettings, Phone, PhoneTypeEnum, PreloaderService, Property, PropertyCalculationService, PropertyCategory, PropertyCategoryListEnum, PropertyCategoryMovement, PropertyCategoryMovementService, PropertyCategoryService, PropertyCollection, PropertyDepreciationCalculationEnum, PropertyDocument, PropertyDocumentService, PropertyEquityChartData, PropertyEquityChartItem, PropertyForecast, PropertyReportItem, PropertyReportItemCollection, PropertyReportItemDepreciationCollection, PropertyReportItemTransaction, PropertyReportItemTransactionCollection, PropertySale, PropertySaleService, PropertySaleTaxExemptionMetadata, PropertyService, PropertyShare, PropertyShareAccessEnum, PropertyShareService, PropertyShareStatusEnum, PropertySubscription, PropertyTransactionReportService, PropertyValuation, RegisterClientForm, RegisterFirmForm, RegistrationInvite, RegistrationInviteStatusEnum, ReportItem, ReportItemCollection, ReportItemDetails, ResetPasswordForm, SUBSCRIPTION_DESCRIPTION, SUBSCRIPTION_TITLE, SalaryForecast, SalaryForecastFrequencyEnum, SalaryForecastService, ServiceNotificationService, ServiceNotificationStatusEnum, ServiceNotificationTypeEnum, ServicePayment, ServicePaymentStatusEnum, ServicePrice, ServicePriceRecurringIntervalEnum, ServicePriceService, ServicePriceTypeEnum, ServiceProduct, ServiceProductIdEnum, ServiceProductStatusEnum, ServiceSubscription, ServiceSubscriptionCollection, ServiceSubscriptionItem, ServiceSubscriptionStatusEnum, ShareFilterOptionsEnum, SoleForecast, SoleForecastService, SpareDocumentSpareTypeEnum, SseService, SubscriptionService, SubscriptionTypeEnum, TAX_RETURN_CATEGORIES, TYPE_LOAN, TankTypeEnum, TaxCalculationMedicareExemptionEnum, TaxCalculationTypeEnum, TaxExemption, TaxExemptionEnum, TaxExemptionMetadata, TaxExemptionMetadataEnum, 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, TransactionCalculationService, TransactionCategoryEnum, TransactionCollection, TransactionMetadata, TransactionOperationEnum, TransactionReceipt, TransactionService, TransactionSourceEnum, TransactionTypeEnum, TtCoreModule, USER_ROLES, USER_WORK_POSITION, User, UserEventSetting, UserEventSettingCollection, UserEventSettingFieldEnum, UserEventSettingService, UserEventStatusEnum, UserEventType, UserEventTypeCategory, UserEventTypeClientTypeEnum, UserEventTypeEmployeeTypeEnum, UserEventTypeFrequencyEnum, UserEventTypeService, UserEventTypeUserTypeEnum, UserMedicareExemptionEnum, UserRolesEnum, UserService, UserStatusEnum, UserSwitcherService, UserTitleEnum, UserToRegister, UserWorkDepreciationCalculationEnum, UserWorkingHolidayMakerEnum, Vehicle, VehicleClaim, VehicleClaimForm, VehicleClaimMethodEnum, VehicleClaimService, VehicleCollection, VehicleExpense, VehicleExpenseCollection, VehicleForm, VehicleLogbook, VehicleLogbookCollection, VehicleLogbookPurposeEnum, VehicleLogbookService, VehicleService, WORK_TANK_LOGBOOK_PURPOSE_OPTIONS, XlsxService, atLeastOneCheckedValidator, atoLinks, autocompleteValidator, cloneDeep, compare, compareMatOptions, conditionalValidator, createDate, displayMatOptions, enumToList, getDocIcon, passwordMatchValidator, passwordValidator, replace, roundTo, sort, sortDeep, taxReviewFilterPredicate };
13436
13567
  //# sourceMappingURL=taxtank-core.js.map