taxtank-core 0.33.58 → 0.33.60

Sign up to get free protection for your applications and to get access to all the features.
Files changed (28) hide show
  1. package/esm2022/src/lib/forms/abstract.form.mjs +7 -2
  2. package/esm2022/src/lib/forms/bank/bank-account/bank-account-add-manual.form.mjs +3 -4
  3. package/esm2022/src/lib/forms/bank/bank-account/bank-account-import.form.mjs +1 -1
  4. package/esm2022/src/lib/forms/bank/bank-account/bank-account-properties.form.mjs +3 -4
  5. package/esm2022/src/lib/models/bank/bank-account.mjs +4 -6
  6. package/esm2022/src/lib/models/bank/index.mjs +1 -2
  7. package/esm2022/src/lib/models/dictionary/dictionary.mjs +2 -2
  8. package/esm2022/src/lib/services/http/rest/rest.service.mjs +8 -6
  9. package/esm2022/src/lib/services/http/transaction/transaction-allocation/allocation-rule/allocation-rule.service.mjs +5 -3
  10. package/esm2022/src/lib/services/property/corelogic/corelogic-messages.enum.mjs +5 -0
  11. package/esm2022/src/lib/services/property/corelogic/corelogic.service.mjs +13 -7
  12. package/esm2022/src/lib/services/property/corelogic/index.mjs +2 -1
  13. package/fesm2022/taxtank-core.mjs +112 -110
  14. package/fesm2022/taxtank-core.mjs.map +1 -1
  15. package/package.json +1 -1
  16. package/src/lib/forms/abstract.form.d.ts +1 -1
  17. package/src/lib/forms/bank/bank-account/bank-account-add-manual.form.d.ts +2 -3
  18. package/src/lib/forms/bank/bank-account/bank-account-properties.form.d.ts +1 -1
  19. package/src/lib/models/bank/bank-account.d.ts +0 -2
  20. package/src/lib/models/bank/index.d.ts +0 -1
  21. package/src/lib/models/dictionary/dictionary.d.ts +1 -1
  22. package/src/lib/services/http/rest/rest.service.d.ts +4 -4
  23. package/src/lib/services/http/transaction/transaction-allocation/allocation-rule/allocation-rule.service.d.ts +1 -3
  24. package/src/lib/services/property/corelogic/corelogic-messages.enum.d.ts +3 -0
  25. package/src/lib/services/property/corelogic/corelogic.service.d.ts +3 -1
  26. package/src/lib/services/property/corelogic/index.d.ts +1 -0
  27. package/esm2022/src/lib/models/bank/bank-account-types.const.mjs +0 -14
  28. package/src/lib/models/bank/bank-account-types.const.d.ts +0 -7
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "taxtank-core",
3
- "version": "0.33.58",
3
+ "version": "0.33.60",
4
4
  "private": false,
5
5
  "peerDependencies": {
6
6
  "@angular/common": "^17.0.0",
@@ -32,7 +32,7 @@ export declare abstract class AbstractForm<Model, Controls extends ControlsInter
32
32
  protected constructor(controls: Controls, model?: Model, validatorOrOpts?: ValidatorFn | ValidatorFn[] | AbstractControlOptions | null, asyncValidator?: AsyncValidatorFn | AsyncValidatorFn[] | null);
33
33
  get saved(): boolean;
34
34
  get currentValue(): Model;
35
- toggleEnabledState(control: AbstractControl): void;
35
+ toggleEnabledState(control?: AbstractControl): void;
36
36
  /**
37
37
  * Check validation and return a new instance of generic model.
38
38
  * Merge form value to initial object
@@ -1,7 +1,6 @@
1
- import { BankAccount } from '../../../models/bank/bank-account';
2
- import { BankConnection } from '../../../models/bank/bank-connection';
1
+ import { BankAccount, BankConnection } from '../../../models';
3
2
  import { BankAccountAllocationForm } from './bank-account-allocation.form';
4
- import { IEventListener } from '../../../interfaces/event-listener.interface';
3
+ import { IEventListener } from '../../../interfaces';
5
4
  /**
6
5
  * Form is using for single manual bank account creation (not Basiq)
7
6
  */
@@ -1,5 +1,5 @@
1
1
  import { UntypedFormArray } from '@angular/forms';
2
- import { BankAccountProperty } from '../../../models/bank/bank-account-property';
2
+ import { BankAccountProperty } from '../../../models';
3
3
  /**
4
4
  * Form array with bank account properties
5
5
  * @TODO create AbstractFormArray
@@ -1,5 +1,4 @@
1
1
  import { BankAccount as BankAccountBase } from '../../db/Models/bank/bank-account';
2
- import { BankAccountTypeEnum } from '../../db/Enums';
3
2
  import { Loan } from '../loan';
4
3
  import { BankAccountBalance } from '../../db/Models';
5
4
  import { BankAccountProperty } from './bank-account-property';
@@ -12,7 +11,6 @@ export declare class BankAccount extends BankAccountBase {
12
11
  balances: BankAccountBalance[];
13
12
  loan: Loan;
14
13
  bankConnection: BankConnection;
15
- type: BankAccountTypeEnum;
16
14
  get bank(): Bank;
17
15
  get bsb(): string;
18
16
  get number(): string;
@@ -4,7 +4,6 @@ export * from './bank';
4
4
  export * from './bank-account';
5
5
  export * from './bank-account-chart-data';
6
6
  export * from './bank-account-property';
7
- export * from './bank-account-types.const';
8
7
  export * from './bank-connection';
9
8
  export * from './bank-external-stats';
10
9
  export * from './bank-transaction';
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @TODO refactor with Map
2
+ * @TODO refactor with Map or Record
3
3
  * List of objects grouped by passed property
4
4
  */
5
5
  export declare class Dictionary<Model> {
@@ -49,10 +49,6 @@ export declare abstract class RestService<BaseModel, Model extends AbstractModel
49
49
  * @TODO: TT-4642 check customHttpErrorMessages fix change to backend errors
50
50
  */
51
51
  protected useBackendError: boolean;
52
- /**
53
- * messages that can be redefined in other classes to customize httpErrorMessages
54
- */
55
- protected customHttpErrorMessages: {};
56
52
  /**
57
53
  * mapping with HTTP errors codes and general messages
58
54
  */
@@ -104,6 +100,10 @@ export declare abstract class RestService<BaseModel, Model extends AbstractModel
104
100
  * Remove multiple Model instances from database
105
101
  */
106
102
  deleteBatch(models: Model[]): Observable<void>;
103
+ /**
104
+ * method with messages that can be redefined in other classes to customize httpErrorMessages
105
+ */
106
+ protected getCustomHttpErrorMessages(): Record<number, string>;
107
107
  /**
108
108
  * Handle response errors - shows error in toast
109
109
  * and throws error further
@@ -7,9 +7,7 @@ export declare class AllocationRuleService extends RestService<AllocationRuleBas
7
7
  protected endpointUri: string;
8
8
  collectionClass: typeof AllocationRuleCollection;
9
9
  modelClass: typeof AllocationRule;
10
- customHttpErrorMessages: {
11
- 422: string;
12
- };
10
+ protected getCustomHttpErrorMessages(): Record<number, string>;
13
11
  static ɵfac: i0.ɵɵFactoryDeclaration<AllocationRuleService, never>;
14
12
  static ɵprov: i0.ɵɵInjectableDeclaration<AllocationRuleService>;
15
13
  }
@@ -0,0 +1,3 @@
1
+ export declare enum CorelogicMessagesEnum {
2
+ SERVICE_UNAVAILABLE = "Corelogic service is temporary unavailable, please try again in a few minutes."
3
+ }
@@ -1,13 +1,15 @@
1
1
  import { HttpClient } from '@angular/common/http';
2
2
  import { Observable, ReplaySubject } from 'rxjs';
3
3
  import { CorelogicSuggestion } from '../../../models';
4
+ import { ToastService } from '../../toast';
4
5
  import * as i0 from "@angular/core";
5
6
  export declare class CorelogicService {
6
7
  private http;
8
+ private toastService;
7
9
  private environment;
8
10
  _accessToken: string;
9
11
  accessTokenSubject: ReplaySubject<string>;
10
- constructor(http: HttpClient, environment: any);
12
+ constructor(http: HttpClient, toastService: ToastService, environment: any);
11
13
  getAccessToken(force?: boolean): Observable<string>;
12
14
  getSuggestions(query: string, country?: string): Observable<CorelogicSuggestion[]>;
13
15
  static ɵfac: i0.ɵɵFactoryDeclaration<CorelogicService, never>;
@@ -1 +1,2 @@
1
1
  export * from './corelogic.service';
2
+ export * from './corelogic-messages.enum';
@@ -1,14 +0,0 @@
1
- import { BankAccountTypeEnum } from '../../db/Enums/bank/bank-account-type.enum';
2
- /**
3
- * Const which contains array of bank account types
4
- */
5
- export const BANK_ACCOUNT_TYPES = [
6
- { key: BankAccountTypeEnum.CREDIT_CARD, value: 'Credit Card Accounts' },
7
- { key: BankAccountTypeEnum.TERM_DEPOSIT, value: 'Deposit Accounts' },
8
- { key: BankAccountTypeEnum.INVESTMENT, value: 'Investment Accounts' },
9
- { key: BankAccountTypeEnum.LOAN, value: 'Loan Accounts' },
10
- { key: BankAccountTypeEnum.OFFSET, value: 'Offset' },
11
- { key: BankAccountTypeEnum.SAVINGS, value: 'Savings Accounts' },
12
- { key: BankAccountTypeEnum.TRANSACTION, value: 'Transaction Accounts' },
13
- ];
14
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmFuay1hY2NvdW50LXR5cGVzLmNvbnN0LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4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FycmF5IG9mIGJhbmsgYWNjb3VudCB0eXBlc1xuICovXG5leHBvcnQgY29uc3QgQkFOS19BQ0NPVU5UX1RZUEVTOiB7a2V5OiBudW1iZXIsIHZhbHVlOiBzdHJpbmd9W10gPSBbXG4gIHtrZXk6IEJhbmtBY2NvdW50VHlwZUVudW0uQ1JFRElUX0NBUkQsIHZhbHVlOiAnQ3JlZGl0IENhcmQgQWNjb3VudHMnfSxcbiAge2tleTogQmFua0FjY291bnRUeXBlRW51bS5URVJNX0RFUE9TSVQsIHZhbHVlOiAnRGVwb3NpdCBBY2NvdW50cyd9LFxuICB7a2V5OiBCYW5rQWNjb3VudFR5cGVFbnVtLklOVkVTVE1FTlQsIHZhbHVlOiAnSW52ZXN0bWVudCBBY2NvdW50cyd9LFxuICB7a2V5OiBCYW5rQWNjb3VudFR5cGVFbnVtLkxPQU4sIHZhbHVlOiAnTG9hbiBBY2NvdW50cyd9LFxuICB7a2V5OiBCYW5rQWNjb3VudFR5cGVFbnVtLk9GRlNFVCwgdmFsdWU6ICdPZmZzZXQnfSxcbiAge2tleTogQmFua0FjY291bnRUeXBlRW51bS5TQVZJTkdTLCB2YWx1ZTogJ1NhdmluZ3MgQWNjb3VudHMnfSxcbiAge2tleTogQmFua0FjY291bnRUeXBlRW51bS5UUkFOU0FDVElPTiwgdmFsdWU6ICdUcmFuc2FjdGlvbiBBY2NvdW50cyd9LFxuXTtcbiJdfQ==
@@ -1,7 +0,0 @@
1
- /**
2
- * Const which contains array of bank account types
3
- */
4
- export declare const BANK_ACCOUNT_TYPES: {
5
- key: number;
6
- value: string;
7
- }[];