taxtank-core 0.8.6 → 0.8.7

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.
Files changed (150) hide show
  1. package/bundles/taxtank-core.umd.js +94 -92
  2. package/bundles/taxtank-core.umd.js.map +1 -1
  3. package/esm2015/lib/db/Models/transaction-base.js +2 -1
  4. package/esm2015/lib/services/http/address/address.service.js +39 -0
  5. package/esm2015/lib/services/http/bank/bank-account/bank-account.service.js +118 -0
  6. package/esm2015/lib/services/http/bank/bank-connection/bank-connection.service.js +52 -0
  7. package/esm2015/lib/services/http/bank/bank-transaction/bank-transaction.service.js +89 -0
  8. package/esm2015/lib/services/http/bank/bank.service.js +24 -0
  9. package/esm2015/lib/services/http/bank/basiq/basiq.service.js +94 -0
  10. package/esm2015/lib/services/http/chart-accounts/chart-accounts-depreciations/chart-accounts-depreciations.service.js +38 -0
  11. package/esm2015/lib/services/http/chart-accounts/chart-accounts.service.js +89 -0
  12. package/esm2015/lib/services/http/chat/chat.service.js +77 -0
  13. package/esm2015/lib/services/http/chat/message/message.service.js +65 -0
  14. package/esm2015/lib/services/http/chat/message-document/message-document.service.js +118 -0
  15. package/esm2015/lib/services/{depreciation/capital-project.service.js → http/depreciation/depreciation-capital-project/depreciation-capital-project.service.js} +7 -7
  16. package/esm2015/lib/services/http/depreciation/depreciation.service.js +146 -0
  17. package/esm2015/lib/services/http/document/document-folder/document-folder.service.js +84 -0
  18. package/esm2015/lib/services/{client → http/firm/client-invite}/client-invite.service.js +7 -7
  19. package/esm2015/lib/services/http/firm/client-movement/client-movement.service.js +98 -0
  20. package/esm2015/lib/services/http/firm/employee/employee.service.js +39 -0
  21. package/esm2015/lib/services/http/firm/employee-invite/employee-invite.service.js +53 -0
  22. package/esm2015/lib/services/http/firm/firm.service.js +79 -0
  23. package/esm2015/lib/services/http/firm/portfolio-report/client-portfolio-report.service.js +37 -0
  24. package/esm2015/lib/services/http/income-source/income-source-forecast/income-source-forecast.service.js +90 -0
  25. package/esm2015/lib/services/http/income-source/income-source.service.js +109 -0
  26. package/esm2015/lib/services/http/income-source/salary-forecast/salary-forecast.service.js +90 -0
  27. package/esm2015/lib/services/http/income-source/sole-forecast/sole-forecast.service.js +87 -0
  28. package/esm2015/lib/services/http/loan/borrowing-expense/borrowing-expense.service.js +73 -0
  29. package/esm2015/lib/services/http/loan/loan.service.js +145 -0
  30. package/esm2015/lib/services/http/property/property-category/property-category.service.js +23 -0
  31. package/esm2015/lib/services/http/property/property-category-movement/property-category-movement.service.js +47 -0
  32. package/esm2015/lib/services/http/property/property-document/property-document.service.js +70 -0
  33. package/esm2015/lib/services/http/property/property-sale/property-sale.service.js +20 -0
  34. package/esm2015/lib/services/http/property/property-sale/tax-exemption/tax-exemption.service.js +21 -0
  35. package/esm2015/lib/services/http/property/property-share/property-share.service.js +115 -0
  36. package/esm2015/lib/services/http/property/property.service.js +126 -0
  37. package/esm2015/lib/services/http/rest/rest.service.js +190 -0
  38. package/esm2015/lib/services/http/service-notification/service-notification.service.js +65 -0
  39. package/esm2015/lib/services/http/subscription/subscription.service.js +157 -0
  40. package/esm2015/lib/services/http/tax-review/tax-review-history/tax-review-history.service.js +41 -0
  41. package/esm2015/lib/services/http/tax-review/tax-review.service.js +103 -0
  42. package/esm2015/lib/services/http/tax-summary/tax-summary.service.js +71 -0
  43. package/esm2015/lib/services/http/transaction/transaction-allocation/transaction-allocation.service.js +85 -0
  44. package/esm2015/lib/services/http/transaction/transaction.service.js +319 -0
  45. package/esm2015/lib/services/http/user/occupation/occupation.service.js +45 -0
  46. package/esm2015/lib/services/http/user/user-event-setting/user-event-setting.service.js +59 -0
  47. package/esm2015/lib/services/http/user/user-event-type/user-event-type.service.js +29 -0
  48. package/esm2015/lib/services/http/user/user.service.js +124 -0
  49. package/esm2015/lib/services/http/vehicle/vehicle.service.js +237 -0
  50. package/esm2015/lib/services/property/equity-position-chart/equity-position-chart.service.js +45 -0
  51. package/esm2015/public-api.js +48 -48
  52. package/fesm2015/taxtank-core.js +51 -49
  53. package/fesm2015/taxtank-core.js.map +1 -1
  54. package/lib/services/{address → http/address}/address.service.d.ts +1 -1
  55. package/lib/services/{bank → http/bank/bank-account}/bank-account.service.d.ts +5 -5
  56. package/lib/services/{bank → http/bank/bank-connection}/bank-connection.service.d.ts +5 -5
  57. package/lib/services/{bank → http/bank/bank-transaction}/bank-transaction.service.d.ts +5 -5
  58. package/lib/services/{bank → http/bank}/bank.service.d.ts +4 -4
  59. package/lib/services/{bank → http/bank/basiq}/basiq.service.d.ts +7 -7
  60. package/lib/services/{chart-accounts → http/chart-accounts/chart-accounts-depreciations}/chart-accounts-depreciations.service.d.ts +4 -4
  61. package/lib/services/{chart-accounts → http/chart-accounts}/chart-accounts.service.d.ts +3 -3
  62. package/lib/services/{chat → http/chat}/chat.service.d.ts +7 -7
  63. package/lib/services/{chat → http/chat/message}/message.service.d.ts +7 -7
  64. package/lib/services/{chat → http/chat/message-document}/message-document.service.d.ts +3 -3
  65. package/lib/services/{depreciation/capital-project.service.d.ts → http/depreciation/depreciation-capital-project/depreciation-capital-project.service.d.ts} +4 -4
  66. package/lib/services/{depreciation → http/depreciation}/depreciation.service.d.ts +5 -5
  67. package/lib/services/{document → http/document/document-folder}/document-folder.service.d.ts +6 -6
  68. package/lib/services/{client → http/firm/client-invite}/client-invite.service.d.ts +4 -4
  69. package/lib/services/{client → http/firm/client-movement}/client-movement.service.d.ts +7 -7
  70. package/lib/services/{employee → http/firm/employee}/employee.service.d.ts +4 -4
  71. package/lib/services/{employee → http/firm/employee-invite}/employee-invite.service.d.ts +4 -4
  72. package/lib/services/{firm → http/firm}/firm.service.d.ts +2 -2
  73. package/lib/services/{client → http/firm/portfolio-report}/client-portfolio-report.service.d.ts +1 -1
  74. package/lib/services/{income-source → http/income-source/income-source-forecast}/income-source-forecast.service.d.ts +5 -5
  75. package/lib/services/{income-source → http/income-source}/income-source.service.d.ts +8 -8
  76. package/lib/services/{income-source → http/income-source/salary-forecast}/salary-forecast.service.d.ts +6 -6
  77. package/lib/services/{income-source → http/income-source/sole-forecast}/sole-forecast.service.d.ts +5 -5
  78. package/lib/services/{borrowing-expense → http/loan/borrowing-expense}/borrowing-expense.service.d.ts +2 -2
  79. package/lib/services/{loan → http/loan}/loan.service.d.ts +6 -6
  80. package/lib/services/{property → http/property}/property-category/property-category.service.d.ts +4 -4
  81. package/lib/services/{property → http/property/property-category-movement}/property-category-movement.service.d.ts +4 -4
  82. package/lib/services/{property → http/property}/property-document/property-document.service.d.ts +5 -5
  83. package/lib/services/http/property/property-sale/property-sale.service.d.ts +10 -0
  84. package/lib/services/http/property/property-sale/tax-exemption/tax-exemption.service.d.ts +11 -0
  85. package/lib/services/{property → http/property}/property-share/property-share.service.d.ts +5 -5
  86. package/lib/services/{property → http/property}/property.service.d.ts +5 -5
  87. package/lib/services/{base-rest.service.d.ts → http/rest/rest.service.d.ts} +4 -4
  88. package/lib/services/http/service-notification/service-notification.service.d.ts +31 -0
  89. package/lib/services/{subscription → http/subscription}/subscription.service.d.ts +6 -6
  90. package/lib/services/{tax-review → http/tax-review/tax-review-history}/tax-review-history.service.d.ts +5 -5
  91. package/lib/services/{tax-review → http/tax-review}/tax-review.service.d.ts +6 -6
  92. package/lib/services/{tax-summary → http/tax-summary}/tax-summary.service.d.ts +2 -2
  93. package/lib/services/{transaction → http/transaction/transaction-allocation}/transaction-allocation.service.d.ts +6 -6
  94. package/lib/services/{transaction → http/transaction}/transaction.service.d.ts +7 -7
  95. package/lib/services/{user → http/user/occupation}/occupation.service.d.ts +1 -1
  96. package/lib/services/{user-event → http/user/user-event-setting}/user-event-setting.service.d.ts +5 -5
  97. package/lib/services/{user-event → http/user/user-event-type}/user-event-type.service.d.ts +5 -5
  98. package/lib/services/{user → http/user}/user.service.d.ts +3 -3
  99. package/lib/services/{work/work-tank.service.d.ts → http/vehicle/vehicle.service.d.ts} +9 -8
  100. package/lib/services/property/{equity-position-chart.service.d.ts → equity-position-chart/equity-position-chart.service.d.ts} +1 -1
  101. package/package.json +1 -1
  102. package/public-api.d.ts +47 -47
  103. package/esm2015/lib/services/address/address.service.js +0 -39
  104. package/esm2015/lib/services/bank/bank-account.service.js +0 -118
  105. package/esm2015/lib/services/bank/bank-connection.service.js +0 -52
  106. package/esm2015/lib/services/bank/bank-transaction.service.js +0 -89
  107. package/esm2015/lib/services/bank/bank.service.js +0 -24
  108. package/esm2015/lib/services/bank/basiq.service.js +0 -94
  109. package/esm2015/lib/services/base-rest.service.js +0 -190
  110. package/esm2015/lib/services/borrowing-expense/borrowing-expense.service.js +0 -73
  111. package/esm2015/lib/services/chart-accounts/chart-accounts-depreciations.service.js +0 -38
  112. package/esm2015/lib/services/chart-accounts/chart-accounts.service.js +0 -89
  113. package/esm2015/lib/services/chat/chat.service.js +0 -77
  114. package/esm2015/lib/services/chat/message-document.service.js +0 -118
  115. package/esm2015/lib/services/chat/message.service.js +0 -65
  116. package/esm2015/lib/services/client/client-movement.service.js +0 -98
  117. package/esm2015/lib/services/client/client-portfolio-report.service.js +0 -37
  118. package/esm2015/lib/services/depreciation/depreciation.service.js +0 -146
  119. package/esm2015/lib/services/document/document-folder.service.js +0 -84
  120. package/esm2015/lib/services/employee/employee-invite.service.js +0 -53
  121. package/esm2015/lib/services/employee/employee.service.js +0 -39
  122. package/esm2015/lib/services/firm/firm.service.js +0 -79
  123. package/esm2015/lib/services/income-source/income-source-forecast.service.js +0 -90
  124. package/esm2015/lib/services/income-source/income-source.service.js +0 -109
  125. package/esm2015/lib/services/income-source/salary-forecast.service.js +0 -90
  126. package/esm2015/lib/services/income-source/sole-forecast.service.js +0 -87
  127. package/esm2015/lib/services/loan/loan.service.js +0 -145
  128. package/esm2015/lib/services/notification/notification.service.js +0 -65
  129. package/esm2015/lib/services/property/equity-position-chart.service.js +0 -45
  130. package/esm2015/lib/services/property/property-category/property-category.service.js +0 -23
  131. package/esm2015/lib/services/property/property-category-movement.service.js +0 -47
  132. package/esm2015/lib/services/property/property-document/property-document.service.js +0 -70
  133. package/esm2015/lib/services/property/property-sale/property-sale.service.js +0 -20
  134. package/esm2015/lib/services/property/property-sale/tax-exemption/tax-exemption.service.js +0 -21
  135. package/esm2015/lib/services/property/property-share/property-share.service.js +0 -115
  136. package/esm2015/lib/services/property/property.service.js +0 -126
  137. package/esm2015/lib/services/subscription/subscription.service.js +0 -157
  138. package/esm2015/lib/services/tax-review/tax-review-history.service.js +0 -41
  139. package/esm2015/lib/services/tax-review/tax-review.service.js +0 -103
  140. package/esm2015/lib/services/tax-summary/tax-summary.service.js +0 -71
  141. package/esm2015/lib/services/transaction/transaction-allocation.service.js +0 -85
  142. package/esm2015/lib/services/transaction/transaction.service.js +0 -319
  143. package/esm2015/lib/services/user/occupation.service.js +0 -45
  144. package/esm2015/lib/services/user/user.service.js +0 -124
  145. package/esm2015/lib/services/user-event/user-event-setting.service.js +0 -59
  146. package/esm2015/lib/services/user-event/user-event-type.service.js +0 -29
  147. package/esm2015/lib/services/work/work-tank.service.js +0 -236
  148. package/lib/services/notification/notification.service.d.ts +0 -31
  149. package/lib/services/property/property-sale/property-sale.service.d.ts +0 -10
  150. package/lib/services/property/property-sale/tax-exemption/tax-exemption.service.d.ts +0 -11
@@ -1,14 +1,14 @@
1
- import { Property as PropertyBase } from '../../db/Models/property/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
- import { BaseRestService } from '../base-rest.service';
5
- import { Property } from '../../models/property/property';
6
- import { EventDispatcherService } from '../event/event-dispatcher.service';
4
+ import { RestService } from '../rest/rest.service';
5
+ import { Property } from '../../../models/property/property';
6
+ import { EventDispatcherService } from '../../event/event-dispatcher.service';
7
7
  import * as i0 from "@angular/core";
8
8
  /**
9
9
  * Service for work with Property
10
10
  */
11
- export declare class PropertyService extends BaseRestService<PropertyBase, Property> {
11
+ export declare class PropertyService extends RestService<PropertyBase, Property> {
12
12
  protected http: HttpClient;
13
13
  protected eventDispatcherService: EventDispatcherService;
14
14
  protected environment: any;
@@ -1,6 +1,6 @@
1
1
  import { Observable, ReplaySubject } from 'rxjs';
2
2
  import { HttpClient } from '@angular/common/http';
3
- import { EventDispatcherService } from './event/event-dispatcher.service';
3
+ import { EventDispatcherService } from '../../event/event-dispatcher.service';
4
4
  import * as i0 from "@angular/core";
5
5
  /**
6
6
  * Abstract base service that implements common services functionality
@@ -8,7 +8,7 @@ import * as i0 from "@angular/core";
8
8
  * Model - entity service is working with
9
9
  * BaseModel - base entity model that extends by Model
10
10
  */
11
- export declare abstract class BaseRestService<BaseModel, Model extends BaseModel> {
11
+ export declare abstract class RestService<BaseModel, Model extends BaseModel> {
12
12
  protected http: HttpClient;
13
13
  protected eventDispatcherService: EventDispatcherService;
14
14
  protected environment: any;
@@ -86,6 +86,6 @@ export declare abstract class BaseRestService<BaseModel, Model extends BaseModel
86
86
  * @param baseModel base model instance that we will use as constructor options
87
87
  */
88
88
  protected createModelInstance(model: new (bm: BaseModel) => Model, baseModel: BaseModel): Model;
89
- static ɵfac: i0.ɵɵFactoryDeclaration<BaseRestService<any, any>, never>;
90
- static ɵprov: i0.ɵɵInjectableDeclaration<BaseRestService<any, any>>;
89
+ static ɵfac: i0.ɵɵFactoryDeclaration<RestService<any, any>, never>;
90
+ static ɵprov: i0.ɵɵInjectableDeclaration<RestService<any, any>>;
91
91
  }
@@ -0,0 +1,31 @@
1
+ import { ServiceNotification as NotificationBase } from '../../../db/Models/service-notification';
2
+ import { Notification } from '../../../models/notification/notification';
3
+ import { HttpClient } from '@angular/common/http';
4
+ import { IEventListener } from '../../../interfaces/event-listener.interface';
5
+ import { RestService } from '../rest/rest.service';
6
+ import { EventDispatcherService } from '../../event/event-dispatcher.service';
7
+ import { SseService } from '../../event/sse.service';
8
+ import * as i0 from "@angular/core";
9
+ /**
10
+ * Service to handle service notifications logic
11
+ */
12
+ export declare class ServiceNotificationService extends RestService<NotificationBase, Notification> implements IEventListener {
13
+ protected http: HttpClient;
14
+ protected eventDispatcherService: EventDispatcherService;
15
+ protected environment: any;
16
+ private sseService;
17
+ modelClass: typeof Notification;
18
+ url: string;
19
+ isHydra: boolean;
20
+ constructor(http: HttpClient, eventDispatcherService: EventDispatcherService, environment: any, sseService: SseService);
21
+ /**
22
+ * SSE and Event Dispatcher Services listeners
23
+ */
24
+ listenEvents(): void;
25
+ /**
26
+ * subscribe to new chat messages
27
+ */
28
+ private listenNotifications;
29
+ static ɵfac: i0.ɵɵFactoryDeclaration<ServiceNotificationService, never>;
30
+ static ɵprov: i0.ɵɵInjectableDeclaration<ServiceNotificationService>;
31
+ }
@@ -1,11 +1,11 @@
1
1
  import { HttpClient } from '@angular/common/http';
2
2
  import { BehaviorSubject, Observable, ReplaySubject } from 'rxjs';
3
- import { ServiceSubscriptionCollection } from '../../collections/service-subscription.collection';
4
- import { ServiceSubscription } from '../../models/service-subscription/service-subscription';
5
- import { ServicePayment } from '../../models/service-subscription/service-payment';
6
- import { EventDispatcherService } from '../event/event-dispatcher.service';
7
- import { ServiceSubscriptionItem } from '../../models/service-subscription/service-subscription-item';
8
- import { SseService } from '../event/sse.service';
3
+ import { ServiceSubscriptionCollection } from '../../../collections/service-subscription.collection';
4
+ import { ServiceSubscription } from '../../../models/service-subscription/service-subscription';
5
+ import { ServicePayment } from '../../../models/service-subscription/service-payment';
6
+ import { EventDispatcherService } from '../../event/event-dispatcher.service';
7
+ import { ServiceSubscriptionItem } from '../../../models/service-subscription/service-subscription-item';
8
+ import { SseService } from '../../event/sse.service';
9
9
  import * as i0 from "@angular/core";
10
10
  export declare class SubscriptionService {
11
11
  private http;
@@ -1,13 +1,13 @@
1
- import { TaxReview as TaxReviewBase } from '../../db/Models/tax-review';
1
+ import { TaxReview as TaxReviewBase } from '../../../../db/Models/tax-review';
2
2
  import { HttpClient } from '@angular/common/http';
3
- import { BaseRestService } from '../base-rest.service';
4
- import { TaxReview } from '../../models/tax-review/tax-review';
5
- import { EventDispatcherService } from '../event/event-dispatcher.service';
3
+ import { RestService } from '../../rest/rest.service';
4
+ import { TaxReview } from '../../../../models/tax-review/tax-review';
5
+ import { EventDispatcherService } from '../../../event/event-dispatcher.service';
6
6
  import * as i0 from "@angular/core";
7
7
  /**
8
8
  * Service to work with tax review history
9
9
  */
10
- export declare class TaxReviewHistoryService extends BaseRestService<TaxReviewBase, TaxReview> {
10
+ export declare class TaxReviewHistoryService extends RestService<TaxReviewBase, TaxReview> {
11
11
  protected http: HttpClient;
12
12
  protected eventDispatcherService: EventDispatcherService;
13
13
  protected environment: any;
@@ -1,15 +1,15 @@
1
- import { TaxReview as TaxReviewBase } from '../../db/Models/tax-review';
1
+ import { TaxReview as TaxReviewBase } from '../../../db/Models/tax-review';
2
2
  import { Observable } from 'rxjs';
3
3
  import { HttpClient } from '@angular/common/http';
4
- import { BaseRestService } from '../base-rest.service';
5
- import { IEventListener } from '../../interfaces/event-listener.interface';
6
- import { TaxReview } from '../../models/tax-review/tax-review';
7
- import { EventDispatcherService } from '../event/event-dispatcher.service';
4
+ import { RestService } from '../rest/rest.service';
5
+ import { IEventListener } from '../../../interfaces/event-listener.interface';
6
+ import { TaxReview } from '../../../models/tax-review/tax-review';
7
+ import { EventDispatcherService } from '../../event/event-dispatcher.service';
8
8
  import * as i0 from "@angular/core";
9
9
  /**
10
10
  * Service to work with tax review
11
11
  */
12
- export declare class TaxReviewService extends BaseRestService<TaxReviewBase, TaxReview> implements IEventListener {
12
+ export declare class TaxReviewService extends RestService<TaxReviewBase, TaxReview> implements IEventListener {
13
13
  protected http: HttpClient;
14
14
  protected eventDispatcherService: EventDispatcherService;
15
15
  protected environment: any;
@@ -1,7 +1,7 @@
1
1
  import { HttpClient } from '@angular/common/http';
2
2
  import { Observable, ReplaySubject } from 'rxjs';
3
- import { TaxSummary } from '../../models/tax-summary/tax-summary';
4
- import { EventDispatcherService } from '../event/event-dispatcher.service';
3
+ import { TaxSummary } from '../../../models/tax-summary/tax-summary';
4
+ import { EventDispatcherService } from '../../event/event-dispatcher.service';
5
5
  import * as i0 from "@angular/core";
6
6
  /**
7
7
  * Service to work with tax summary logic
@@ -1,16 +1,16 @@
1
1
  import { HttpClient } from '@angular/common/http';
2
- import { TransactionAllocation as TransactionAllocationBase } from '../../db/Models/transaction-allocation';
3
- import { TransactionAllocation } from '../../models/transaction/transaction-allocation';
4
- import { Transaction } from '../../models/transaction/transaction';
5
- import { BaseRestService } from '../base-rest.service';
6
- import { EventDispatcherService } from '../event/event-dispatcher.service';
2
+ import { TransactionAllocation as TransactionAllocationBase } from '../../../../db/Models/transaction-allocation';
3
+ import { TransactionAllocation } from '../../../../models/transaction/transaction-allocation';
4
+ import { Transaction } from '../../../../models/transaction/transaction';
5
+ import { RestService } from '../../rest/rest.service';
6
+ import { EventDispatcherService } from '../../../event/event-dispatcher.service';
7
7
  import { Observable } from 'rxjs';
8
8
  import * as i0 from "@angular/core";
9
9
  /**
10
10
  * Service for transaction allocations business logic
11
11
  * @TODO alex refactor
12
12
  */
13
- export declare class TransactionAllocationService extends BaseRestService<TransactionAllocationBase, TransactionAllocation> {
13
+ export declare class TransactionAllocationService extends RestService<TransactionAllocationBase, TransactionAllocation> {
14
14
  protected http: HttpClient;
15
15
  protected eventDispatcherService: EventDispatcherService;
16
16
  protected environment: any;
@@ -1,17 +1,17 @@
1
1
  import { EventEmitter } from '@angular/core';
2
2
  import { Observable } from 'rxjs';
3
- import { Transaction as TransactionBase } from '../../db/Models/transaction';
3
+ import { Transaction as TransactionBase } from '../../../db/Models/transaction';
4
4
  import { HttpClient } from '@angular/common/http';
5
- import { EventDispatcherService } from '../event/event-dispatcher.service';
6
- import { BaseRestService } from '../base-rest.service';
7
- import { Transaction } from '../../models/transaction/transaction';
8
- import { ChartAccounts } from '../../models/chart-accounts/chart-accounts';
9
- import { ChartAccountsTaxLabelsEnum } from '../../models/chart-accounts/chart-accounts-tax-labels.enum';
5
+ import { EventDispatcherService } from '../../event/event-dispatcher.service';
6
+ import { RestService } from '../rest/rest.service';
7
+ import { Transaction } from '../../../models/transaction/transaction';
8
+ import { ChartAccounts } from '../../../models/chart-accounts/chart-accounts';
9
+ import { ChartAccountsTaxLabelsEnum } from '../../../models/chart-accounts/chart-accounts-tax-labels.enum';
10
10
  import * as i0 from "@angular/core";
11
11
  /**
12
12
  * Service for transactions business logic
13
13
  */
14
- export declare class TransactionService extends BaseRestService<TransactionBase, Transaction> {
14
+ export declare class TransactionService extends RestService<TransactionBase, Transaction> {
15
15
  protected http: HttpClient;
16
16
  protected eventDispatcherService: EventDispatcherService;
17
17
  protected environment: any;
@@ -1,6 +1,6 @@
1
1
  import { Observable, ReplaySubject } from 'rxjs';
2
2
  import { HttpClient } from '@angular/common/http';
3
- import { Occupation } from '../../models/user/occupation';
3
+ import { Occupation } from '../../../../models/user/occupation';
4
4
  import * as i0 from "@angular/core";
5
5
  /**
6
6
  * Service that works with Occupations
@@ -1,11 +1,11 @@
1
1
  import { HttpClient } from '@angular/common/http';
2
- import { UserEventSetting } from '../../models/user-event/user-event-setting';
3
- import { UserEventSetting as UserEventSettingBase } from '../../db/Models/user-event-setting';
4
- import { EventDispatcherService } from '../event/event-dispatcher.service';
5
- import { BaseRestService } from '../base-rest.service';
2
+ import { UserEventSetting } from '../../../../models/user-event/user-event-setting';
3
+ import { UserEventSetting as UserEventSettingBase } from '../../../../db/Models/user-event-setting';
4
+ import { EventDispatcherService } from '../../../event/event-dispatcher.service';
5
+ import { RestService } from '../../rest/rest.service';
6
6
  import { Observable } from 'rxjs';
7
7
  import * as i0 from "@angular/core";
8
- export declare class UserEventSettingService extends BaseRestService<UserEventSettingBase, UserEventSetting> {
8
+ export declare class UserEventSettingService extends RestService<UserEventSettingBase, UserEventSetting> {
9
9
  protected http: HttpClient;
10
10
  protected eventDispatcherService: EventDispatcherService;
11
11
  protected environment: any;
@@ -1,10 +1,10 @@
1
1
  import { HttpClient } from '@angular/common/http';
2
- import { UserEventType as UserEventTypeBase } from '../../db/Models/user-event-type';
3
- import { UserEventType } from '../../models/user-event/user-event-type';
4
- import { EventDispatcherService } from '../event/event-dispatcher.service';
5
- import { BaseRestService } from '../base-rest.service';
2
+ import { UserEventType as UserEventTypeBase } from '../../../../db/Models/user-event-type';
3
+ import { UserEventType } from '../../../../models/user-event/user-event-type';
4
+ import { EventDispatcherService } from '../../../event/event-dispatcher.service';
5
+ import { RestService } from '../../rest/rest.service';
6
6
  import * as i0 from "@angular/core";
7
- export declare class UserEventTypeService extends BaseRestService<UserEventTypeBase, UserEventType> {
7
+ export declare class UserEventTypeService extends RestService<UserEventTypeBase, UserEventType> {
8
8
  protected http: HttpClient;
9
9
  protected eventDispatcherService: EventDispatcherService;
10
10
  protected environment: any;
@@ -1,8 +1,8 @@
1
1
  import { HttpClient } from '@angular/common/http';
2
2
  import { Observable, ReplaySubject } from 'rxjs';
3
- import { User } from '../../models/user/user';
4
- import { EventDispatcherService } from '../event/event-dispatcher.service';
5
- import { JwtService } from '../auth/jwt.service';
3
+ import { User } from '../../../models/user/user';
4
+ import { EventDispatcherService } from '../../event/event-dispatcher.service';
5
+ import { JwtService } from '../../auth/jwt.service';
6
6
  import * as i0 from "@angular/core";
7
7
  /**
8
8
  * Service to work with user
@@ -1,18 +1,19 @@
1
1
  import { HttpClient } from '@angular/common/http';
2
2
  import { Observable, ReplaySubject } from 'rxjs';
3
3
  import { TransactionService } from '../transaction/transaction.service';
4
- import { Vehicle } from '../../models/logbook/vehicle';
5
- import { VehicleClaim } from '../../models/logbook/vehicle-claim';
6
- import { VehicleLogbook } from '../../models/logbook/vehicle-logbook';
7
- import { IncomePosition } from '../../models/income-position/income-position';
4
+ import { Vehicle } from '../../../models/logbook/vehicle';
5
+ import { VehicleClaim } from '../../../models/logbook/vehicle-claim';
6
+ import { VehicleLogbook } from '../../../models/logbook/vehicle-logbook';
7
+ import { IncomePosition } from '../../../models/income-position/income-position';
8
8
  import { DepreciationService } from '../depreciation/depreciation.service';
9
9
  import { ChartAccountsService } from '../chart-accounts/chart-accounts.service';
10
- import { EventDispatcherService } from '../event/event-dispatcher.service';
10
+ import { EventDispatcherService } from '../../event/event-dispatcher.service';
11
11
  import * as i0 from "@angular/core";
12
12
  /**
13
13
  * Service that allows to work with WorkTank operations
14
+ * @TODO separate into multiple services, extend restService
14
15
  */
15
- export declare class WorkTankService {
16
+ export declare class VehicleService {
16
17
  private http;
17
18
  private transactionService;
18
19
  private depreciationService;
@@ -88,6 +89,6 @@ export declare class WorkTankService {
88
89
  * @param vehicle which should be deleted
89
90
  */
90
91
  deleteVehicle(vehicle: Vehicle): Observable<void>;
91
- static ɵfac: i0.ɵɵFactoryDeclaration<WorkTankService, never>;
92
- static ɵprov: i0.ɵɵInjectableDeclaration<WorkTankService>;
92
+ static ɵfac: i0.ɵɵFactoryDeclaration<VehicleService, never>;
93
+ static ɵprov: i0.ɵɵInjectableDeclaration<VehicleService>;
93
94
  }
@@ -1,6 +1,6 @@
1
1
  import { Observable } from 'rxjs';
2
2
  import { HttpClient } from '@angular/common/http';
3
- import { ChartData } from '../../models/chart/chart-data';
3
+ import { ChartData } from '../../../models/chart/chart-data';
4
4
  import * as i0 from "@angular/core";
5
5
  /**
6
6
  * Service for get property equity position half-year history chart data
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "taxtank-core",
3
- "version": "0.8.6",
3
+ "version": "0.8.7",
4
4
  "private": false,
5
5
  "peerDependencies": {
6
6
  "@angular/common": "^12.2.3 || ~13.0.0",
package/public-api.d.ts CHANGED
@@ -256,69 +256,69 @@ export * from './lib/models/user-event/user-event-type';
256
256
  /**
257
257
  * Services
258
258
  */
259
- export * from './lib/services/address/address.service';
259
+ export * from './lib/services/http/address/address.service';
260
260
  export * from './lib/services/asset/assets.service';
261
261
  export * from './lib/services/auth/auth.service';
262
262
  export * from './lib/services/auth/jwt.service';
263
- export * from './lib/services/bank/bank.service';
264
- export * from './lib/services/bank/bank-account.service';
263
+ export * from './lib/services/http/bank/bank.service';
264
+ export * from './lib/services/http/bank/bank-account/bank-account.service';
265
265
  export * from './lib/services/bank/bank-account-calculation.service';
266
- export * from './lib/services/bank/bank-connection.service';
267
- export * from './lib/services/bank/bank-transaction.service';
266
+ export * from './lib/services/http/bank/bank-connection/bank-connection.service';
267
+ export * from './lib/services/http/bank/bank-transaction/bank-transaction.service';
268
268
  export * from './lib/services/bank/bank-transaction-calculation.service';
269
- export * from './lib/services/bank/basiq.service';
270
- export * from './lib/services/borrowing-expense/borrowing-expense.service';
271
- export * from './lib/services/chart-accounts/chart-accounts.service';
272
- export * from './lib/services/chart-accounts/chart-accounts-depreciations.service';
273
- export * from './lib/services/chat/chat.service';
274
- export * from './lib/services/chat/message.service';
275
- export * from './lib/services/chat/message-document.service';
276
- export * from './lib/services/client/client-invite.service';
277
- export * from './lib/services/client/client-movement.service';
278
- export * from './lib/services/client/client-portfolio-report.service';
279
- export * from './lib/services/depreciation/capital-project.service';
280
- export * from './lib/services/depreciation/depreciation.service';
281
- export * from './lib/services/document/document-folder.service';
282
- export * from './lib/services/employee/employee.service';
283
- export * from './lib/services/employee/employee-invite.service';
269
+ export * from './lib/services/http/bank/basiq/basiq.service';
270
+ export * from './lib/services/http/loan/borrowing-expense/borrowing-expense.service';
271
+ export * from './lib/services/http/chart-accounts/chart-accounts.service';
272
+ export * from './lib/services/http/chart-accounts/chart-accounts-depreciations/chart-accounts-depreciations.service';
273
+ export * from './lib/services/http/chat/chat.service';
274
+ export * from './lib/services/http/chat/message/message.service';
275
+ export * from './lib/services/http/chat/message-document/message-document.service';
276
+ export * from './lib/services/http/firm/client-invite/client-invite.service';
277
+ export * from './lib/services/http/firm/client-movement/client-movement.service';
278
+ export * from './lib/services/http/firm/portfolio-report/client-portfolio-report.service';
279
+ export * from './lib/services/http/depreciation/depreciation-capital-project/depreciation-capital-project.service';
280
+ export * from './lib/services/http/depreciation/depreciation.service';
281
+ export * from './lib/services/http/document/document-folder/document-folder.service';
282
+ export * from './lib/services/http/firm/employee/employee.service';
283
+ export * from './lib/services/http/firm/employee-invite/employee-invite.service';
284
284
  export * from './lib/services/event/event-dispatcher.service';
285
285
  export * from './lib/services/event/sse.service';
286
- export * from './lib/services/firm/firm.service';
286
+ export * from './lib/services/http/firm/firm.service';
287
287
  export * from './lib/services/header-title/header-title.service';
288
- export * from './lib/services/income-source/income-source.service';
289
- export * from './lib/services/income-source/income-source-forecast.service';
290
- export * from './lib/services/income-source/salary-forecast.service';
291
- export * from './lib/services/income-source/sole-forecast.service';
288
+ export * from './lib/services/http/income-source/income-source.service';
289
+ export * from './lib/services/http/income-source/income-source-forecast/income-source-forecast.service';
290
+ export * from './lib/services/http/income-source/salary-forecast/salary-forecast.service';
291
+ export * from './lib/services/http/income-source/sole-forecast/sole-forecast.service';
292
292
  export * from './lib/services/intercom/intercom.service';
293
- export * from './lib/services/loan/loan.service';
294
- export * from './lib/services/notification/notification.service';
293
+ export * from './lib/services/http/loan/loan.service';
294
+ export * from './lib/services/http/service-notification/service-notification.service';
295
295
  export * from './lib/services/pdf/pdf.service';
296
296
  export * from './lib/services/preloader/preloader.service';
297
297
  export * from './lib/services/property/corelogic/corelogic.service';
298
- export * from './lib/services/property/property.service';
298
+ export * from './lib/services/http/property/property.service';
299
299
  export * from './lib/services/property/property-calculation/property-calculation.service';
300
- export * from './lib/services/property/property-category/property-category.service';
301
- export * from './lib/services/property/property-document/property-document.service';
302
- export * from './lib/services/property/property-share/property-share.service';
303
- export * from './lib/services/property/property-sale/property-sale.service';
304
- export * from './lib/services/property/equity-position-chart.service';
305
- export * from './lib/services/property/property.service';
306
- export * from './lib/services/property/property-category-movement.service';
307
- export * from './lib/services/subscription/subscription.service';
308
- export * from './lib/services/tax-review/tax-review.service';
309
- export * from './lib/services/tax-review/tax-review-history.service';
310
- export * from './lib/services/tax-summary/tax-summary.service';
311
- export * from './lib/services/transaction/transaction.service';
312
- export * from './lib/services/transaction/transaction-allocation.service';
300
+ export * from './lib/services/http/property/property-category/property-category.service';
301
+ export * from './lib/services/http/property/property-document/property-document.service';
302
+ export * from './lib/services/http/property/property-share/property-share.service';
303
+ export * from './lib/services/http/property/property-sale/property-sale.service';
304
+ export * from './lib/services/property/equity-position-chart/equity-position-chart.service';
305
+ export * from './lib/services/http/property/property.service';
306
+ export * from './lib/services/http/property/property-category-movement/property-category-movement.service';
307
+ export * from './lib/services/http/subscription/subscription.service';
308
+ export * from './lib/services/http/tax-review/tax-review.service';
309
+ export * from './lib/services/http/tax-review/tax-review-history/tax-review-history.service';
310
+ export * from './lib/services/http/tax-summary/tax-summary.service';
311
+ export * from './lib/services/http/transaction/transaction.service';
312
+ export * from './lib/services/http/transaction/transaction-allocation/transaction-allocation.service';
313
313
  export * from './lib/services/transaction/transaction-calculation.service';
314
- export * from './lib/services/user/occupation.service';
315
- export * from './lib/services/user/user.service';
314
+ export * from './lib/services/http/user/occupation/occupation.service';
315
+ export * from './lib/services/http/user/user.service';
316
316
  export * from './lib/services/user/user-switcher.service';
317
- export * from './lib/services/user-event/user-event-setting.service';
318
- export * from './lib/services/user-event/user-event-type.service';
319
- export * from './lib/services/work/work-tank.service';
317
+ export * from './lib/services/http/user/user-event-setting/user-event-setting.service';
318
+ export * from './lib/services/http/user/user-event-type/user-event-type.service';
319
+ export * from './lib/services/http/vehicle/vehicle.service';
320
320
  export * from './lib/services/xlsx/xlsx.service';
321
- export * from './lib/services/property/property-sale/tax-exemption/tax-exemption.service';
321
+ export * from './lib/services/http/property/property-sale/tax-exemption/tax-exemption.service';
322
322
  /**
323
323
  * Interfaces
324
324
  */
@@ -1,39 +0,0 @@
1
- import { Inject, Injectable } from '@angular/core';
2
- import { ReplaySubject } from 'rxjs';
3
- import { Country } from '../../models/address/country';
4
- import { map } from 'rxjs/operators';
5
- import { plainToClass } from 'class-transformer';
6
- import * as i0 from "@angular/core";
7
- import * as i1 from "@angular/common/http";
8
- export class AddressService {
9
- constructor(http, environment) {
10
- this.http = http;
11
- this.environment = environment;
12
- this.countriesSubject = new ReplaySubject(1);
13
- }
14
- getCountries() {
15
- if (!this._countries) {
16
- this.http.get(`${this.environment.apiV2}/countries`)
17
- .pipe(map((response) => {
18
- return response['hydra:member'].map((item) => plainToClass(Country, item));
19
- }))
20
- .subscribe((countries) => {
21
- this._countries = countries;
22
- this.countriesSubject.next(countries);
23
- });
24
- }
25
- return this.countriesSubject.asObservable();
26
- }
27
- }
28
- AddressService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: AddressService, deps: [{ token: i1.HttpClient }, { token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable });
29
- AddressService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: AddressService, providedIn: 'root' });
30
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: AddressService, decorators: [{
31
- type: Injectable,
32
- args: [{
33
- providedIn: 'root'
34
- }]
35
- }], ctorParameters: function () { return [{ type: i1.HttpClient }, { type: undefined, decorators: [{
36
- type: Inject,
37
- args: ['environment']
38
- }] }]; } });
39
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWRkcmVzcy5zZXJ2aWNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvdHQtY29yZS9zcmMvbGliL3NlcnZpY2VzL2FkZHJlc3MvYWRkcmVzcy5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxNQUFNLEVBQUUsVUFBVSxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBRW5ELE9BQU8sRUFBYyxhQUFhLEVBQUUsTUFBTSxNQUFNLENBQUM7QUFDakQsT0FBTyxFQUFFLE9BQU8sRUFBRSxNQUFNLDhCQUE4QixDQUFDO0FBQ3ZELE9BQU8sRUFBRSxHQUFHLEVBQUUsTUFBTSxnQkFBZ0IsQ0FBQztBQUNyQyxPQUFPLEVBQUUsWUFBWSxFQ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NlOiBvYmplY3QpID0+IHtcbiAgICAgICAgICAgIHJldHVybiByZXNwb25zZVsnaHlkcmE6bWVtYmVyJ10ubWFwKChpdGVtOiBvYmplY3QpID0+IHBsYWluVG9DbGFzcyhDb3VudHJ5LCBpdGVtKSk7XG4gICAgICAgICAgfSlcbiAgICAgICAgKVxuICAgICAgICAuc3Vic2NyaWJlKChjb3VudHJpZXM6IENvdW50cnlbXSkgPT4ge1xuICAgICAgICAgIHRoaXMuX2NvdW50cmllcyA9IGNvdW50cmllcztcbiAgICAgICAgICB0aGlzLmNvdW50cmllc1N1YmplY3QubmV4dChjb3VudHJpZXMpO1xuICAgICAgICB9KTtcbiAgICB9XG5cbiAgICByZXR1cm4gdGhpcy5jb3VudHJpZXNTdWJqZWN0LmFzT2JzZXJ2YWJsZSgpO1xuICB9XG59XG4iXX0=