taxtank-core 0.5.4 → 0.7.1
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 +443 -177
- package/bundles/taxtank-core.umd.js.map +1 -1
- package/esm2015/lib/collections/depreciation.collection.js +13 -2
- package/esm2015/lib/collections/property/property-sale/property-sale-tax-exemption-metadata.collection.js +20 -0
- package/esm2015/lib/collections/property/property.collection.js +72 -0
- package/esm2015/lib/db/Enums/property/property-category-list.enum.js +5 -0
- package/esm2015/lib/db/Enums/{property-depreciation-calculation.enum.js → property/property-depreciation-calculation.enum.js} +1 -1
- package/esm2015/lib/db/Enums/property/property-owner-access.enum.js +6 -0
- package/esm2015/lib/db/Enums/property/property-owner-status.enum.js +7 -0
- package/esm2015/lib/db/Enums/property/property-sale/tax-exemption-metadata.enum.js +9 -0
- package/esm2015/lib/db/Enums/property/property-sale/tax-exemption.enum.js +12 -0
- package/esm2015/lib/db/Models/bank-account-property.js +1 -1
- package/esm2015/lib/db/Models/depreciation-capital-project.js +1 -1
- package/esm2015/lib/db/Models/depreciation.js +1 -1
- package/esm2015/lib/db/Models/property/property-category-movement.js +3 -0
- package/esm2015/lib/db/Models/property/property-category.js +3 -0
- package/esm2015/lib/db/Models/property/property-document.js +3 -0
- package/esm2015/lib/db/Models/property/property-forecast.js +3 -0
- package/esm2015/lib/db/Models/property/property-owner.js +3 -0
- package/esm2015/lib/db/Models/property/property-sale/property-sale-tax-exemption-metadata.js +3 -0
- package/esm2015/lib/db/Models/property/property-sale/property-sale.js +3 -0
- package/esm2015/lib/db/Models/property/property-sale/tax-exemption-metadata.js +3 -0
- package/esm2015/lib/db/Models/property/property-sale/tax-exemption.js +3 -0
- package/esm2015/lib/db/Models/property/property-subscription.js +3 -0
- package/esm2015/lib/db/Models/property/property-valuation.js +3 -0
- package/esm2015/lib/db/Models/property/property.js +3 -0
- package/esm2015/lib/db/Models/transaction-base.js +1 -1
- package/esm2015/lib/db/Models/transaction.js +1 -1
- package/esm2015/lib/db/Models/user.js +1 -1
- package/esm2015/lib/forms/abstract.form.js +11 -0
- package/esm2015/lib/forms/index.js +7 -0
- package/esm2015/lib/forms/login/login.form.js +11 -0
- package/esm2015/lib/forms/register/register-client.form.js +29 -0
- package/esm2015/lib/forms/register/register-firm.form.js +26 -0
- package/esm2015/lib/forms/user/password.form.js +11 -0
- package/esm2015/lib/forms/user/reset-password.form.js +10 -0
- package/esm2015/lib/interceptors/corelogic-interceptor.js +2 -2
- package/esm2015/lib/models/depreciation/depreciation.js +5 -1
- package/esm2015/lib/models/endpoint/endpoints.const.js +1 -2
- package/esm2015/lib/models/property/property-category-movement.js +2 -2
- package/esm2015/lib/models/property/property-category.js +2 -2
- package/esm2015/lib/models/property/property-document.js +2 -2
- package/esm2015/lib/models/property/property-equity-chart-data.js +3 -3
- package/esm2015/lib/models/property/property-forecast.js +2 -2
- package/esm2015/lib/models/property/property-owner.js +3 -3
- package/esm2015/lib/models/property/property-sale/property-sale-tax-exemption-metadata.js +4 -0
- package/esm2015/lib/models/property/property-sale/property-sale.js +19 -0
- package/esm2015/lib/models/property/property-sale/tax-exemption-metadata.js +4 -0
- package/esm2015/lib/models/property/property-sale/tax-exemption.js +4 -0
- package/esm2015/lib/models/property/property-subscription.js +2 -2
- package/esm2015/lib/models/property/property-valuation.js +2 -2
- package/esm2015/lib/models/property/property.js +88 -4
- package/esm2015/lib/services/depreciation/depreciation.service.js +1 -1
- package/esm2015/lib/services/property/corelogic/corelogic.service.js +46 -0
- package/esm2015/lib/services/property/property-calculation/property-calculation.service.js +121 -0
- package/esm2015/lib/services/property/property-category/property-category.service.js +23 -0
- package/esm2015/lib/services/property/property-category-movement.service.js +1 -1
- package/esm2015/lib/services/property/property-document/property-document.service.js +70 -0
- package/esm2015/lib/services/property/{property-owner.service.js → property-owner/property-owner.service.js} +7 -7
- package/esm2015/lib/services/property/property-sale/property-sale.service.js +20 -0
- package/esm2015/lib/services/property/property-sale/tax-exemption/tax-exemption.service.js +21 -0
- package/esm2015/lib/services/property/property.service.js +1 -1
- package/esm2015/public-api.js +22 -14
- package/fesm2015/taxtank-core.js +361 -147
- package/fesm2015/taxtank-core.js.map +1 -1
- package/lib/collections/depreciation.collection.d.ts +4 -1
- package/lib/collections/property/property-sale/property-sale-tax-exemption-metadata.collection.d.ts +8 -0
- package/lib/collections/{property.collection.d.ts → property/property.collection.d.ts} +4 -4
- package/lib/db/Enums/property/property-category-list.enum.d.ts +3 -0
- package/lib/db/Enums/{property-depreciation-calculation.enum.d.ts → property/property-depreciation-calculation.enum.d.ts} +0 -0
- package/lib/db/Enums/{property-owner-access.enum.d.ts → property/property-owner-access.enum.d.ts} +0 -0
- package/lib/db/Enums/{property-owner-status.enum.d.ts → property/property-owner-status.enum.d.ts} +0 -0
- package/lib/db/Enums/property/property-sale/tax-exemption-metadata.enum.d.ts +5 -0
- package/lib/db/Enums/property/property-sale/tax-exemption.enum.d.ts +9 -0
- package/lib/db/Models/bank-account-property.d.ts +1 -1
- package/lib/db/Models/depreciation-capital-project.d.ts +1 -1
- package/lib/db/Models/depreciation.d.ts +1 -1
- package/lib/db/Models/{property-category-movement.d.ts → property/property-category-movement.d.ts} +1 -1
- package/lib/db/Models/{property-category.d.ts → property/property-category.d.ts} +1 -1
- package/lib/db/Models/{property-document.d.ts → property/property-document.d.ts} +1 -1
- package/lib/db/Models/{property-forecast.d.ts → property/property-forecast.d.ts} +0 -0
- package/lib/db/Models/{property-owner.d.ts → property/property-owner.d.ts} +4 -4
- package/lib/db/Models/property/property-sale/property-sale-tax-exemption-metadata.d.ts +8 -0
- package/lib/db/Models/property/property-sale/property-sale.d.ts +20 -0
- package/lib/db/Models/property/property-sale/tax-exemption-metadata.d.ts +6 -0
- package/lib/db/Models/property/property-sale/tax-exemption.d.ts +7 -0
- package/lib/db/Models/{property-subscription.d.ts → property/property-subscription.d.ts} +1 -1
- package/lib/db/Models/{property-valuation.d.ts → property/property-valuation.d.ts} +0 -0
- package/lib/db/Models/{property.d.ts → property/property.d.ts} +9 -8
- package/lib/db/Models/transaction-base.d.ts +1 -1
- package/lib/db/Models/transaction.d.ts +1 -1
- package/lib/db/Models/user.d.ts +3 -3
- package/lib/forms/abstract.form.d.ts +4 -0
- package/lib/forms/index.d.ts +6 -0
- package/lib/forms/login/login.form.d.ts +4 -0
- package/lib/forms/register/register-client.form.d.ts +5 -0
- package/lib/forms/register/register-firm.form.d.ts +7 -0
- package/lib/forms/user/password.form.d.ts +4 -0
- package/lib/forms/user/reset-password.form.d.ts +4 -0
- package/lib/interceptors/corelogic-interceptor.d.ts +1 -1
- package/lib/models/depreciation/depreciation.d.ts +1 -0
- package/lib/models/property/property-category-movement.d.ts +1 -1
- package/lib/models/property/property-category.d.ts +1 -1
- package/lib/models/property/property-document.d.ts +1 -1
- package/lib/models/property/property-equity-chart-data.d.ts +1 -1
- package/lib/models/property/property-forecast.d.ts +1 -1
- package/lib/models/property/property-owner.d.ts +1 -1
- package/lib/models/property/property-sale/property-sale-tax-exemption-metadata.d.ts +3 -0
- package/lib/models/property/property-sale/property-sale.d.ts +8 -0
- package/lib/models/property/property-sale/tax-exemption-metadata.d.ts +3 -0
- package/lib/models/property/property-sale/tax-exemption.d.ts +3 -0
- package/lib/models/property/property-subscription.d.ts +1 -1
- package/lib/models/property/property-valuation.d.ts +1 -1
- package/lib/models/property/property.d.ts +34 -3
- package/lib/services/property/{corelogic.service.d.ts → corelogic/corelogic.service.d.ts} +1 -1
- package/lib/services/property/{property-calculation.service.d.ts → property-calculation/property-calculation.service.d.ts} +5 -5
- package/lib/services/property/{property-category.service.d.ts → property-category/property-category.service.d.ts} +3 -3
- package/lib/services/property/property-category-movement.service.d.ts +1 -1
- package/lib/services/property/{property-document.service.d.ts → property-document/property-document.service.d.ts} +4 -4
- package/lib/services/property/{property-owner.service.d.ts → property-owner/property-owner.service.d.ts} +4 -4
- package/lib/services/property/property-sale/property-sale.service.d.ts +10 -0
- package/lib/services/property/property-sale/tax-exemption/tax-exemption.service.d.ts +11 -0
- package/lib/services/property/property.service.d.ts +1 -1
- package/package.json +2 -1
- package/public-api.d.ts +21 -13
- package/esm2015/lib/collections/property.collection.js +0 -72
- package/esm2015/lib/db/Enums/property-owner-access.enum.js +0 -6
- package/esm2015/lib/db/Enums/property-owner-status.enum.js +0 -7
- package/esm2015/lib/db/Models/capital-cost-property.js +0 -3
- package/esm2015/lib/db/Models/capital-cost.js +0 -3
- package/esm2015/lib/db/Models/property-capital-cost.js +0 -3
- package/esm2015/lib/db/Models/property-category-movement.js +0 -3
- package/esm2015/lib/db/Models/property-category.js +0 -3
- package/esm2015/lib/db/Models/property-document.js +0 -3
- package/esm2015/lib/db/Models/property-forecast.js +0 -3
- package/esm2015/lib/db/Models/property-owner.js +0 -3
- package/esm2015/lib/db/Models/property-sold.js +0 -3
- package/esm2015/lib/db/Models/property-subscription.js +0 -3
- package/esm2015/lib/db/Models/property-valuation.js +0 -3
- package/esm2015/lib/db/Models/property.js +0 -3
- package/esm2015/lib/models/property/property-capital-cost.js +0 -4
- package/esm2015/lib/models/property/property-sold.js +0 -12
- package/esm2015/lib/services/property/corelogic.service.js +0 -46
- package/esm2015/lib/services/property/property-calculation.service.js +0 -121
- package/esm2015/lib/services/property/property-capital-cost.service.js +0 -46
- package/esm2015/lib/services/property/property-category.service.js +0 -23
- package/esm2015/lib/services/property/property-document.service.js +0 -68
- package/esm2015/lib/services/property/property-sold.service.js +0 -23
- package/lib/db/Models/capital-cost-property.d.ts +0 -13
- package/lib/db/Models/capital-cost.d.ts +0 -4
- package/lib/db/Models/property-capital-cost.d.ts +0 -13
- package/lib/db/Models/property-sold.d.ts +0 -12
- package/lib/models/property/property-capital-cost.d.ts +0 -3
- package/lib/models/property/property-sold.d.ts +0 -5
- package/lib/services/property/property-capital-cost.service.d.ts +0 -20
- package/lib/services/property/property-sold.service.d.ts +0 -13
|
@@ -9,7 +9,8 @@ export declare class DepreciationCollection extends Collection<Depreciation> {
|
|
|
9
9
|
*/
|
|
10
10
|
get amount(): number;
|
|
11
11
|
get claimAmount(): number;
|
|
12
|
-
getClaimAmountByYear(year
|
|
12
|
+
getClaimAmountByYear(year?: number): number;
|
|
13
|
+
getCloseBalanceByYear(year?: number): number;
|
|
13
14
|
getCurrentYearForecastAmount(): number;
|
|
14
15
|
get assetValue(): number;
|
|
15
16
|
/**
|
|
@@ -17,6 +18,8 @@ export declare class DepreciationCollection extends Collection<Depreciation> {
|
|
|
17
18
|
*/
|
|
18
19
|
getByTankType(tankType: TankTypeEnum): DepreciationCollection;
|
|
19
20
|
getByPropertiesIds(ids: number[]): DepreciationCollection;
|
|
21
|
+
getWithCapitalProject(): DepreciationCollection;
|
|
22
|
+
getWithoutCapitalProject(): DepreciationCollection;
|
|
20
23
|
getWithoutBorrowingExpenses(): DepreciationCollection;
|
|
21
24
|
getWorkDepreciations(): DepreciationCollection;
|
|
22
25
|
getPropertyDepreciations(): DepreciationCollection;
|
package/lib/collections/property/property-sale/property-sale-tax-exemption-metadata.collection.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Collection } from '../../collection';
|
|
2
|
+
import { PropertySaleTaxExemptionMetadata } from '../../../models/property/property-sale/property-sale-tax-exemption-metadata';
|
|
3
|
+
export declare class PropertySaleTaxExemptionMetadataCollection extends Collection<PropertySaleTaxExemptionMetadata> {
|
|
4
|
+
getPPRDays(): number;
|
|
5
|
+
getMarketValue(): number;
|
|
6
|
+
getClaimPercent(): number;
|
|
7
|
+
getByMetadataId(id: number): PropertySaleTaxExemptionMetadata;
|
|
8
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Collection } from '
|
|
2
|
-
import { Property } from '
|
|
3
|
-
import { PropertyCategory } from '
|
|
1
|
+
import { Collection } from '../collection';
|
|
2
|
+
import { Property } from '../../models/property/property';
|
|
3
|
+
import { PropertyCategory } from '../../models/property/property-category';
|
|
4
4
|
export declare class PropertyCollection extends Collection<Property> {
|
|
5
5
|
/**
|
|
6
6
|
* Get new property collection filtered by category id
|
|
@@ -30,7 +30,7 @@ export declare class PropertyCollection extends Collection<Property> {
|
|
|
30
30
|
get firstForecastYear(): number;
|
|
31
31
|
get marketValueGrowth(): number;
|
|
32
32
|
getOwnerOccupiedProperties(): PropertyCollection;
|
|
33
|
-
get
|
|
33
|
+
get earliestContractDate(): Date;
|
|
34
34
|
/**
|
|
35
35
|
* Get list of unique property categories from collection
|
|
36
36
|
*/
|
|
File without changes
|
package/lib/db/Enums/{property-owner-access.enum.d.ts → property/property-owner-access.enum.d.ts}
RENAMED
|
File without changes
|
package/lib/db/Enums/{property-owner-status.enum.d.ts → property/property-owner-status.enum.d.ts}
RENAMED
|
File without changes
|
|
@@ -2,7 +2,7 @@ import { DepreciationTypeEnum } from '../Enums/depreciation-type.enum';
|
|
|
2
2
|
import { DepreciationCalculationEnum } from '../Enums/depreciation-calculation.enum';
|
|
3
3
|
import { DepreciationCalculationPercentEnum } from '../Enums/depreciation-calculation-percent.enum';
|
|
4
4
|
import { User } from './user';
|
|
5
|
-
import { Property } from './property';
|
|
5
|
+
import { Property } from './property/property';
|
|
6
6
|
import { BankTransaction } from './bank-transaction';
|
|
7
7
|
import { DepreciationCapitalProject } from './depreciation-capital-project';
|
|
8
8
|
import { ChartAccounts } from './chart-accounts';
|
package/lib/db/Models/{property-category-movement.d.ts → property/property-category-movement.d.ts}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Property } from './property';
|
|
2
2
|
import { PropertyCategory } from './property-category';
|
|
3
3
|
import { PropertyValuation } from './property-valuation';
|
|
4
|
-
import { User } from '
|
|
4
|
+
import { User } from '../user';
|
|
5
5
|
export declare class PropertyCategoryMovement {
|
|
6
6
|
id?: number;
|
|
7
7
|
fromDate?: Date;
|
|
File without changes
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { PropertyOwnerStatusEnum } from '
|
|
2
|
-
import { PropertyOwnerAccessEnum } from '
|
|
1
|
+
import { PropertyOwnerStatusEnum } from '../../Enums/property/property-owner-status.enum';
|
|
2
|
+
import { PropertyOwnerAccessEnum } from '../../Enums/property/property-owner-access.enum';
|
|
3
3
|
import { Property } from './property';
|
|
4
|
-
import { User } from '
|
|
5
|
-
import { RegistrationInvite } from '
|
|
4
|
+
import { User } from '../user';
|
|
5
|
+
import { RegistrationInvite } from '../registration-invite';
|
|
6
6
|
export declare class PropertyOwner {
|
|
7
7
|
id?: number;
|
|
8
8
|
email?: string;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { PropertySale } from './property-sale';
|
|
2
|
+
import { TaxExemptionMetadata } from './tax-exemption-metadata';
|
|
3
|
+
export declare class PropertySaleTaxExemptionMetadata {
|
|
4
|
+
value?: number;
|
|
5
|
+
id?: number;
|
|
6
|
+
propertySale?: PropertySale;
|
|
7
|
+
metadata?: TaxExemptionMetadata;
|
|
8
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Property } from '../property';
|
|
2
|
+
import { TaxExemption } from './tax-exemption';
|
|
3
|
+
import { TaxExemptionMetadata } from '../../../../models/property/property-sale/tax-exemption-metadata';
|
|
4
|
+
export declare class PropertySale {
|
|
5
|
+
id?: number;
|
|
6
|
+
structuralImprovementsWDV?: number;
|
|
7
|
+
buildingAtCostClaimed?: number;
|
|
8
|
+
settlementDate?: Date;
|
|
9
|
+
contractDate?: Date;
|
|
10
|
+
price?: number;
|
|
11
|
+
commission?: number;
|
|
12
|
+
legalFees?: number;
|
|
13
|
+
otherCost?: number;
|
|
14
|
+
capitalLoss?: number;
|
|
15
|
+
createdAt?: Date;
|
|
16
|
+
updatedAt?: Date;
|
|
17
|
+
property?: Property;
|
|
18
|
+
taxExemption?: TaxExemption;
|
|
19
|
+
taxExemptionMetadata?: TaxExemptionMetadata[];
|
|
20
|
+
}
|
|
File without changes
|
|
@@ -1,21 +1,20 @@
|
|
|
1
|
-
import { PropertyDepreciationCalculationEnum } from '
|
|
2
|
-
import { User } from '
|
|
3
|
-
import { Address } from '
|
|
1
|
+
import { PropertyDepreciationCalculationEnum } from '../../Enums/property/property-depreciation-calculation.enum';
|
|
2
|
+
import { User } from '../user';
|
|
3
|
+
import { Address } from '../address';
|
|
4
4
|
import { PropertyCategory } from './property-category';
|
|
5
5
|
import { PropertyForecast } from './property-forecast';
|
|
6
6
|
import { PropertyOwner } from './property-owner';
|
|
7
7
|
import { PropertyValuation } from './property-valuation';
|
|
8
8
|
import { PropertyCategoryMovement } from './property-category-movement';
|
|
9
|
-
import {
|
|
10
|
-
import { BankAccountProperty } from './bank-account-property';
|
|
9
|
+
import { BankAccountProperty } from '../bank-account-property';
|
|
11
10
|
import { PropertyDocument } from './property-document';
|
|
12
|
-
import { Depreciation } from '
|
|
11
|
+
import { Depreciation } from '../depreciation';
|
|
13
12
|
import { PropertySubscription } from './property-subscription';
|
|
14
13
|
export declare class Property {
|
|
15
14
|
id?: number;
|
|
16
15
|
photo?: string;
|
|
17
16
|
purchasePrice?: number;
|
|
18
|
-
|
|
17
|
+
contractDate?: Date;
|
|
19
18
|
settlementDate?: Date;
|
|
20
19
|
depreciationCalculation?: PropertyDepreciationCalculationEnum;
|
|
21
20
|
shareWith?: string;
|
|
@@ -32,7 +31,9 @@ export declare class Property {
|
|
|
32
31
|
owners?: PropertyOwner[];
|
|
33
32
|
valuations?: PropertyValuation[];
|
|
34
33
|
categoryMovements?: PropertyCategoryMovement[];
|
|
35
|
-
|
|
34
|
+
stampDuty?: number;
|
|
35
|
+
legalFees?: number;
|
|
36
|
+
otherCapitalCosts?: number;
|
|
36
37
|
propertyBankAccounts?: BankAccountProperty[];
|
|
37
38
|
createdBy?: User;
|
|
38
39
|
updatedBy?: User;
|
|
@@ -9,7 +9,7 @@ import { TransactionMetadata } from './transaction-metadata';
|
|
|
9
9
|
import { TransactionAllocation } from './transaction-allocation';
|
|
10
10
|
import { Loan } from './loan';
|
|
11
11
|
import { TransactionBase } from './transaction-base';
|
|
12
|
-
import { Property } from './property';
|
|
12
|
+
import { Property } from './property/property';
|
|
13
13
|
import { Depreciation } from './depreciation';
|
|
14
14
|
export declare class Transaction extends TransactionBase {
|
|
15
15
|
id?: number;
|
package/lib/db/Models/user.d.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { UserTitleEnum } from '../Enums/user-title.enum';
|
|
2
2
|
import { UserStatusEnum } from '../Enums/user-status.enum';
|
|
3
3
|
import { UserRolesEnum } from '../Enums/user-roles.enum';
|
|
4
|
-
import { Property } from './property';
|
|
5
|
-
import { PropertySubscription } from './property-subscription';
|
|
4
|
+
import { Property } from './property/property';
|
|
5
|
+
import { PropertySubscription } from './property/property-subscription';
|
|
6
6
|
import { ServiceSubscription } from './service-subscription';
|
|
7
7
|
import { UserEventSetting } from './user-event-setting';
|
|
8
8
|
import { BankConnection } from './bank-connection';
|
|
9
9
|
import { TaxReview } from './tax-review';
|
|
10
|
-
import { PropertyOwner } from './property-owner';
|
|
10
|
+
import { PropertyOwner } from './property/property-owner';
|
|
11
11
|
import { Address } from './address';
|
|
12
12
|
import { Phone } from './phone';
|
|
13
13
|
import { ClientMovement } from './client-movement';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { AbstractForm } from '../abstract.form';
|
|
2
|
+
import { FirmTypeEnum } from '../../db/Enums/firm-type.enum';
|
|
3
|
+
export declare class RegisterFirmForm extends AbstractForm {
|
|
4
|
+
private firmType;
|
|
5
|
+
constructor(firmType: FirmTypeEnum, referenceCode?: string);
|
|
6
|
+
submit(): object;
|
|
7
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Observable } from 'rxjs';
|
|
2
2
|
import { HttpRequest, HttpHandler, HttpEvent, HttpInterceptor } from '@angular/common/http';
|
|
3
|
-
import { CorelogicService } from '../services/property/corelogic.service';
|
|
3
|
+
import { CorelogicService } from '../services/property/corelogic/corelogic.service';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
/**
|
|
6
6
|
* Corelogic interceptor add Core Logic access token for each search requests related with Core Logic API
|
|
@@ -64,6 +64,7 @@ export declare class Depreciation extends DepreciationBase implements ITank, IRe
|
|
|
64
64
|
getCloseBalance(): number;
|
|
65
65
|
get claimAmount(): number;
|
|
66
66
|
getClaimAmountByYear(year: number): number;
|
|
67
|
+
getCloseBalanceByYear(year: number): number;
|
|
67
68
|
get assetValue(): number;
|
|
68
69
|
getClaimPercent(): number;
|
|
69
70
|
getCurrentYearForecastAmount(): number;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PropertyCategoryMovement as PropertyCategoryMovementBase } from '../../db/Models/property-category-movement';
|
|
1
|
+
import { PropertyCategoryMovement as PropertyCategoryMovementBase } from '../../db/Models/property/property-category-movement';
|
|
2
2
|
import { PropertyValuation } from './property-valuation';
|
|
3
3
|
import { PropertyCategory } from './property-category';
|
|
4
4
|
export declare class PropertyCategoryMovement extends PropertyCategoryMovementBase {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PropertyCategory as PropertyCategoryBase } from '../../db/Models/property-category';
|
|
1
|
+
import { PropertyCategory as PropertyCategoryBase } from '../../db/Models/property/property-category';
|
|
2
2
|
export declare class PropertyCategory extends PropertyCategoryBase {
|
|
3
3
|
isOwnerOccupied(): boolean;
|
|
4
4
|
isVacantLand(): boolean;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PropertyDocument as PropertyDocumentBase } from '../../db/Models/property-document';
|
|
1
|
+
import { PropertyDocument as PropertyDocumentBase } from '../../db/Models/property/property-document';
|
|
2
2
|
import { IAsset } from '../../interfaces/asset.interface';
|
|
3
3
|
import { IDocument } from '../../interfaces/document.interface';
|
|
4
4
|
import { AssetTypeEnum } from '../../interfaces/asset-type.enum';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PropertyEquityChartItem } from './property-equity-chart-item';
|
|
2
|
-
import { PropertyCollection } from '../../collections/property.collection';
|
|
2
|
+
import { PropertyCollection } from '../../collections/property/property.collection';
|
|
3
3
|
import { BankAccountCollection } from '../../collections/bank-account.collection';
|
|
4
4
|
import { LoanCollection } from '../../collections/loan.collection';
|
|
5
5
|
import { PropertyEquityChartTypeEnum } from './property-equity-chart-type.enum';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PropertyForecast as PropertyForecastBase } from '../../db/Models/property-forecast';
|
|
1
|
+
import { PropertyForecast as PropertyForecastBase } from '../../db/Models/property/property-forecast';
|
|
2
2
|
export declare class PropertyForecast extends PropertyForecastBase {
|
|
3
3
|
income: number;
|
|
4
4
|
expense: number;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PropertyOwner as PropertyOwnerBase } from '../../db/Models/property-owner';
|
|
1
|
+
import { PropertyOwner as PropertyOwnerBase } from '../../db/Models/property/property-owner';
|
|
2
2
|
import { User } from '../user/user';
|
|
3
3
|
import { RegistrationInvite } from '../registration-invite/registration-invite';
|
|
4
4
|
import { Property } from './property';
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { PropertySaleTaxExemptionMetadata as BasePropertySaleTaxExemptionMetadata } from '../../../db/Models/property/property-sale/property-sale-tax-exemption-metadata';
|
|
2
|
+
export declare class PropertySaleTaxExemptionMetadata extends BasePropertySaleTaxExemptionMetadata {
|
|
3
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { PropertySale as BasePropertySale } from '../../../db/Models/property/property-sale/property-sale';
|
|
2
|
+
import { PropertySaleTaxExemptionMetadata } from '../../../db/Models/property/property-sale/property-sale-tax-exemption-metadata';
|
|
3
|
+
export declare class PropertySale extends BasePropertySale {
|
|
4
|
+
settlementDate: Date;
|
|
5
|
+
contractDate: Date;
|
|
6
|
+
taxExemptionMetadata: PropertySaleTaxExemptionMetadata[];
|
|
7
|
+
get saleCostsTotalAmount(): number;
|
|
8
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PropertySubscription as PropertySubscriptionBase } from '../../db/Models/property-subscription';
|
|
1
|
+
import { PropertySubscription as PropertySubscriptionBase } from '../../db/Models/property/property-subscription';
|
|
2
2
|
import { User } from '../user/user';
|
|
3
3
|
export declare class PropertySubscription extends PropertySubscriptionBase {
|
|
4
4
|
createdAt: Date;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PropertyValuation as PropertyValuationBase } from '../../db/Models/property-valuation';
|
|
1
|
+
import { PropertyValuation as PropertyValuationBase } from '../../db/Models/property/property-valuation';
|
|
2
2
|
import { PropertyDocument } from './property-document';
|
|
3
3
|
export declare class PropertyValuation extends PropertyValuationBase {
|
|
4
4
|
date: Date;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Property as PropertyBase } from '../../db/Models/property';
|
|
1
|
+
import { Property as PropertyBase } from '../../db/Models/property/property';
|
|
2
2
|
import { Documentable } from '../../interfaces/documentable.interface';
|
|
3
3
|
import { IDocument } from '../../interfaces/document.interface';
|
|
4
|
-
import { PropertyOwner } from '../../db/Models/property-owner';
|
|
4
|
+
import { PropertyOwner } from '../../db/Models/property/property-owner';
|
|
5
5
|
import { PropertySubscription } from './property-subscription';
|
|
6
6
|
import { Photoable } from '../../interfaces/photoable';
|
|
7
7
|
import { Address } from '../address/address';
|
|
@@ -10,8 +10,14 @@ import { PropertyValuation } from './property-valuation';
|
|
|
10
10
|
import { PropertyForecast } from './property-forecast';
|
|
11
11
|
import { PropertyCategoryMovement } from './property-category-movement';
|
|
12
12
|
import { User } from '../user/user';
|
|
13
|
+
import { TaxExemptionEnum } from '../../db/Enums/property/property-sale/tax-exemption.enum';
|
|
14
|
+
import { PropertySale } from './property-sale/property-sale';
|
|
15
|
+
import { unitOfTime } from 'moment';
|
|
16
|
+
/**
|
|
17
|
+
* propertySale docs - https://taxtank.atlassian.net/wiki/spaces/TAXTANK/pages/4209508353/Property+Sold+button
|
|
18
|
+
*/
|
|
13
19
|
export declare class Property extends PropertyBase implements Photoable, Documentable {
|
|
14
|
-
|
|
20
|
+
contractDate: Date;
|
|
15
21
|
settlementDate: Date;
|
|
16
22
|
address: Address;
|
|
17
23
|
category: PropertyCategory;
|
|
@@ -52,4 +58,29 @@ export declare class Property extends PropertyBase implements Photoable, Documen
|
|
|
52
58
|
getCurrentSubscription(): PropertySubscription;
|
|
53
59
|
getForecastByYear(year: number): PropertyForecast;
|
|
54
60
|
get isShared(): boolean;
|
|
61
|
+
/**
|
|
62
|
+
* purchase costs - claimed costs, except `ppr to investment` exemption,
|
|
63
|
+
* in that case it's equal to market value, when property became an investment property
|
|
64
|
+
*/
|
|
65
|
+
calculateCostBase(sale: PropertySale): number;
|
|
66
|
+
/**
|
|
67
|
+
* gross capital gain tax: sale costs - cost base
|
|
68
|
+
*/
|
|
69
|
+
calculateCGT(sale: PropertySale): number;
|
|
70
|
+
/**
|
|
71
|
+
* net capital gain tax (includes tax exemptions)
|
|
72
|
+
*/
|
|
73
|
+
calculateNetCGT(sale: PropertySale): number;
|
|
74
|
+
/**
|
|
75
|
+
* guess tax exemption based on property details
|
|
76
|
+
*/
|
|
77
|
+
getCGTExemption(sale: PropertySale): TaxExemptionEnum;
|
|
78
|
+
/**
|
|
79
|
+
* tax exemption can reduce cgt from 100% to less (up to zero)
|
|
80
|
+
*/
|
|
81
|
+
getCGTExemptionRatio(sale: PropertySale): number;
|
|
82
|
+
/**
|
|
83
|
+
* ownership duration from purchase till sale
|
|
84
|
+
*/
|
|
85
|
+
getOwnershipDuration(sale: PropertySale, unitOfTime?: unitOfTime.Diff): number;
|
|
55
86
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { HttpClient } from '@angular/common/http';
|
|
2
2
|
import { Observable, ReplaySubject } from 'rxjs';
|
|
3
|
-
import { CorelogicSuggestion } from '
|
|
3
|
+
import { CorelogicSuggestion } from '../../../models/property/corelogic-suggestion';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
export declare class CorelogicService {
|
|
6
6
|
private http;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Observable } from 'rxjs';
|
|
2
|
-
import { BankAccountCollection } from '
|
|
3
|
-
import { DepreciationCollection } from '
|
|
4
|
-
import { LoanCollection } from '
|
|
5
|
-
import { PropertyCollection } from '
|
|
6
|
-
import { TransactionCollection } from '
|
|
2
|
+
import { BankAccountCollection } from '../../../collections/bank-account.collection';
|
|
3
|
+
import { DepreciationCollection } from '../../../collections/depreciation.collection';
|
|
4
|
+
import { LoanCollection } from '../../../collections/loan.collection';
|
|
5
|
+
import { PropertyCollection } from '../../../collections/property/property.collection';
|
|
6
|
+
import { TransactionCollection } from '../../../collections/transaction.collection';
|
|
7
7
|
import * as i0 from "@angular/core";
|
|
8
8
|
/**
|
|
9
9
|
* Service with calculations methods for properties related with other entities.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { PropertyCategory as PropertyCategoryBase } from '
|
|
2
|
-
import { BaseRestService } from '
|
|
3
|
-
import { PropertyCategory } from '
|
|
1
|
+
import { PropertyCategory as PropertyCategoryBase } from '../../../db/Models/property/property-category';
|
|
2
|
+
import { BaseRestService } from '../../base-rest.service';
|
|
3
|
+
import { PropertyCategory } from '../../../models/property/property-category';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
/**
|
|
6
6
|
* Service for work with Property Categories
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PropertyCategoryMovement } from '../../models/property/property-category-movement';
|
|
2
|
-
import { PropertyCategoryMovement as PropertyCategoryMovementBase } from '../../db/Models/property-category-movement';
|
|
2
|
+
import { PropertyCategoryMovement as PropertyCategoryMovementBase } from '../../db/Models/property/property-category-movement';
|
|
3
3
|
import { BaseRestService } from '../base-rest.service';
|
|
4
4
|
import { Observable } from 'rxjs';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Observable } from 'rxjs';
|
|
2
|
-
import { PropertyDocument as PropertyDocumentBase } from '
|
|
2
|
+
import { PropertyDocument as PropertyDocumentBase } from '../../../db/Models/property/property-document';
|
|
3
3
|
import { HttpClient } from '@angular/common/http';
|
|
4
|
-
import { EventDispatcherService } from '
|
|
5
|
-
import { PropertyDocument } from '
|
|
6
|
-
import { BaseRestService } from '
|
|
4
|
+
import { EventDispatcherService } from '../../event/event-dispatcher.service';
|
|
5
|
+
import { PropertyDocument } from '../../../models/property/property-document';
|
|
6
|
+
import { BaseRestService } from '../../base-rest.service';
|
|
7
7
|
import * as i0 from "@angular/core";
|
|
8
8
|
/**
|
|
9
9
|
* Class for work with Property Documents
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Observable } from 'rxjs';
|
|
2
|
-
import { PropertyOwner as PropertyOwnerBase } from '
|
|
2
|
+
import { PropertyOwner as PropertyOwnerBase } from '../../../db/Models/property/property-owner';
|
|
3
3
|
import { HttpClient } from '@angular/common/http';
|
|
4
|
-
import { EventDispatcherService } from '
|
|
5
|
-
import { PropertyOwner } from '
|
|
6
|
-
import { BaseRestService } from '
|
|
4
|
+
import { EventDispatcherService } from '../../event/event-dispatcher.service';
|
|
5
|
+
import { PropertyOwner } from '../../../models/property/property-owner';
|
|
6
|
+
import { BaseRestService } from '../../base-rest.service';
|
|
7
7
|
import * as i0 from "@angular/core";
|
|
8
8
|
export declare class PropertyOwnerService extends BaseRestService<PropertyOwnerBase, PropertyOwner> {
|
|
9
9
|
protected http: HttpClient;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { PropertySale as PropertySaleBase } from '../../../db/Models/property/property-sale/property-sale';
|
|
2
|
+
import { PropertySale } from '../../../models/property/property-sale/property-sale';
|
|
3
|
+
import { BaseRestService } from '../../base-rest.service';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export declare class PropertySaleService extends BaseRestService<PropertySaleBase, PropertySale> {
|
|
6
|
+
modelClass: typeof PropertySale;
|
|
7
|
+
url: string;
|
|
8
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PropertySaleService, never>;
|
|
9
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<PropertySaleService>;
|
|
10
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { BaseRestService } from '../../../base-rest.service';
|
|
2
|
+
import { TaxExemption as BaseTaxExemption } from '../../../../db/Models/property/property-sale/tax-exemption';
|
|
3
|
+
import { TaxExemption } from '../../../../models/property/property-sale/tax-exemption';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export declare class TaxExemptionService extends BaseRestService<BaseTaxExemption, TaxExemption> {
|
|
6
|
+
modelClass: typeof TaxExemption;
|
|
7
|
+
url: string;
|
|
8
|
+
isHydra: boolean;
|
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TaxExemptionService, never>;
|
|
10
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<TaxExemptionService>;
|
|
11
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Property as PropertyBase } from '../../db/Models/property';
|
|
1
|
+
import { Property as PropertyBase } from '../../db/Models/property/property';
|
|
2
2
|
import { Observable } from 'rxjs';
|
|
3
3
|
import { HttpClient } from '@angular/common/http';
|
|
4
4
|
import { BaseRestService } from '../base-rest.service';
|
package/package.json
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "taxtank-core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"peerDependencies": {
|
|
6
6
|
"@angular/common": "^12.2.3 || ~13.0.0",
|
|
7
7
|
"@angular/core": "^12.2.3 || ~13.0.0",
|
|
8
|
+
"@angular/forms": "^12.2.3 || ~13.0.0",
|
|
8
9
|
"@angular/router": "^12.2.3 || ~13.0.0",
|
|
9
10
|
"@auth0/angular-jwt": "^5.0.2",
|
|
10
11
|
"@stripe/stripe-js": "^1.11.0",
|