taxtank-core 0.28.85 → 0.28.87
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 +77 -44
- package/bundles/taxtank-core.umd.js.map +1 -1
- package/esm2015/lib/collections/property/property-category-movement.collection.js +2 -2
- package/esm2015/lib/collections/transaction/transaction.collection.js +4 -12
- package/esm2015/lib/models/event/app-event-type.enum.js +20 -18
- package/esm2015/lib/models/property/property.js +2 -2
- package/esm2015/lib/services/http/sole/sole-invoice/sole-invoice.service.js +12 -1
- package/esm2015/lib/services/http/subscription/subscription.service.js +16 -10
- package/esm2015/lib/services/http/transaction/transaction-allocation/transaction-allocation.service.js +21 -1
- package/esm2015/lib/services/property/property-calculation/property-calculation.service.js +3 -3
- package/fesm2015/taxtank-core.js +69 -40
- package/fesm2015/taxtank-core.js.map +1 -1
- package/lib/collections/transaction/transaction.collection.d.ts +1 -9
- package/lib/models/event/app-event-type.enum.d.ts +19 -17
- package/lib/services/http/sole/sole-invoice/sole-invoice.service.d.ts +4 -1
- package/lib/services/http/subscription/subscription.service.d.ts +7 -5
- package/lib/services/http/transaction/transaction-allocation/transaction-allocation.service.d.ts +3 -0
- package/package.json +1 -1
|
@@ -25,20 +25,12 @@ export declare class TransactionCollection extends ExportableCollection<Transact
|
|
|
25
25
|
* Difference between allocated amount and total amount
|
|
26
26
|
*/
|
|
27
27
|
getUnallocatedAmount(allocations: TransactionAllocationCollection): number;
|
|
28
|
-
/**
|
|
29
|
-
* Get cash position
|
|
30
|
-
* Cash Position = Income - Expenses
|
|
31
|
-
* Cash position is equal to Total Amount because income is positive and expense is negative,
|
|
32
|
-
*/
|
|
33
|
-
get cashPosition(): number;
|
|
34
28
|
/**
|
|
35
29
|
* get date of the last transaction
|
|
36
30
|
*/
|
|
37
31
|
getLastTransactionDate(): Date;
|
|
38
|
-
/**
|
|
39
|
-
* Get summary of claim amounts
|
|
40
|
-
*/
|
|
41
32
|
get claimAmount(): number;
|
|
33
|
+
get grossClaimAmount(): number;
|
|
42
34
|
get grossAmount(): number;
|
|
43
35
|
getByChartAccountsCategories(categories: ChartAccountsCategoryEnum[]): TransactionCollection;
|
|
44
36
|
/**
|
|
@@ -51,21 +51,23 @@ export declare enum AppEventTypeEnum {
|
|
|
51
51
|
SOLE_DETAILS_UPDATED = 49,
|
|
52
52
|
SOLE_INVOICE_PUBLISHED = 50,
|
|
53
53
|
TAX_REVIEW_UPDATED = 51,
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
54
|
+
TRANSACTION_ALLOCATION_CREATED = 52,
|
|
55
|
+
TRANSACTION_ALLOCATION_DELETED = 53,
|
|
56
|
+
TRANSACTION_CREATED = 54,
|
|
57
|
+
TRANSACTION_DELETED = 55,
|
|
58
|
+
TRANSACTION_UPDATED = 56,
|
|
59
|
+
TRANSACTION_UPDATED_WITH_RECEIPT = 57,
|
|
60
|
+
TRANSACTION_UPDATED_WITH_DELETED_RECEIPT = 58,
|
|
61
|
+
TRANSACTION_RECEIPT_CREATED = 59,
|
|
62
|
+
TRANSACTION_RECEIPT_DELETED = 60,
|
|
63
|
+
TRANSACTIONS_CREATED = 61,
|
|
64
|
+
USER_UPDATED = 62,
|
|
65
|
+
VEHICLE_CLAIM_UPDATED = 63,
|
|
66
|
+
VEHICLE_CLAIM_CREATED = 64,
|
|
67
|
+
VEHICLE_CLAIM_DETAILS_UPDATED = 65,
|
|
68
|
+
VEHICLE_CLAIM_DETAILS_CREATED = 66,
|
|
69
|
+
VEHICLE_LOGBOOK_CREATED = 67,
|
|
70
|
+
VEHICLE_LOGBOOK_UPDATED = 68,
|
|
71
|
+
VEHICLE_LOGBOOK_DELETED = 69,
|
|
72
|
+
VEHICLE_LOGBOOK_BEST_PERIOD_UPDATED = 70
|
|
71
73
|
}
|
|
@@ -3,11 +3,13 @@ import { SoleInvoice as SoleInvoiceBase } from '../../../../db/Models/sole/sole-
|
|
|
3
3
|
import { SoleInvoice } from '../../../../models';
|
|
4
4
|
import { SoleInvoiceStatusesEnum } from '../../../../db/Enums/sole-invoice-statuses.enum';
|
|
5
5
|
import { Observable } from 'rxjs';
|
|
6
|
+
import { IEventListener } from '../../../../interfaces/event-listener.interface';
|
|
6
7
|
import * as i0 from "@angular/core";
|
|
7
|
-
export declare class SoleInvoiceService extends RestService<SoleInvoiceBase, SoleInvoice> {
|
|
8
|
+
export declare class SoleInvoiceService extends RestService<SoleInvoiceBase, SoleInvoice> implements IEventListener {
|
|
8
9
|
modelClass: typeof SoleInvoice;
|
|
9
10
|
url: string;
|
|
10
11
|
isHydra: boolean;
|
|
12
|
+
listenEvents(): void;
|
|
11
13
|
add(invoice: SoleInvoice): Observable<SoleInvoice>;
|
|
12
14
|
update(invoice: SoleInvoice): Observable<SoleInvoice>;
|
|
13
15
|
updateStatus(invoice: SoleInvoice, status: SoleInvoiceStatusesEnum): Observable<SoleInvoice>;
|
|
@@ -18,6 +20,7 @@ export declare class SoleInvoiceService extends RestService<SoleInvoiceBase, Sol
|
|
|
18
20
|
* Basically needed to create a new invoice to show its number when the invoice has not yet been sent to the backend
|
|
19
21
|
*/
|
|
20
22
|
getNewInvoiceNumber(): number;
|
|
23
|
+
private listenAllocations;
|
|
21
24
|
static ɵfac: i0.ɵɵFactoryDeclaration<SoleInvoiceService, never>;
|
|
22
25
|
static ɵprov: i0.ɵɵInjectableDeclaration<SoleInvoiceService>;
|
|
23
26
|
}
|
|
@@ -1,25 +1,27 @@
|
|
|
1
1
|
import { HttpClient } from '@angular/common/http';
|
|
2
|
-
import {
|
|
3
|
-
import { ServiceSubscriptionCollection } from '../../../collections/subscription/service-subscription.collection';
|
|
2
|
+
import { Observable, ReplaySubject } from 'rxjs';
|
|
4
3
|
import { ServiceSubscription } from '../../../models/service-subscription/service-subscription';
|
|
5
4
|
import { ServicePayment } from '../../../models/service-subscription/service-payment';
|
|
6
5
|
import { EventDispatcherService } from '../../event/event-dispatcher.service';
|
|
7
6
|
import { ServiceSubscriptionItem } from '../../../models/service-subscription/service-subscription-item';
|
|
8
7
|
import { SseService } from '../../event/sse.service';
|
|
8
|
+
import { ToastService } from '../../toast/toast.service';
|
|
9
9
|
import * as i0 from "@angular/core";
|
|
10
|
+
/**
|
|
11
|
+
* @TODO Alex refactor
|
|
12
|
+
*/
|
|
10
13
|
export declare class SubscriptionService {
|
|
11
14
|
private http;
|
|
12
15
|
private eventDispatcherService;
|
|
13
16
|
private sseService;
|
|
17
|
+
private toastService;
|
|
14
18
|
private environment;
|
|
15
19
|
_serviceSubscription: ServiceSubscription;
|
|
16
20
|
serviceSubscriptionSubject: ReplaySubject<ServiceSubscription>;
|
|
17
|
-
serviceSubscriptionsSubject: ReplaySubject<ServiceSubscriptionCollection>;
|
|
18
21
|
stripe: any;
|
|
19
22
|
servicePaymentsSubject: ReplaySubject<ServicePayment[]>;
|
|
20
23
|
_servicePayments: ServicePayment[];
|
|
21
|
-
|
|
22
|
-
constructor(http: HttpClient, eventDispatcherService: EventDispatcherService, sseService: SseService, environment: any);
|
|
24
|
+
constructor(http: HttpClient, eventDispatcherService: EventDispatcherService, sseService: SseService, toastService: ToastService, environment: any);
|
|
23
25
|
getSubscription(force?: boolean): Observable<ServiceSubscription>;
|
|
24
26
|
/**
|
|
25
27
|
* redirect to stripe payment page
|
package/lib/services/http/transaction/transaction-allocation/transaction-allocation.service.d.ts
CHANGED
|
@@ -16,6 +16,9 @@ export declare class TransactionAllocationService extends RestService<Transactio
|
|
|
16
16
|
* Add single transaction allocation
|
|
17
17
|
*/
|
|
18
18
|
add(allocation: TransactionAllocation): Observable<TransactionAllocation>;
|
|
19
|
+
addBatch(models: TransactionAllocation[], queryParams?: object): Observable<TransactionAllocation[]>;
|
|
20
|
+
delete(model: TransactionAllocation): Observable<void>;
|
|
21
|
+
deleteBatch(models: TransactionAllocation[]): Observable<void>;
|
|
19
22
|
/**
|
|
20
23
|
* get list of transactions allocations related with passed bank transactions list
|
|
21
24
|
*/
|