taxtank-core 0.21.16 → 0.21.19

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.
@@ -4644,12 +4644,18 @@
4644
4644
  enumerable: false,
4645
4645
  configurable: true
4646
4646
  });
4647
- DepreciationCollection.prototype.getClaimAmountByYear = function (year) {
4647
+ DepreciationCollection.prototype.getClaimedAmountByYear = function (year) {
4648
4648
  if (year === void 0) { year = +localStorage.getItem('financialYear'); }
4649
4649
  return +Math.round(this.amount - this.items.reduce(function (sum, depreciation) {
4650
4650
  return sum + depreciation.getCloseBalanceByYear(year);
4651
4651
  }, 0)).toFixed(2);
4652
4652
  };
4653
+ DepreciationCollection.prototype.getClaimAmountByYear = function (year) {
4654
+ if (year === void 0) { year = +localStorage.getItem('financialYear'); }
4655
+ return this.items.reduce(function (sum, depreciation) {
4656
+ return sum + depreciation.getClaimAmountByYear(year);
4657
+ }, 0);
4658
+ };
4653
4659
  DepreciationCollection.prototype.getCloseBalanceByYear = function (year) {
4654
4660
  if (year === void 0) { year = +localStorage.getItem('financialYear'); }
4655
4661
  return this.items.reduce(function (sum, depreciation) {
@@ -8376,11 +8382,13 @@
8376
8382
  * Depreciation Nested Tree node with depreciations group
8377
8383
  */
8378
8384
  var DepreciationGroup = /** @class */ (function () {
8379
- function DepreciationGroup(label, description, icon, children) {
8385
+ function DepreciationGroup(label, description, icon, children, totalCost, openingValue) {
8380
8386
  this.label = label;
8381
8387
  this.description = description;
8382
8388
  this.icon = icon;
8383
8389
  this.children = children;
8390
+ this.totalCost = totalCost;
8391
+ this.openingValue = openingValue;
8384
8392
  }
8385
8393
  DepreciationGroup.prototype.getClaimAmount = function () {
8386
8394
  return this.children.reduce(function (sum, child) { return sum + child.getClaimAmount(); }, 0);
@@ -9788,7 +9796,7 @@
9788
9796
  .getIncomeTransactions()
9789
9797
  .filterBy('chartAccounts.id', exports.ChartAccountsListEnum.OTHER_RENTAL_INCOME)
9790
9798
  .sumBy('claimAmount');
9791
- this.interestDeductionsAmount = Math.abs(transactions.getInterestTransactions().sumBy('amount'));
9799
+ this.interestDeductionsAmount = Math.abs(transactions.getInterestTransactions().sumBy('claimAmount'));
9792
9800
  this.capitalWorksDeductionsAmount = Math.abs(depreciations.getCapitalDepreciations().sumBy('claimAmount'));
9793
9801
  this.otherRentalDeductionsAmount = this.calculateOtherRentalDeductionsAmount();
9794
9802
  /**