taxtank-core 0.23.3 → 0.23.6
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 +140 -14
- package/bundles/taxtank-core.umd.js.map +1 -1
- package/esm2015/lib/collections/collection-dictionary.js +2 -2
- package/esm2015/lib/collections/property/property-sale/property-sale.collection.js +16 -0
- package/esm2015/lib/collections/property/property.collection.js +13 -1
- package/esm2015/lib/forms/report/my-tax/index.js +2 -1
- package/esm2015/lib/forms/report/my-tax/my-tax-cgt.form.js +25 -0
- package/esm2015/lib/models/property/property-sale/property-sale.js +10 -1
- package/esm2015/lib/models/property/property.js +13 -1
- package/esm2015/lib/models/report/my-tax/index.js +3 -1
- package/esm2015/lib/models/report/my-tax/my-tax-cgt/cgt-exemption-and-rollover-code.enum.js +9 -0
- package/esm2015/lib/models/report/my-tax/my-tax-cgt/my-tax-cgt.js +26 -0
- package/esm2015/lib/services/http/bank/bank-connection/bank-connection.service.js +3 -1
- package/esm2015/public-api.js +2 -1
- package/fesm2015/taxtank-core.js +116 -12
- package/fesm2015/taxtank-core.js.map +1 -1
- package/lib/collections/collection-dictionary.d.ts +1 -1
- package/lib/collections/property/property-sale/property-sale.collection.d.ts +10 -0
- package/lib/collections/property/property.collection.d.ts +8 -0
- package/lib/forms/report/my-tax/index.d.ts +1 -0
- package/lib/forms/report/my-tax/my-tax-cgt.form.d.ts +5 -0
- package/lib/models/property/property-sale/property-sale.d.ts +5 -0
- package/lib/models/property/property.d.ts +10 -0
- package/lib/models/report/my-tax/index.d.ts +2 -0
- package/lib/models/report/my-tax/my-tax-cgt/cgt-exemption-and-rollover-code.enum.d.ts +7 -0
- package/lib/models/report/my-tax/my-tax-cgt/my-tax-cgt.d.ts +23 -0
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
|
@@ -40,7 +40,7 @@ export declare class CollectionDictionary<Collection extends BaseCollection<Abst
|
|
|
40
40
|
* Create instance of collection
|
|
41
41
|
*/
|
|
42
42
|
createCollection(items?: object[]): Collection;
|
|
43
|
-
length(): number;
|
|
43
|
+
get length(): number;
|
|
44
44
|
/**
|
|
45
45
|
* @Todo find a better solution to get list of the sorted keys
|
|
46
46
|
* Get array of the "keys" by provided order
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Collection } from '../../collection';
|
|
2
|
+
import { PropertySale } from '../../../models/property/property-sale/property-sale';
|
|
3
|
+
export declare class PropertySaleCollection extends Collection<PropertySale> {
|
|
4
|
+
get grossCGT(): number;
|
|
5
|
+
/**
|
|
6
|
+
* Property sales are CGT applicable unless it has "Principle place of residence" exemption type
|
|
7
|
+
*/
|
|
8
|
+
getCGTApplicable(): this;
|
|
9
|
+
getByPropertyShareIds(ids: number[]): this;
|
|
10
|
+
}
|
|
@@ -18,6 +18,10 @@ export declare class PropertyCollection extends Collection<Property> {
|
|
|
18
18
|
* Get new property collection filtered by shared
|
|
19
19
|
*/
|
|
20
20
|
getSharedProperties(): PropertyCollection;
|
|
21
|
+
/**
|
|
22
|
+
* Properties that are taxed and will be included in reports (Tax summary, My tax report, e.t.c.)
|
|
23
|
+
*/
|
|
24
|
+
getTaxInclusive(): this;
|
|
21
25
|
getUnsold(): this;
|
|
22
26
|
/**
|
|
23
27
|
* Get total purchase price for all properties in the collection
|
|
@@ -27,6 +31,10 @@ export declare class PropertyCollection extends Collection<Property> {
|
|
|
27
31
|
get marketValue(): number;
|
|
28
32
|
get firstForecastYear(): number;
|
|
29
33
|
get marketValueGrowth(): number;
|
|
34
|
+
/**
|
|
35
|
+
* list of properties
|
|
36
|
+
*/
|
|
37
|
+
getCGTApplicable(): this;
|
|
30
38
|
getOwnerOccupiedProperties(): PropertyCollection;
|
|
31
39
|
get earliestContractDate(): Date;
|
|
32
40
|
/**
|
|
@@ -8,4 +8,9 @@ export declare class PropertySale extends BasePropertySale {
|
|
|
8
8
|
contractDate: Date;
|
|
9
9
|
taxExemptionMetadata: PropertySaleTaxExemptionMetadata[];
|
|
10
10
|
get saleCostsTotalAmount(): number;
|
|
11
|
+
/**
|
|
12
|
+
* CGT is not applicable for sales with "Principle place of residence" exemption type.
|
|
13
|
+
* https://taxtank.atlassian.net/wiki/spaces/TAXTANK/pages/4644110466/Tax+Return+MyTax+-+Online+Form ("Capital gains or losses" section)
|
|
14
|
+
*/
|
|
15
|
+
isCGTApplicable(): boolean;
|
|
11
16
|
}
|
|
@@ -18,6 +18,11 @@ import { DepreciationCollection } from '../../collections/depreciation.collectio
|
|
|
18
18
|
* propertySale docs - https://taxtank.atlassian.net/wiki/spaces/TAXTANK/pages/4209508353/Property+Sold+button
|
|
19
19
|
*/
|
|
20
20
|
export declare class Property extends PropertyBase implements Photoable, Documentable {
|
|
21
|
+
/**
|
|
22
|
+
* Property acquired before 20 September 1985 will generally be treated as pre-Capital Gains Tax (CGT) assets.
|
|
23
|
+
* Any assets acquired before this day are CGT exempt (because the tax didn't exist before this date).
|
|
24
|
+
*/
|
|
25
|
+
static preCGTAssetDate: Date;
|
|
21
26
|
contractDate: Date;
|
|
22
27
|
settlementDate: Date;
|
|
23
28
|
address: Address;
|
|
@@ -84,6 +89,11 @@ export declare class Property extends PropertyBase implements Photoable, Documen
|
|
|
84
89
|
*/
|
|
85
90
|
getCGTExemptionRatio(sale: PropertySale): number;
|
|
86
91
|
isOneYearExemptionApplicable(sale: PropertySale): boolean;
|
|
92
|
+
/**
|
|
93
|
+
* CGT is not applicable for properties acquired before 20.09.1985 (tax didn't exist before this date).
|
|
94
|
+
* https://taxtank.atlassian.net/wiki/spaces/TAXTANK/pages/4644110466/Tax+Return+MyTax+-+Online+Form ("Capital gains or losses" section)
|
|
95
|
+
*/
|
|
96
|
+
isCGTApplicable(): boolean;
|
|
87
97
|
/**
|
|
88
98
|
* ownership duration from purchase till sale
|
|
89
99
|
*/
|
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
* 'My Tax' report related data (classes, enums, const, e.t.c)
|
|
3
3
|
*/
|
|
4
4
|
export * from './my-tax-business-or-losses/my-tax-business-or-losses';
|
|
5
|
+
export * from './my-tax-cgt/my-tax-cgt';
|
|
6
|
+
export * from './my-tax-cgt/cgt-exemption-and-rollover-code.enum';
|
|
5
7
|
export * from './my-tax-deductions/my-tax-deductions';
|
|
6
8
|
export * from './my-tax-deductions/deduction-fields.const';
|
|
7
9
|
export * from './my-tax-deductions/deduction-self-education-type.enum';
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { PropertyCollection } from '../../../../collections/property/property.collection';
|
|
2
|
+
import { PropertySaleCollection } from '../../../../collections/property/property-sale/property-sale.collection';
|
|
3
|
+
/**
|
|
4
|
+
* Report related to Property sales CGT details.
|
|
5
|
+
* All fields are about current year, except netCapitalLoss
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
export declare class MyTaxCgt {
|
|
9
|
+
hasCapitalGain: boolean;
|
|
10
|
+
hasExemption: boolean;
|
|
11
|
+
netCapitalGain: number;
|
|
12
|
+
grossCapitalGain: number;
|
|
13
|
+
/**
|
|
14
|
+
* Loss collected over the years
|
|
15
|
+
*/
|
|
16
|
+
netCapitalLoss: number;
|
|
17
|
+
static createFrom(propertySales: PropertySaleCollection, properties: PropertyCollection, clientCapitalLoss: number): MyTaxCgt;
|
|
18
|
+
/**
|
|
19
|
+
* Exemption is applicable for PPR sales and properties acquired before Property.preCGTAssetDate
|
|
20
|
+
* https://taxtank.atlassian.net/wiki/spaces/TAXTANK/pages/4644110466/Tax+Return+MyTax+-+Online+Form ("Capital gains or losses" section)
|
|
21
|
+
*/
|
|
22
|
+
static isCGTApplicable(sales: PropertySaleCollection, properties: PropertyCollection): boolean;
|
|
23
|
+
}
|
package/package.json
CHANGED
package/public-api.d.ts
CHANGED
|
@@ -23,6 +23,7 @@ export * from './lib/collections/loan/loan-payment.collection';
|
|
|
23
23
|
export * from './lib/collections/message.collection';
|
|
24
24
|
export * from './lib/collections/message-document.collection';
|
|
25
25
|
export * from './lib/collections/property/property.collection';
|
|
26
|
+
export * from './lib/collections/property/property-sale/property-sale.collection';
|
|
26
27
|
export * from './lib/collections/report/depreciation/depreciation-lvp-report-item.collection';
|
|
27
28
|
export * from './lib/collections/report/depreciation/depreciation-report-item.collection';
|
|
28
29
|
export * from './lib/collections/report/property/property-report-item.collection';
|