taxtank-core 0.21.0 → 0.21.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/taxtank-core.umd.js +131 -49
- package/bundles/taxtank-core.umd.js.map +1 -1
- package/esm2015/lib/collections/property/property.collection.js +24 -5
- package/esm2015/lib/forms/bank/bank-account/bank-account-add-manual.form.js +3 -2
- package/esm2015/lib/forms/register/register-client.form.js +3 -9
- package/esm2015/lib/forms/register/register-firm.form.js +4 -1
- package/esm2015/lib/functions/mat-options-functions.js +4 -1
- package/esm2015/lib/models/badge/badge-color.enum.js +8 -0
- package/esm2015/lib/models/badge/badge.js +14 -0
- package/esm2015/lib/models/property/property.js +6 -1
- package/esm2015/lib/services/property/property-calculation/property-calculation.service.js +35 -1
- package/esm2015/public-api.js +4 -1
- package/fesm2015/taxtank-core.js +122 -47
- package/fesm2015/taxtank-core.js.map +1 -1
- package/lib/collections/property/property.collection.d.ts +5 -0
- package/lib/forms/register/register-client.form.d.ts +3 -2
- package/lib/forms/register/register-firm.form.d.ts +1 -0
- package/lib/models/badge/badge-color.enum.d.ts +6 -0
- package/lib/models/badge/badge.d.ts +10 -0
- package/lib/models/property/property.d.ts +5 -0
- package/lib/services/property/property-calculation/property-calculation.service.d.ts +10 -0
- package/package.json +1 -1
- package/public-api.d.ts +3 -0
|
@@ -42,4 +42,9 @@ export declare class PropertyCollection extends Collection<Property> {
|
|
|
42
42
|
* Get property with the lowest tax position
|
|
43
43
|
*/
|
|
44
44
|
getBestPerformanceTaxProperty(transactions: TransactionCollection, depreciations: DepreciationCollection): Property;
|
|
45
|
+
/**
|
|
46
|
+
* Show best performance properties first
|
|
47
|
+
* https://taxtank.atlassian.net/wiki/spaces/TAXTANK/pages/217677997/Property+Tank+Dashboard
|
|
48
|
+
*/
|
|
49
|
+
sortByBestPerformance(transactions: TransactionCollection, depreciations: DepreciationCollection): this;
|
|
45
50
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { AbstractForm } from '../abstract.form';
|
|
2
|
-
|
|
2
|
+
import { User } from '../../models/user/user';
|
|
3
|
+
export declare class RegisterClientForm extends AbstractForm<User> {
|
|
3
4
|
constructor(referenceCode?: string);
|
|
4
|
-
submit():
|
|
5
|
+
submit(data?: object): User;
|
|
5
6
|
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { BadgeColorEnum } from './badge-color.enum';
|
|
2
|
+
import { AbstractModel } from '../../db/Models/abstract-model';
|
|
3
|
+
/**
|
|
4
|
+
* Class for UI element badge
|
|
5
|
+
*/
|
|
6
|
+
export declare class Badge extends AbstractModel {
|
|
7
|
+
color: BadgeColorEnum;
|
|
8
|
+
text: string;
|
|
9
|
+
constructor(text: string, color?: BadgeColorEnum);
|
|
10
|
+
}
|
|
@@ -86,5 +86,10 @@ export declare class Property extends PropertyBase implements Photoable, Documen
|
|
|
86
86
|
* ownership duration from purchase till sale
|
|
87
87
|
*/
|
|
88
88
|
getOwnershipDuration(sale: PropertySale, unitOfTime?: unitOfTime.Diff): number;
|
|
89
|
+
/**
|
|
90
|
+
* Tax Position = Income - Expense - Interest - Depreciation
|
|
91
|
+
* Where (Income - Expense - Interest) is cash position.
|
|
92
|
+
* https://taxtank.atlassian.net/wiki/spaces/TAXTANK/pages/217415928/Dashboard+Property
|
|
93
|
+
*/
|
|
89
94
|
getTaxPosition(transactions: TransactionCollection, depreciations: DepreciationCollection): number;
|
|
90
95
|
}
|
|
@@ -4,6 +4,8 @@ import { DepreciationCollection } from '../../../collections/depreciation.collec
|
|
|
4
4
|
import { LoanCollection } from '../../../collections/loan/loan.collection';
|
|
5
5
|
import { PropertyCollection } from '../../../collections/property/property.collection';
|
|
6
6
|
import { TransactionCollection } from '../../../collections/transaction/transaction.collection';
|
|
7
|
+
import { Dictionary } from '../../../models/dictionary/dictionary';
|
|
8
|
+
import { Badge } from '../../../models/badge/badge';
|
|
7
9
|
import * as i0 from "@angular/core";
|
|
8
10
|
/**
|
|
9
11
|
* Service with calculations methods for properties related with other entities.
|
|
@@ -28,6 +30,14 @@ export declare class PropertyCalculationService {
|
|
|
28
30
|
getLvrGrowth$(properties$: Observable<PropertyCollection>, bankAccounts$: Observable<BankAccountCollection>, loans$: Observable<LoanCollection>): Observable<number>;
|
|
29
31
|
getEquityPosition(properties: PropertyCollection, bankAccounts: BankAccountCollection): number;
|
|
30
32
|
getPurchaseEquity(properties: PropertyCollection, bankAccounts: BankAccountCollection, loans: LoanCollection): number;
|
|
33
|
+
/**
|
|
34
|
+
* Get dictionary of badges for each property in collection
|
|
35
|
+
*/
|
|
36
|
+
getBadgesByProperty(properties: PropertyCollection, transactions: TransactionCollection, depreciations: DepreciationCollection): Dictionary<Badge>;
|
|
37
|
+
/**
|
|
38
|
+
* Get Badge for single property in collection
|
|
39
|
+
*/
|
|
40
|
+
private getBadge;
|
|
31
41
|
static ɵfac: i0.ɵɵFactoryDeclaration<PropertyCalculationService, never>;
|
|
32
42
|
static ɵprov: i0.ɵɵInjectableDeclaration<PropertyCalculationService>;
|
|
33
43
|
}
|
package/package.json
CHANGED
package/public-api.d.ts
CHANGED
|
@@ -138,6 +138,8 @@ export * from './lib/db/Enums/property/property-sale/tax-exemption-metadata.enum
|
|
|
138
138
|
export * from './lib/models/account-setup/account-setup-item';
|
|
139
139
|
export * from './lib/models/address/address';
|
|
140
140
|
export * from './lib/models/address/country';
|
|
141
|
+
export * from './lib/models/badge/badge';
|
|
142
|
+
export * from './lib/models/badge/badge-color.enum';
|
|
141
143
|
export * from './lib/models/bank/bank';
|
|
142
144
|
export * from './lib/models/bank/bank-account';
|
|
143
145
|
export * from './lib/models/bank/bank-account-chart-data';
|
|
@@ -174,6 +176,7 @@ export * from './lib/models/client/client-movement';
|
|
|
174
176
|
export * from './lib/models/client/client-portfolio-chart-data';
|
|
175
177
|
export * from './lib/models/client/client-portfolio-report';
|
|
176
178
|
export * from './lib/models/color/alphabet-colors.enum';
|
|
179
|
+
export * from './lib/models/dictionary/dictionary';
|
|
177
180
|
export * from './lib/models/depreciation/depreciation';
|
|
178
181
|
export * from './lib/models/depreciation/depreciation-capital-project';
|
|
179
182
|
export * from './lib/models/depreciation/depreciation-forecast';
|