taxtank-core 0.33.5 → 0.33.7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (177) hide show
  1. package/esm2022/common/src/common.module.mjs +4 -4
  2. package/esm2022/common/src/interceptors/interceptors.module.mjs +4 -4
  3. package/esm2022/common/src/interceptors/jwt-interceptor.mjs +5 -5
  4. package/esm2022/common/src/services/auth/auth.service.mjs +5 -5
  5. package/esm2022/common/src/services/auth/jwt.service.mjs +3 -3
  6. package/esm2022/common/src/services/mixpanel.service.mjs +5 -5
  7. package/esm2022/src/lib/collections/bank-account.collection.mjs +5 -41
  8. package/esm2022/src/lib/collections/collection-dictionary.mjs +12 -10
  9. package/esm2022/src/lib/collections/collection.mjs +5 -5
  10. package/esm2022/src/lib/collections/depreciation.collection.mjs +6 -18
  11. package/esm2022/src/lib/collections/property/property.collection.mjs +9 -5
  12. package/esm2022/src/lib/collections/transaction/transaction.collection.mjs +3 -15
  13. package/esm2022/src/lib/core.module.mjs +4 -4
  14. package/esm2022/src/lib/db/Enums/bank/bank-account-type.enum.mjs +2 -2
  15. package/esm2022/src/lib/db/Models/bank/bank-account.mjs +1 -1
  16. package/esm2022/src/lib/db/Models/transaction/transaction-base.mjs +6 -40
  17. package/esm2022/src/lib/forms/abstract.form.mjs +1 -1
  18. package/esm2022/src/lib/forms/address/address.form.mjs +1 -1
  19. package/esm2022/src/lib/forms/firm/client-movement.form.mjs +4 -4
  20. package/esm2022/src/lib/forms/firm/employee-details.form.mjs +4 -4
  21. package/esm2022/src/lib/forms/property/property-share.form.mjs +2 -2
  22. package/esm2022/src/lib/interceptors/basiq-client-id.interceptor.mjs +4 -4
  23. package/esm2022/src/lib/interceptors/basiq-token.interceptor.mjs +4 -4
  24. package/esm2022/src/lib/interceptors/corelogic-interceptor.mjs +5 -5
  25. package/esm2022/src/lib/interceptors/financial-year-interceptor.mjs +5 -5
  26. package/esm2022/src/lib/interceptors/interceptors.module.mjs +4 -4
  27. package/esm2022/src/lib/interceptors/preloader.interceptor.mjs +4 -4
  28. package/esm2022/src/lib/interceptors/rewardful.interceptor.mjs +5 -5
  29. package/esm2022/src/lib/interceptors/user-switcher-interceptor.mjs +5 -5
  30. package/esm2022/src/lib/models/bank/bank-account.mjs +6 -3
  31. package/esm2022/src/lib/models/bank/type-loan.const.mjs +2 -5
  32. package/esm2022/src/lib/models/depreciation/depreciation.mjs +8 -22
  33. package/esm2022/src/lib/models/financial-year/financial-year.mjs +1 -1
  34. package/esm2022/src/lib/models/property/property.mjs +1 -4
  35. package/esm2022/src/lib/models/report/index.mjs +3 -1
  36. package/esm2022/src/lib/models/report/report.interface.mjs +2 -0
  37. package/esm2022/src/lib/models/report/reports.const.mjs +73 -0
  38. package/esm2022/src/lib/models/service-subscription/service-subscription.mjs +2 -2
  39. package/esm2022/src/lib/models/sole/sole-invoice.mjs +1 -1
  40. package/esm2022/src/lib/models/transaction/transaction.mjs +1 -19
  41. package/esm2022/src/lib/models/vehicle/vehicle-claim.mjs +1 -1
  42. package/esm2022/src/lib/pipes/app-currency.pipe.mjs +3 -3
  43. package/esm2022/src/lib/pipes/safe-url.pipe.mjs +4 -4
  44. package/esm2022/src/lib/services/account-setup/account-setup.service.mjs +4 -4
  45. package/esm2022/src/lib/services/asset/assets.service.mjs +5 -5
  46. package/esm2022/src/lib/services/bank/bank-account-calculation.service.mjs +3 -3
  47. package/esm2022/src/lib/services/data.service.mjs +3 -3
  48. package/esm2022/src/lib/services/event/event-dispatcher.service.mjs +3 -3
  49. package/esm2022/src/lib/services/event/sse.service.mjs +5 -5
  50. package/esm2022/src/lib/services/export/export-formatter.service.mjs +4 -4
  51. package/esm2022/src/lib/services/firm/current-firm-branch.service.mjs +3 -3
  52. package/esm2022/src/lib/services/header-title/header-title.service.mjs +4 -4
  53. package/esm2022/src/lib/services/http/address/address.service.mjs +5 -5
  54. package/esm2022/src/lib/services/http/bank/bank-account/bank-account.service.mjs +5 -5
  55. package/esm2022/src/lib/services/http/bank/bank-connection/bank-connection.service.mjs +5 -5
  56. package/esm2022/src/lib/services/http/bank/bank-transaction/bank-transaction.service.mjs +5 -5
  57. package/esm2022/src/lib/services/http/bank/bank.service.mjs +3 -3
  58. package/esm2022/src/lib/services/http/bank/basiq/basiq-token.service.mjs +3 -3
  59. package/esm2022/src/lib/services/http/bank/basiq/basiq.service.mjs +6 -6
  60. package/esm2022/src/lib/services/http/budget/budget.service.mjs +3 -3
  61. package/esm2022/src/lib/services/http/chart-accounts/chart-accounts-depreciations/chart-accounts-depreciations.service.mjs +3 -3
  62. package/esm2022/src/lib/services/http/chart-accounts/chart-accounts.service.mjs +3 -3
  63. package/esm2022/src/lib/services/http/chat/chat.service.mjs +5 -5
  64. package/esm2022/src/lib/services/http/chat/message-document.service.mjs +5 -5
  65. package/esm2022/src/lib/services/http/chat/message.service.mjs +5 -5
  66. package/esm2022/src/lib/services/http/client/annual-client-details.service.mjs +3 -3
  67. package/esm2022/src/lib/services/http/client/capital-loss/capital-loss.service.mjs +4 -4
  68. package/esm2022/src/lib/services/http/client/client-coupon.service.mjs +3 -3
  69. package/esm2022/src/lib/services/http/client/occupation/occupation.service.mjs +5 -5
  70. package/esm2022/src/lib/services/http/depreciation/depreciation-capital-project/depreciation-capital-project.service.mjs +3 -3
  71. package/esm2022/src/lib/services/http/depreciation/depreciation.service.mjs +5 -5
  72. package/esm2022/src/lib/services/http/document/document-folder/document-folder.service.mjs +3 -3
  73. package/esm2022/src/lib/services/http/document/document.service.mjs +3 -3
  74. package/esm2022/src/lib/services/http/facebook/facebook.service.mjs +6 -6
  75. package/esm2022/src/lib/services/http/file/file.service.mjs +3 -3
  76. package/esm2022/src/lib/services/http/firm/client-invite/client-invite.service.mjs +5 -5
  77. package/esm2022/src/lib/services/http/firm/client-movement/client-movement.service.mjs +5 -5
  78. package/esm2022/src/lib/services/http/firm/employee/employee.service.mjs +3 -3
  79. package/esm2022/src/lib/services/http/firm/employee-invite/employee-invite.service.mjs +3 -3
  80. package/esm2022/src/lib/services/http/firm/firm-branch/firm-branch.service.mjs +4 -4
  81. package/esm2022/src/lib/services/http/firm/firm.service.mjs +5 -5
  82. package/esm2022/src/lib/services/http/firm/portfolio-report/client-portfolio-report.service.mjs +5 -5
  83. package/esm2022/src/lib/services/http/google/google.service.mjs +5 -5
  84. package/esm2022/src/lib/services/http/holding/holding-import/holding-import.service.mjs +4 -4
  85. package/esm2022/src/lib/services/http/holding/holding-sale.service.mjs +3 -3
  86. package/esm2022/src/lib/services/http/holding/holding-type.service.mjs +3 -3
  87. package/esm2022/src/lib/services/http/holding/holding.service.mjs +5 -5
  88. package/esm2022/src/lib/services/http/income-source/income-source-forecast/income-source-forecast.service.mjs +5 -5
  89. package/esm2022/src/lib/services/http/income-source/income-source.service.mjs +5 -5
  90. package/esm2022/src/lib/services/http/income-source/salary-forecast/salary-forecast.service.mjs +5 -5
  91. package/esm2022/src/lib/services/http/income-source/sole-forecast/sole-forecast.service.mjs +5 -5
  92. package/esm2022/src/lib/services/http/loan/borrowing-expense/borrowing-expense.service.mjs +5 -5
  93. package/esm2022/src/lib/services/http/loan/loan.service.mjs +5 -5
  94. package/esm2022/src/lib/services/http/pdf/pdf.service.mjs +5 -5
  95. package/esm2022/src/lib/services/http/property/borrowing-report/borrowing-report.service.mjs +3 -3
  96. package/esm2022/src/lib/services/http/property/property-category/property-category.service.mjs +3 -3
  97. package/esm2022/src/lib/services/http/property/property-category-movement/property-category-movement.service.mjs +3 -3
  98. package/esm2022/src/lib/services/http/property/property-document/property-document.service.mjs +3 -3
  99. package/esm2022/src/lib/services/http/property/property-sale/property-sale.service.mjs +3 -3
  100. package/esm2022/src/lib/services/http/property/property-share/property-share.service.mjs +5 -5
  101. package/esm2022/src/lib/services/http/property/property-valuation/property-valuation.service.mjs +3 -3
  102. package/esm2022/src/lib/services/http/property/property.service.mjs +5 -5
  103. package/esm2022/src/lib/services/http/rest/rest-old.service.mjs +5 -5
  104. package/esm2022/src/lib/services/http/rest/rest.service.mjs +5 -5
  105. package/esm2022/src/lib/services/http/service-notification/service-notification.service.mjs +5 -5
  106. package/esm2022/src/lib/services/http/setup-item/setup-item.service.mjs +3 -3
  107. package/esm2022/src/lib/services/http/sole/bas-report/bas-report.service.mjs +3 -3
  108. package/esm2022/src/lib/services/http/sole/sole-business/sole-business.service.mjs +3 -3
  109. package/esm2022/src/lib/services/http/sole/sole-business-activity/sole-business-activity.service.mjs +3 -3
  110. package/esm2022/src/lib/services/http/sole/sole-business-loss/sole-business-loss-rules/sole-business-loss-offset-rule.service.mjs +3 -3
  111. package/esm2022/src/lib/services/http/sole/sole-business-loss/sole-business-loss.service.mjs +5 -5
  112. package/esm2022/src/lib/services/http/sole/sole-contact/sole-contact.service.mjs +3 -3
  113. package/esm2022/src/lib/services/http/sole/sole-depreciation-method/sole-depreciation-method.service.mjs +5 -5
  114. package/esm2022/src/lib/services/http/sole/sole-details/sole-details.service.mjs +5 -5
  115. package/esm2022/src/lib/services/http/sole/sole-invoice/sole-invoice.service.mjs +5 -5
  116. package/esm2022/src/lib/services/http/sole/sole-invoice-template/sole-invoice-template.service.mjs +3 -3
  117. package/esm2022/src/lib/services/http/subscription/service-payment/service-payment.service.mjs +3 -3
  118. package/esm2022/src/lib/services/http/subscription/service-payment-method/service-payment-method.service.mjs +5 -5
  119. package/esm2022/src/lib/services/http/subscription/service-price/service-price.service.mjs +3 -3
  120. package/esm2022/src/lib/services/http/subscription/service-product/service-product.service.mjs +3 -3
  121. package/esm2022/src/lib/services/http/subscription/service-subscription/subscription.service.mjs +5 -5
  122. package/esm2022/src/lib/services/http/tax-review/tax-review-history/tax-review-history.service.mjs +5 -5
  123. package/esm2022/src/lib/services/http/tax-review/tax-review.service.mjs +5 -5
  124. package/esm2022/src/lib/services/http/tax-summary/tax-summary.service.mjs +5 -5
  125. package/esm2022/src/lib/services/http/transaction/transaction-allocation/allocation-rule/allocation-rule.service.mjs +3 -3
  126. package/esm2022/src/lib/services/http/transaction/transaction-allocation/transaction-allocation.service.mjs +5 -5
  127. package/esm2022/src/lib/services/http/transaction/transaction.service.mjs +6 -23
  128. package/esm2022/src/lib/services/http/user/financial-year/financial-year.service.mjs +5 -5
  129. package/esm2022/src/lib/services/http/user/user-event-setting/user-event-setting.service.mjs +3 -3
  130. package/esm2022/src/lib/services/http/user/user-event-type/user-event-type.service.mjs +3 -3
  131. package/esm2022/src/lib/services/http/user/user.service.mjs +5 -5
  132. package/esm2022/src/lib/services/http/user/users-invite/users-invite.service.mjs +3 -3
  133. package/esm2022/src/lib/services/http/vehicle/vehicle-claim-details.service.mjs +5 -5
  134. package/esm2022/src/lib/services/http/vehicle/vehicle-claim.service.mjs +5 -5
  135. package/esm2022/src/lib/services/http/vehicle/vehicle-logbook/vehicle-logbook.service.mjs +3 -3
  136. package/esm2022/src/lib/services/http/vehicle/vehicle.service.mjs +4 -4
  137. package/esm2022/src/lib/services/http/youtube/youtube.service.mjs +6 -6
  138. package/esm2022/src/lib/services/intercom/intercom.service.mjs +5 -5
  139. package/esm2022/src/lib/services/json/chart-accounts/chart-accounts-value.service.mjs +4 -4
  140. package/esm2022/src/lib/services/json/holding/holding-type-exchange.service.mjs +4 -4
  141. package/esm2022/src/lib/services/json/income-source/income-source-type.service.mjs +4 -4
  142. package/esm2022/src/lib/services/json/tax-exemption/tax-exemption.service.mjs +4 -4
  143. package/esm2022/src/lib/services/json/tax-return/tax-return-item.service.mjs +4 -4
  144. package/esm2022/src/lib/services/pdf/pdf-from-dom-element/pdf-from-dom-element.service.mjs +3 -3
  145. package/esm2022/src/lib/services/pdf/pdf-from-table/pdf-from-data-table/pdf-from-data-table.service.mjs +4 -4
  146. package/esm2022/src/lib/services/pdf/pdf-from-table/pdf-from-html-table/pdf-from-html-table.service.mjs +3 -3
  147. package/esm2022/src/lib/services/pdf/pdf-from-table/pdf-from-table.service.mjs +3 -3
  148. package/esm2022/src/lib/services/preloader/preloader.service.mjs +4 -4
  149. package/esm2022/src/lib/services/property/corelogic/corelogic.service.mjs +5 -5
  150. package/esm2022/src/lib/services/property/equity-position-chart/equity-position-chart.service.mjs +5 -5
  151. package/esm2022/src/lib/services/property/property-calculation/property-calculation.service.mjs +3 -3
  152. package/esm2022/src/lib/services/report/property/property-transaction-report.service.mjs +4 -4
  153. package/esm2022/src/lib/services/toast/toast.service.mjs +3 -3
  154. package/esm2022/src/lib/services/user/user-switcher.service.mjs +3 -3
  155. package/esm2022/src/lib/services/xlsx/xlsx.service.mjs +3 -3
  156. package/esm2022/src/lib/validators/unique-email.validator.mjs +4 -4
  157. package/fesm2022/taxtank-core-common.mjs +26 -26
  158. package/fesm2022/taxtank-core.mjs +632 -701
  159. package/fesm2022/taxtank-core.mjs.map +1 -1
  160. package/package.json +1 -1
  161. package/src/lib/collections/bank-account.collection.d.ts +1 -21
  162. package/src/lib/collections/collection-dictionary.d.ts +1 -1
  163. package/src/lib/collections/collection.d.ts +3 -4
  164. package/src/lib/collections/depreciation.collection.d.ts +1 -1
  165. package/src/lib/collections/property/property.collection.d.ts +1 -1
  166. package/src/lib/db/Enums/bank/bank-account-type.enum.d.ts +1 -0
  167. package/src/lib/db/Models/bank/bank-account.d.ts +0 -1
  168. package/src/lib/db/Models/transaction/transaction-base.d.ts +0 -9
  169. package/src/lib/models/bank/bank-account.d.ts +1 -0
  170. package/src/lib/models/bank/type-loan.const.d.ts +0 -3
  171. package/src/lib/models/depreciation/depreciation.d.ts +3 -11
  172. package/src/lib/models/property/property.d.ts +0 -1
  173. package/src/lib/models/report/index.d.ts +2 -0
  174. package/src/lib/models/report/report.interface.d.ts +7 -0
  175. package/src/lib/models/report/reports.const.d.ts +3 -0
  176. package/src/lib/models/transaction/transaction.d.ts +1 -6
  177. package/src/lib/services/http/transaction/transaction.service.d.ts +0 -6
@@ -19,13 +19,13 @@ export class CommonModule {
19
19
  ]
20
20
  };
21
21
  }
22
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CommonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
23
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: CommonModule, imports: [AngularCommonModule,
22
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: CommonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
23
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.12", ngImport: i0, type: CommonModule, imports: [AngularCommonModule,
24
24
  InterceptorsModule] }); }
25
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CommonModule, imports: [AngularCommonModule,
25
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: CommonModule, imports: [AngularCommonModule,
26
26
  InterceptorsModule] }); }
27
27
  }
28
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CommonModule, decorators: [{
28
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: CommonModule, decorators: [{
29
29
  type: NgModule,
30
30
  args: [{
31
31
  declarations: [],
@@ -3,9 +3,9 @@ import { HTTP_INTERCEPTORS } from '@angular/common/http';
3
3
  import { JwtInterceptor } from './jwt-interceptor';
4
4
  import * as i0 from "@angular/core";
5
5
  export class InterceptorsModule {
6
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: InterceptorsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
7
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: InterceptorsModule }); }
8
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: InterceptorsModule, providers: [
6
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: InterceptorsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
7
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.12", ngImport: i0, type: InterceptorsModule }); }
8
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: InterceptorsModule, providers: [
9
9
  {
10
10
  provide: HTTP_INTERCEPTORS,
11
11
  useClass: JwtInterceptor,
@@ -13,7 +13,7 @@ export class InterceptorsModule {
13
13
  }
14
14
  ] }); }
15
15
  }
16
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: InterceptorsModule, decorators: [{
16
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: InterceptorsModule, decorators: [{
17
17
  type: NgModule,
18
18
  args: [{
19
19
  providers: [
@@ -126,13 +126,13 @@ export class JwtInterceptor {
126
126
  // });
127
127
  });
128
128
  }
129
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: JwtInterceptor, deps: [{ token: i1.JwtService }, { token: i1.AuthService }, { token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable }); }
130
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: JwtInterceptor }); }
129
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: JwtInterceptor, deps: [{ token: i1.JwtService }, { token: i1.AuthService }, { token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable }); }
130
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: JwtInterceptor }); }
131
131
  }
132
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: JwtInterceptor, decorators: [{
132
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: JwtInterceptor, decorators: [{
133
133
  type: Injectable
134
- }], ctorParameters: function () { return [{ type: i1.JwtService }, { type: i1.AuthService }, { type: undefined, decorators: [{
134
+ }], ctorParameters: () => [{ type: i1.JwtService }, { type: i1.AuthService }, { type: undefined, decorators: [{
135
135
  type: Inject,
136
136
  args: ['environment']
137
- }] }]; } });
137
+ }] }] });
138
138
  //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiand0LWludGVyY2VwdG9yLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvdHQtY29yZS9jb21tb24vc3JjL2ludGVyY2VwdG9ycy9qd3QtaW50ZXJjZXB0b3IudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLGVBQWUsRUFBYyxVQUFVLElBQUksb0JBQW9CLEVBQUUsTUFBTSxNQUFNLENBQUM7QUFDdkYsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLEVBQUUsUUFBUSxFQUFFLFNBQVMsRUFBRSxJQUFJLEVBQUUsTUFBTSxnQkFBZ0IsQ0FBQztBQUMvRSxPQUFPLEVBQUUsTUFBTSxFQUFFLFVBQVUsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUNuRCxPQUFPLEVBQUUsaUJBQWlCLEVBQXdELE1BQU0sc0JBQXNCLENBQUM7OztBQUcvRyxNQUFNLHlCQUF5QixHQUFHLG9GQUFvRixDQUFDO0FBRXZIOztHQUVHO0FBRUgsTUFBTSxPQUFPLGNBQWM7SUFJekIsWUFDUyxVQUFzQixFQUNyQixXQUF3QixFQUNELFdBQWdCO1FBRnhDLGVBQVUsR0FBVixVQUFVLENBQVk7UUFDckIsZ0JBQVcsR0FBWCxXQUFXLENBQWE7UUFDRCxn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1xuICAgKiBAcGFyYW0gZXJyb3JSZXNwb25zZSBmcm9tIHdoaWNoIG1lc3NhZ2VzIHNob3VsZCBiZSB0YWtlblxuICAgKlxuICAgKiBAVE9ETyBtb3ZlIHRvIHNlcGFyYXRlZCBpbnRlcmNlcHRvclxuICAgKi9cbiAgcHJpdmF0ZSBzaG93RXJyb3JNZXNzYWdlcyhlcnJvclJlc3BvbnNlOiBIdHRwRXJyb3JSZXNwb25zZSk6IHZvaWQge1xuICAgIGlmICghZXJyb3JSZXNwb25zZS5lcnJvci52aW9sYXRpb25zKSB7XG4gICAgICAvLyB0aGlzLnNuYWNrQmFyLm9wZW4oJ1NvbWV0aGluZyB3ZW50IHdyb25nJywgJycsIHtcbiAgICAgIC8vICAgcGFuZWxDbGFzczogJ2Vycm9yJ1xuICAgICAgLy8gfSk7XG5cbiAgICAgIHJldHVybjtcbiAgICB9XG4gICAgZXJyb3JSZXNwb25zZS5lcnJvci52aW9sYXRpb25zLmZvckVhY2goKHZpb2xhdGlvbjogb2JqZWN0KTogdm9pZCA9PiB7XG4gICAgICAvLyB0aGlzLnNuYWNrQmFyLm9wZW4odmlvbGF0aW9uWydtZXNzYWdlJ10sICcnLCB7XG4gICAgICAvLyAgIHBhbmVsQ2xhc3M6ICdlcnJvcidcbiAgICAgIC8vIH0pO1xuICAgIH0pO1xuICB9XG59XG4iXX0=
@@ -41,16 +41,16 @@ export class AuthService {
41
41
  localStorage.clear();
42
42
  location.replace(url);
43
43
  }
44
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AuthService, deps: [{ token: i1.HttpClient }, { token: i2.JwtService }, { token: i3.MixpanelService }, { token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable }); }
45
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AuthService, providedIn: 'root' }); }
44
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: AuthService, deps: [{ token: i1.HttpClient }, { token: i2.JwtService }, { token: i3.MixpanelService }, { token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable }); }
45
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: AuthService, providedIn: 'root' }); }
46
46
  }
47
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AuthService, decorators: [{
47
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: AuthService, decorators: [{
48
48
  type: Injectable,
49
49
  args: [{
50
50
  providedIn: 'root'
51
51
  }]
52
- }], ctorParameters: function () { return [{ type: i1.HttpClient }, { type: i2.JwtService }, { type: i3.MixpanelService }, { type: undefined, decorators: [{
52
+ }], ctorParameters: () => [{ type: i1.HttpClient }, { type: i2.JwtService }, { type: i3.MixpanelService }, { type: undefined, decorators: [{
53
53
  type: Inject,
54
54
  args: ['environment']
55
- }] }]; } });
55
+ }] }] });
56
56
  //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXV0aC5zZXJ2aWNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvdHQtY29yZS9jb21tb24vc3JjL3NlcnZpY2VzL2F1dGgvYXV0aC5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxNQUFNLEVBQUUsVUFBVSxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQ25ELE9BQU8sRUFBYyxpQkFBaUIsRUFBRSxNQUFNLHNCQUFzQixDQUFDO0FBRXJFLE9BQU8sRUFBRSxHQUFHLEVBQUUsTUFBTSxnQkFBZ0IsQ0FBQzs7Ozs7QUFRckMsTUFBTSxPQU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UudG9rZW4pLnJvbGVzLmluY2x1ZGVzKHJvbGUpKSB7XG4gICAgICAgICAgdGhpcy5zZXRBdXRoKHJlc3BvbnNlKTtcbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICB0aHJvdyBuZXcgSHR0cEVycm9yUmVzcG9uc2Uoe1xuICAgICAgICAgICAgZXJyb3I6IHsgY29kZTogNDAxLCBtZXNzYWdlOiAnWW91ciBUYXhUYW5rIHN1YnNjcmlwdGlvbiBpcyBleHBpcmVkLiBQbGVhc2UgcmVhY3RpdmF0ZSB5b3VyIGFjY291bnQgdG8gbGluayB0aGUgd2lkZ2V0LicgfSxcbiAgICAgICAgICAgIHN0YXR1czogNDAxLFxuICAgICAgICAgICAgc3RhdHVzVGV4dDogJ1VuYXV0aG9yaXplZCcsXG4gICAgICAgICAgfSlcbiAgICAgICAgfVxuXG4gICAgICAgIHJldHVybiByZXNwb25zZTtcbiAgICAgIH0pXG4gICAgKTtcbiAgfVxuXG4gIHJlZnJlc2gocmVmcmVzaFRva2VuOiBzdHJpbmcpIHtcbiAgICByZXR1cm4gdGhpcy5odHRwLnBvc3QoYCR7dGhpcy5lbnZpcm9ubWVudC5hcGlWMn0vdG9rZW4vcmVmcmVzaGAsIHsgcmVmcmVzaFRva2VuIH0pLnBpcGUoXG4gICAgICBtYXAoKHJlc3BvbnNlOiBhbnkpID0+IHtcbiAgICAgICAgdGhpcy5zZXRBdXRoKHJlc3BvbnNlKTtcblxuICAgICAgICByZXR1cm4gcmVzcG9uc2U7XG4gICAgICB9KVxuICAgICk7XG4gIH1cblxuICBsb2dvdXRGcm9udCh1cmwgPSAnL2xvZ2luJyk6IHZvaWQge1xuICAgIHRoaXMuand0U2VydmljZS5kZXN0cm95VG9rZW5zKCk7XG4gICAgbG9jYWxTdG9yYWdlLmNsZWFyKCk7XG4gICAgbG9jYXRpb24ucmVwbGFjZSh1cmwpO1xuICB9XG59XG4iXX0=
@@ -40,10 +40,10 @@ export class JwtService extends JwtHelperService {
40
40
  isMe(userId) {
41
41
  return this.decode().id === userId;
42
42
  }
43
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: JwtService, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
44
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: JwtService, providedIn: 'root' }); }
43
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: JwtService, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
44
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: JwtService, providedIn: 'root' }); }
45
45
  }
46
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: JwtService, decorators: [{
46
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: JwtService, decorators: [{
47
47
  type: Injectable,
48
48
  args: [{
49
49
  providedIn: 'root'
@@ -45,16 +45,16 @@ export class MixpanelService {
45
45
  }
46
46
  mixpanel['track_pageview']();
47
47
  }
48
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: MixpanelService, deps: [{ token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable }); }
49
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: MixpanelService, providedIn: 'root' }); }
48
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MixpanelService, deps: [{ token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable }); }
49
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MixpanelService, providedIn: 'root' }); }
50
50
  }
51
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: MixpanelService, decorators: [{
51
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MixpanelService, decorators: [{
52
52
  type: Injectable,
53
53
  args: [{
54
54
  providedIn: 'root'
55
55
  }]
56
- }], ctorParameters: function () { return [{ type: undefined, decorators: [{
56
+ }], ctorParameters: () => [{ type: undefined, decorators: [{
57
57
  type: Inject,
58
58
  args: ['environment']
59
- }] }]; } });
59
+ }] }] });
60
60
  //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibWl4cGFuZWwuc2VydmljZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3R0LWNvcmUvY29tbW9uL3NyYy9zZXJ2aWNlcy9taXhwYW5lbC5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxNQUFNLEVBQUUsVUFBVSxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQ25ELE9BQU8sUUFBUSxNQUFNLGtCQUFrQixDQUFDOztBQUV4Qzs7R0FFRztBQUlILE1BQU0sT0FBTyxlQUFlO0lBQzFCLFlBQTJDLFdBQWdCO1FBQWhCLGdCQUFXLEdBQVgsV0FBVyxDQUFLO0lBQUcsQ0FBQztJQUUvRCxJQUFJO1FBQ0YsSUFBSSxDQUFDLElBQUksQ0FBQyxXQUFXLENBQUMsY0FBYyxFQUFFO1lBQ3BDLE9BQU87U0FDUjtRQUVELFFBQVEsQ0FBQyxJQUFJLENBQUMsSUFBSSxDQUFDLFdBQVcsQ0FBQyxhQUFhLENBQUMsQ0FBQztJQUNoRCxDQUFDO0lBRUQsUUFBUSxDQUFDLEVBQVU7UUFDakIsSUFBSSxDQUFDLElBQUksQ0FBQyxXQUFX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9KVxuICB9XG5cbiAgcmVzZXQoKTogdm9pZCB7XG4gICAgaWYgKCF0aGlzLmVudmlyb25tZW50LmVuYWJsZU1peHBhbmVsKSB7XG4gICAgICByZXR1cm47XG4gICAgfVxuXG4gICAgbWl4cGFuZWwucmVzZXQoKTtcbiAgfVxuXG4gIHRyYWNrKGV2ZW50OiBzdHJpbmcsIHByb3BlcnRpZXM6IHsgW2tleTogc3RyaW5nXTogYW55IH0gPSB7fSk6IHZvaWQge1xuICAgIGlmICghdGhpcy5lbnZpcm9ubWVudC5lbmFibGVNaXhwYW5lbCkge1xuICAgICAgcmV0dXJuO1xuICAgIH1cblxuICAgIG1peHBhbmVsLnRyYWNrKGV2ZW50LCBwcm9wZXJ0aWVzKTtcbiAgfVxuXG4gIHRyYWNrTGluayhpZDogc3RyaW5nLCBldmVudDogc3RyaW5nKTogdm9pZCB7XG4gICAgaWYgKCF0aGlzLmVudmlyb25tZW50LmVuYWJsZU1peHBhbmVsKSB7XG4gICAgICByZXR1cm47XG4gICAgfVxuXG4gICAgbWl4cGFuZWxbJ3RyYWNrX2xpbmtzJ10oYCMke2lkfWAsIGV2ZW50KTtcbiAgfVxuXG4gIHRyYWNrUGFnZVZpZXcoKTogdm9pZCB7XG4gICAgaWYgKCF0aGlzLmVudmlyb25tZW50LmVuYWJsZU1peHBhbmVsKSB7XG4gICAgICByZXR1cm47XG4gICAgfVxuXG4gICAgbWl4cGFuZWxbJ3RyYWNrX3BhZ2V2aWV3J10oKTtcbiAgfVxufVxuIl19
@@ -4,33 +4,12 @@ import { TYPE_LOAN } from '../models';
4
4
  import flatten from 'lodash/flatten';
5
5
  import uniqBy from 'lodash/uniqBy';
6
6
  import uniq from 'lodash/uniq';
7
- import concat from 'lodash/concat';
8
7
  import { CollectionDictionary } from './collection-dictionary';
9
8
  import { LoanCollection } from './loan';
10
9
  /**
11
10
  * Collection of bank accounts.
12
11
  */
13
12
  export class BankAccountCollection extends Collection {
14
- /**
15
- * get list of bank accounts with passed types
16
- */
17
- getByType(types, isExclude = false) {
18
- // get types always as array (if only one passed)
19
- const typesArray = concat(types);
20
- return this.items.filter((bankAccount) => {
21
- if (isExclude) {
22
- return !typesArray.includes(bankAccount.type);
23
- }
24
- return typesArray.includes(bankAccount.type);
25
- });
26
- }
27
- /**
28
- * get amount of current loans
29
- */
30
- getCurrentLoanAmount() {
31
- return this.getByType(TYPE_LOAN)
32
- .reduce((sum, bankAccount) => sum += bankAccount.currentBalance, 0);
33
- }
34
13
  /**
35
14
  * get collection filtered by property id
36
15
  */
@@ -59,18 +38,15 @@ export class BankAccountCollection extends Collection {
59
38
  getActive() {
60
39
  return this.getOwn().filter((bankAccount) => bankAccount.isActive());
61
40
  }
62
- /**
63
- * Get collection of loan bank accounts
64
- */
65
41
  getLoanAccounts() {
66
- return new BankAccountCollection(this.getByType(TYPE_LOAN));
42
+ return this.filterBy('type', TYPE_LOAN);
43
+ }
44
+ getDebitAccounts() {
45
+ return this.filter(bankAccount => ![...TYPE_LOAN, BankAccountTypeEnum.CREDIT_CARD].includes(bankAccount.type));
67
46
  }
68
47
  get loans() {
69
48
  return new LoanCollection(this.filterBy('type', BankAccountTypeEnum.LOAN).map((bankAccount) => bankAccount.loan));
70
49
  }
71
- getSavingsAccounts() {
72
- return new BankAccountCollection(this.getByType(TYPE_LOAN, true));
73
- }
74
50
  getOpeningBalance() {
75
51
  return this.items.reduce((sum, bankAccount) => sum + bankAccount.getOpeningBalance(), 0);
76
52
  }
@@ -80,18 +56,6 @@ export class BankAccountCollection extends Collection {
80
56
  get bankShortNames() {
81
57
  return uniq(this.map((bankAccount) => bankAccount.bank.shortName)).join(', ');
82
58
  }
83
- /**
84
- * Get Collection of bank accounts with property tank type
85
- */
86
- getPropertyBankAccounts() {
87
- return new BankAccountCollection(this.items.filter((bankAccount) => bankAccount.isPropertyTank()));
88
- }
89
- /**
90
- * Get Collection of bank accounts with work tank type
91
- */
92
- getWorkBankAccounts() {
93
- return new BankAccountCollection(this.items.filter((bankAccount) => bankAccount.isWorkTank()));
94
- }
95
59
  /**
96
60
  * Get Collection of bank accounts by tank type
97
61
  */
@@ -150,4 +114,4 @@ export class BankAccountCollection extends Collection {
150
114
  return this.getActive().getLoanAccounts().getByPropertiesIds(ids);
151
115
  }
152
116
  }
153
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmFuay1hY2NvdW50LmNvbGxlY3Rpb24uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy90dC1jb3JlL3NyYy9saWIvY29sbGVjdGlvbnMvYmFuay1hY2NvdW50LmNvbGxlY3Rpb24udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLGNBQWMsQ0FBQztBQUMxQyxPQUFPLEVBQUUsbUJBQW1CLEVBQUUsTUFBTSxhQUFhLENBQUM7QUFFbEQsT0FBTyxFQUE4QyxTQUFTLEVBQUUsTUFBTSxXQUFXLENBQUM7QUFDbEYsT0FBTyxPQUFPLE1BQU0sZ0JBQWdCLENBQUM7QUFDckMsT0FBTyxNQUFNLE1BQU0sZUFBZSxDQUFDO0FBQ25DLE9BQU8sSUFBSSxNQUFNLGFBQWEsQ0FBQztBQUMvQixPQUFPLE1BQU0sTUFBTSxlQUFlLENBQUM7QUFDbkMsT0FBTyxFQUFFLG9CQUFvQixFQUFFLE1BQU0seUJBQXlCLENBQUM7QUFDL0QsT0FBTyxFQUFFLGNBQWMsRUFBRSxNQUFNLFFBQVEsQ0FBQztBQUV4Qzs7R0FFRztBQUNILE1BQU0sT0FBTyxxQkFBc0IsU0FBUSxVQUF1QjtJQUNoRTs7T0FFRztJQUNILFNBQVMsQ0FBQyxLQUFrRCxFQUFFLFNBQVMsR0FBRyxLQUFLO1FBQzdFLGlEQUFpRDtRQUNqRCxNQUFNLFVBQVUsR0FBMEIsTUFBTSxDQUFDLEtB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eTogUHJvcGVydHkpOiBudW1iZXIge1xuICAgIHJldHVybiB0aGlzLmdldFByb3BlcnR5QmFsYW5jZUFtb3VudChwcm9wZXJ0eS5pZCkgLyBwcm9wZXJ0eS5jdXJyZW50WWVhckZvcmVjYXN0Lm1hcmtldFZhbHVlO1xuICB9XG5cbiAgLyoqXG4gICAqIEBUT0RPIEFsZXgvVmlrOiBtYXliZSB3ZSBzaG91bGQgZ2V0IGl0IGZyb20gand0VG9rZW4gb3IgdGhpbmsgYWJvdXQgc29tZSBsb2NhbFN0b3JhZ2VTZXJ2aWNlP1xuICAgKi9cbiAgZ2V0T3duKCk6IHRoaXMge1xuICAgIHJldHVybiB0aGlzLmZpbHRlcigoYmFua0FjY291bnQ6IEJhbmtBY2NvdW50KSA9PiBiYW5rQWNjb3VudC5pc093bmVyKCtsb2NhbFN0b3JhZ2UuZ2V0SXRlbSgndXNlcklkJykpKTtcbiAgfVxuXG4gIGdldEFjdGl2ZUxvYW5BY2NvdW50c0J5UHJvcGVydGllcyhpZHM6IG51bWJlcltdKTogQmFua0FjY291bnRDb2xsZWN0aW9uIHtcbiAgICByZXR1cm4gdGhpcy5nZXRBY3RpdmUoKS5nZXRMb2FuQWNjb3VudHMoKS5nZXRCeVByb3BlcnRpZXNJZHMoaWRzKTtcbiAgfVxufVxuIl19
@@ -94,15 +94,17 @@ export class CollectionDictionary {
94
94
  const obj = {};
95
95
  // Group collection items
96
96
  collection.items.forEach((item) => {
97
- let key = get(item, path);
98
- // if object does not have property for grouping it will be grouped as 'other'
99
- if (key === undefined) {
100
- key = 'other';
101
- }
102
- if (!obj[key]) {
103
- obj[key] = [];
104
- }
105
- obj[key].push(item);
97
+ const keys = Array.isArray(get(item, path)) ? get(item, path) : [get(item, path)];
98
+ keys.forEach(key => {
99
+ // if object does not have property for grouping it will be grouped as 'other'
100
+ if (key === undefined) {
101
+ key = 'other';
102
+ }
103
+ if (!obj[key]) {
104
+ obj[key] = [];
105
+ }
106
+ obj[key].push(item);
107
+ });
106
108
  });
107
109
  // Create collections from groups
108
110
  Object.keys(obj).forEach((key) => {
@@ -110,4 +112,4 @@ export class CollectionDictionary {
110
112
  });
111
113
  }
112
114
  }
113
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29sbGVjdGlvbi1kaWN0aW9uYXJ5LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvdHQtY29yZS9zcmMvbGliL2NvbGxlY3Rpb25zL2NvbGxlY3Rpb24tZGljdGlvbmFyeS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEdBQUcsTUFBTSxZQUFZLENBQUM7QUFDN0IsT0FBTyxPQUFPLE1BQU0sZ0JBQWdCLENBQUM7QUFDckMsT0FBTyxLQUFLLE1BQU0sY0FBYyxDQUFDO0FBR2pDLE9BQU8sWUFBWSxNQUFNLHFCQUFxQixDQUFDO0FBQy9DLE9BQU8sTUFBTSxNQUFNLGVBQWUsQ0FBQztBQUVuQzs7O0dBR0c7QUFDSCxNQUFNLE9BQU8sb0JBQW9CO0lBVy9CLFlBQVksVUFBc0IsRUFBRSxJQUFJLEdBQUcsSUFBSTtRQVYvQzs7V0FFRztRQUNILFVBQUssR0FBa0MsRUFBRSxDQUFDO1FBUXhDLElBQUksQ0FBQyxxQkFBcUIsR0FBRyxVQUFVLENBQUMsV0FBa0QsQ0FBQztRQUMzRixnRUFBZ0U7UUFDaEUsSUFBSSxVQUFVLENBQUMsTUFBTSxJQUFJLEtBQUssQ0FBQyxVQUFVLENBQUMsS0FBSyxDQUFDLENBQUMsQ0FBQyxFQUFFLElBQUksQ0FBQyxLQUFLLENBQUMsR0FBRyxDQUFDLENBQUMsQ0FBQyxDQUFDLENBQUMsRUFBRTtZQUN2RSxJQUFJLENBQUMsVUFBVSxDQUFDLFVBQVUsRUFBRSxJQUFJLENBQUMsQ0FBQztTQUNuQzt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Y3Rpb24gaXRlbXMgYnkgcGFzc2VkIHBhdGggaW50byBpdGVtcyBvYmplY3RcbiAgICovXG4gIHByaXZhdGUgZ3JvdXBJdGVtcyhjb2xsZWN0aW9uOiBDb2xsZWN0aW9uLCBwYXRoOiBzdHJpbmcpOiB2b2lkIHtcbiAgICAvLyBDcmVhdGUgZW1wdHkgaW5pdGlhbCBvYmplY3QgZm9yIGdyb3Vwc1xuICAgIGNvbnN0IG9iajogeyBba2V5OiBzdHJpbmddOiBBcnJheTxvYmplY3Q+IH0gPSB7fTtcblxuICAgIC8vIEdyb3VwIGNvbGxlY3Rpb24gaXRlbXNcbiAgICBjb2xsZWN0aW9uLml0ZW1zLmZvckVhY2goKGl0ZW06IG9iamVjdCk6IHZvaWQgPT4ge1xuICAgICAgbGV0IGtleTogc3RyaW5nID0gZ2V0KGl0ZW0sIHBhdGgpO1xuXG4gICAgICAvLyBpZiBvYmplY3QgZG9lcyBub3QgaGF2ZSBwcm9wZXJ0eSBmb3IgZ3JvdXBpbmcgaXQgd2lsbCBiZSBncm91cGVkIGFzICdvdGhlcidcbiAgICAgIGlmIChrZXkgPT09IHVuZGVmaW5lZCkge1xuICAgICAgICBrZXkgPSAnb3RoZXInO1xuICAgICAgfVxuXG4gICAgICBpZiAoIW9ialtrZXldKSB7XG4gICAgICAgIG9ialtrZXldID0gW107XG4gICAgICB9XG5cbiAgICAgIG9ialtrZXldLnB1c2goaXRlbSk7XG4gICAgfSk7XG5cbiAgICAvLyBDcmVhdGUgY29sbGVjdGlvbnMgZnJvbSBncm91cHNcbiAgICBPYmplY3Qua2V5cyhvYmopLmZvckVhY2goKGtleTogc3RyaW5nKTogdm9pZCA9PiB7XG4gICAgICB0aGlzLml0ZW1zW2tleV0gPSB0aGlzLmNyZWF0ZUNvbGxlY3Rpb24ob2JqW2tleV0pO1xuICAgIH0pO1xuICB9XG59XG4iXX0=
115
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29s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ZXlzKG9iaikuZm9yRWFjaCgoa2V5OiBzdHJpbmcpOiB2b2lkID0+IHtcbiAgICAgIHRoaXMuaXRlbXNba2V5XSA9IHRoaXMuY3JlYXRlQ29sbGVjdGlvbihvYmpba2V5XSk7XG4gICAgfSk7XG4gIH1cbn1cbiJdfQ==
@@ -128,9 +128,9 @@ export class Collection {
128
128
  this.items.unshift(...items);
129
129
  return this.create(this.items);
130
130
  }
131
- remove(...items) {
131
+ remove(items, path = 'id') {
132
132
  items.forEach((item) => {
133
- const index = this.findIndexBy('id', item.id);
133
+ const index = this.findIndexBy(path, get(item, path));
134
134
  if (index < 0) {
135
135
  return;
136
136
  }
@@ -151,8 +151,8 @@ export class Collection {
151
151
  }
152
152
  return this.create(this.items);
153
153
  }
154
- diff(items) {
155
- return this.filter((model) => !items.map((item) => item.id).includes(model.id));
154
+ diff(items, path = 'id') {
155
+ return this.filter((model) => !items.map((item) => get(item, path)).includes(get(model, path)));
156
156
  }
157
157
  minBy(path) {
158
158
  return this.items.reduce((prev, current) => (get(prev, path) < get(current, path) ? prev : current));
@@ -171,4 +171,4 @@ export class Collection {
171
171
  return this;
172
172
  }
173
173
  }
174
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29sbGVjdGlvbi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3R0LWNvcmUvc3JjL2xpYi9jb2xsZWN0aW9ucy9jb2xsZWN0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxvQkFBb0IsRUFBRSxNQUFNLHlCQUF5QixDQUFDO0FBQy9ELE9BQU8sS0FBSyxNQUFNLGNBQWMsQ0FBQztBQUNqQyxPQUFPLElBQUksTUFBTSxhQUFhLENBQUM7QUFDL0IsT0FBTyxHQUFHLE1BQU0sWUFBWSxDQUFDO0FBRTdCLE9BQU8sR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ZGVsKSA9PiBpdGVtLmlkKS5pbmNsdWRlcyhtb2RlbC5pZCkpO1xyXG4gIH1cclxuXHJcbiAgbWluQnkocGF0aDogc3RyaW5nKTogTW9kZWwge1xyXG4gICAgcmV0dXJuIHRoaXMuaXRlbXMucmVkdWNlKChwcmV2OiBNb2RlbCwgY3VycmVudDogTW9kZWwpID0+IChnZXQocHJldiwgcGF0aCkgPCBnZXQoY3VycmVudCwgcGF0aCkgPyBwcmV2IDogY3VycmVudCkpO1xyXG4gIH1cclxuXHJcbiAgbWF4QnkocGF0aDogc3RyaW5nKTogTW9kZWwge1xyXG4gICAgcmV0dXJuIHRoaXMuaXRlbXMucmVkdWNlKChwcmV2OiBNb2RlbCwgY3VycmVudDogTW9kZWwpID0+IChnZXQocHJldiwgcGF0aCkgPiBnZXQoY3VycmVudCwgcGF0aCkgPyBwcmV2IDogY3VycmVudCkpO1xyXG4gIH1cclxuXHJcbiAgLyoqXHJcbiAgICogZmxvYXQgbWF0aCBpc3N1ZXMgaHR0cHM6Ly9zdGFja292ZXJmbG93LmNvbS9xdWVzdGlvbnMvMTI1MTEwNTcvZmxvYXQtc3VtLXdpdGgtamF2YXNjcmlwdFxyXG4gICAqL1xyXG4gIHJlZHVjZShjYWxsYmFjazogKHN1bTogbnVtYmVyLCBpdGVtOiBNb2RlbCkgPT4gbnVtYmVyLCBpbml0ID0gMCk6IG51bWJlciB7XHJcbiAgICByZXR1cm4gK3RoaXMuaXRlbXMucmVkdWNlKGNhbGxiYWNrLCBpbml0KS50b0ZpeGVkKDEwKTtcclxuICB9XHJcblxyXG4gIHNsaWNlKGZyb206IG51bWJlciwgdG86IG51bWJlcik6IHRoaXMge1xyXG4gICAgdGhpcy5pdGVtcyA9IHRoaXMuaXRlbXMuc2xpY2UoZnJvbSwgdG8pO1xyXG5cclxuICAgIHJldHVybiB0aGlzO1xyXG4gIH1cclxufVxyXG4iXX0=
174
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaW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