taxtank-core 0.30.46 → 0.30.48
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/esm2020/lib/collections/exportable.collection.mjs +1 -1
- package/esm2020/lib/collections/holding/holding-sale.collection.mjs +35 -3
- package/esm2020/lib/collections/holding/holding.collection.mjs +6 -2
- package/esm2020/lib/collections/loan/loan-payment.collection.mjs +2 -2
- package/esm2020/lib/db/Enums/chart-accounts/chart-accounts-category.enum.mjs +3 -3
- package/esm2020/lib/forms/holding/holding-sale.form.mjs +3 -2
- package/esm2020/lib/services/account-setup/account-setup.service.mjs +13 -10
- package/esm2020/lib/services/xlsx/xlsx.service.mjs +5 -1
- package/fesm2015/taxtank-core.mjs +54 -13
- package/fesm2015/taxtank-core.mjs.map +1 -1
- package/fesm2020/taxtank-core.mjs +53 -13
- package/fesm2020/taxtank-core.mjs.map +1 -1
- package/lib/collections/exportable.collection.d.ts +1 -1
- package/lib/collections/holding/holding-sale.collection.d.ts +9 -3
- package/lib/collections/loan/loan-payment.collection.d.ts +1 -2
- package/lib/db/Enums/chart-accounts/chart-accounts-category.enum.d.ts +2 -2
- package/lib/services/account-setup/account-setup.service.d.ts +3 -2
- package/lib/services/xlsx/xlsx.service.d.ts +4 -0
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Collection } from './collection';
|
|
2
2
|
import { ExportDataTable } from '../models/export/export-data-table';
|
|
3
3
|
import { ExportCell } from '../models/export/export-cell';
|
|
4
|
-
import { AbstractModel } from '../db/Models
|
|
4
|
+
import { AbstractModel } from '../db/Models';
|
|
5
5
|
export declare abstract class ExportableCollection<Model extends AbstractModel> extends Collection<Model> {
|
|
6
6
|
abstract getExportHeader(type?: string): string[];
|
|
7
7
|
abstract getExportBody(type?: string): ExportCell[][];
|
|
@@ -1,6 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
1
|
+
import { Dictionary, Holding, HoldingSale, HoldingType } from '../../models';
|
|
2
|
+
import { ExportableCollection } from "../exportable.collection";
|
|
3
|
+
import { ExportCell } from "../../models/export/export-cell";
|
|
4
|
+
export declare class HoldingSaleCollection extends ExportableCollection<HoldingSale> {
|
|
5
|
+
holdingTypesById: Dictionary<HoldingType>;
|
|
6
|
+
holdingsById: Dictionary<Holding>;
|
|
4
7
|
/**
|
|
5
8
|
* @TODO vik remove?
|
|
6
9
|
*/
|
|
@@ -8,4 +11,7 @@ export declare class HoldingSaleCollection extends Collection<HoldingSale> {
|
|
|
8
11
|
get currentYearCapitalLoss(): number;
|
|
9
12
|
get halfExemptionGrossCapitalGain(): number;
|
|
10
13
|
get noExemptionGrossCapitalGain(): number;
|
|
14
|
+
getExportHeader(): string[];
|
|
15
|
+
getExportFooter(): ExportCell[];
|
|
16
|
+
getExportBody(): ExportCell[][];
|
|
11
17
|
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { ExportableCollection } from '../exportable.collection';
|
|
2
2
|
import { ExportCell } from '../../models/export/export-cell';
|
|
3
|
-
import { LoanPayment } from '../../models
|
|
4
|
-
import { FinancialYear } from '../../models/financial-year/financial-year';
|
|
3
|
+
import { LoanPayment, FinancialYear } from '../../models';
|
|
5
4
|
export declare class LoanPaymentCollection extends ExportableCollection<LoanPayment> {
|
|
6
5
|
getExportHeader(): string[];
|
|
7
6
|
getExportBody(): ExportCell[][];
|
|
@@ -9,7 +9,7 @@ import { Observable, ReplaySubject } from 'rxjs';
|
|
|
9
9
|
import { AccountSetupItemCollection } from '../../collections/account-setup-item.collection';
|
|
10
10
|
import { VehicleClaimService } from '../http/vehicle/vehicle-claim.service';
|
|
11
11
|
import { TransactionService } from '../http/transaction/transaction.service';
|
|
12
|
-
import { HoldingService, SoleBusinessService } from '../http';
|
|
12
|
+
import { HoldingService, SoleBusinessService, UserService } from '../http';
|
|
13
13
|
import * as i0 from "@angular/core";
|
|
14
14
|
/**
|
|
15
15
|
* Service handling user's account setup process.
|
|
@@ -25,10 +25,11 @@ export declare class AccountSetupService {
|
|
|
25
25
|
private transactionService;
|
|
26
26
|
private soleBusinessService;
|
|
27
27
|
private holdingService;
|
|
28
|
+
private userService;
|
|
28
29
|
cache: AccountSetupItemCollection;
|
|
29
30
|
cacheSubject: ReplaySubject<AccountSetupItemCollection>;
|
|
30
31
|
clientIncomeTypesId: number;
|
|
31
|
-
constructor(clientIncomeTypesService: ClientIncomeTypesService, propertyService: PropertyService, incomeSourceService: IncomeSourceService, bankAccountsService: BankAccountService, transactionAllocationService: TransactionAllocationService, vehicleClaimService: VehicleClaimService, transactionService: TransactionService, soleBusinessService: SoleBusinessService, holdingService: HoldingService);
|
|
32
|
+
constructor(clientIncomeTypesService: ClientIncomeTypesService, propertyService: PropertyService, incomeSourceService: IncomeSourceService, bankAccountsService: BankAccountService, transactionAllocationService: TransactionAllocationService, vehicleClaimService: VehicleClaimService, transactionService: TransactionService, soleBusinessService: SoleBusinessService, holdingService: HoldingService, userService: UserService);
|
|
32
33
|
/**
|
|
33
34
|
* Get list of account setup items for current user
|
|
34
35
|
*/
|
|
@@ -10,6 +10,10 @@ export declare class XlsxService {
|
|
|
10
10
|
sheetName: string;
|
|
11
11
|
fileName: string;
|
|
12
12
|
};
|
|
13
|
+
/**
|
|
14
|
+
* @TODO vik/artem work with ExportDataTable instead of ExportableCollection
|
|
15
|
+
* @TODO vik/artem why so much code? here is 6 rows solution https://stackoverflow.com/questions/64939994/how-to-export-array-of-objects-to-an-excel-in-angular-8
|
|
16
|
+
*/
|
|
13
17
|
exportArrayToExcel(exportableCollection: ExportableCollection<any>, name?: string): void;
|
|
14
18
|
static ɵfac: i0.ɵɵFactoryDeclaration<XlsxService, never>;
|
|
15
19
|
static ɵprov: i0.ɵɵInjectableDeclaration<XlsxService>;
|