taxtank-core 0.32.59 → 0.32.62
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/esm2022/lib/db/Enums/user-event-type-type.enum.mjs +2 -1
- package/esm2022/lib/services/http/firm/employee/employee.service.mjs +2 -1
- package/esm2022/lib/services/http/firm/employee-invite/employee-invite.service.mjs +1 -2
- package/esm2022/lib/services/http/rest/rest-old.service.mjs +2 -1
- package/esm2022/lib/services/http/rest/rest.service.mjs +3 -1
- package/esm2022/lib/services/http/transaction/transaction-allocation/transaction-allocation.service.mjs +10 -1
- package/esm2022/lib/services/http/transaction/transaction.service.mjs +10 -1
- package/fesm2022/taxtank-core.mjs +21 -1
- package/fesm2022/taxtank-core.mjs.map +1 -1
- package/lib/db/Enums/user-event-type-type.enum.d.ts +1 -0
- package/lib/services/http/firm/employee/employee.service.d.ts +2 -1
- package/lib/services/http/firm/employee-invite/employee-invite.service.d.ts +1 -2
- package/lib/services/http/transaction/transaction-allocation/transaction-allocation.service.d.ts +1 -0
- package/lib/services/http/transaction/transaction.service.d.ts +1 -0
- package/package.json +1 -1
|
@@ -10805,6 +10805,7 @@ let RestService$1 = class RestService extends DataService {
|
|
|
10805
10805
|
* Refresh cache with actual backend data
|
|
10806
10806
|
*/
|
|
10807
10807
|
refreshCache() {
|
|
10808
|
+
console.log('refreshCacheNew');
|
|
10808
10809
|
this.cache = undefined;
|
|
10809
10810
|
this.get();
|
|
10810
10811
|
}
|
|
@@ -11029,6 +11030,7 @@ let RestService$1 = class RestService extends DataService {
|
|
|
11029
11030
|
}
|
|
11030
11031
|
return { method, model };
|
|
11031
11032
|
})).subscribe((change) => {
|
|
11033
|
+
console.log('mercure: ' + change);
|
|
11032
11034
|
this.handleResponse([change.model], change.method);
|
|
11033
11035
|
});
|
|
11034
11036
|
}
|
|
@@ -11246,6 +11248,7 @@ var UserEventTypeTypeEnum;
|
|
|
11246
11248
|
UserEventTypeTypeEnum[UserEventTypeTypeEnum["BASIQ_FIRST_IMPORT_COMPLETE"] = 2031] = "BASIQ_FIRST_IMPORT_COMPLETE";
|
|
11247
11249
|
UserEventTypeTypeEnum[UserEventTypeTypeEnum["BASIQ_AUTHORIZATION_FAIL"] = 2032] = "BASIQ_AUTHORIZATION_FAIL";
|
|
11248
11250
|
UserEventTypeTypeEnum[UserEventTypeTypeEnum["TRANSACTION_ALLOCATE_REMINDER"] = 2033] = "TRANSACTION_ALLOCATE_REMINDER";
|
|
11251
|
+
UserEventTypeTypeEnum[UserEventTypeTypeEnum["AUTO_ALLOCATION"] = 2035] = "AUTO_ALLOCATION";
|
|
11249
11252
|
UserEventTypeTypeEnum[UserEventTypeTypeEnum["REGISTRATION_INVITE"] = 2040] = "REGISTRATION_INVITE";
|
|
11250
11253
|
UserEventTypeTypeEnum[UserEventTypeTypeEnum["REGISTRATION_INVITE_ACCEPTED"] = 2041] = "REGISTRATION_INVITE_ACCEPTED";
|
|
11251
11254
|
UserEventTypeTypeEnum[UserEventTypeTypeEnum["CLIENT_EMAIL_CONFIRMED"] = 2050] = "CLIENT_EMAIL_CONFIRMED";
|
|
@@ -12367,6 +12370,7 @@ class EmployeeService extends RestService$1 {
|
|
|
12367
12370
|
this.endpointUri = 'employees';
|
|
12368
12371
|
this.modelClass = User;
|
|
12369
12372
|
this.collectionClass = (Collection);
|
|
12373
|
+
this.disabledMethods = ['postBatch', 'putBatch'];
|
|
12370
12374
|
this.messages = EmployeeMessagesEnum;
|
|
12371
12375
|
this.roles = [UserRolesEnum.FIRM_MANAGER];
|
|
12372
12376
|
}
|
|
@@ -12407,7 +12411,6 @@ class EmployeeInviteService extends RestService$1 {
|
|
|
12407
12411
|
super(...arguments);
|
|
12408
12412
|
this.endpointUri = 'employees/invites';
|
|
12409
12413
|
this.collectionClass = (Collection);
|
|
12410
|
-
this.disabledMethods = ['postBatch', 'putBatch'];
|
|
12411
12414
|
this.modelClass = EmployeeInvite;
|
|
12412
12415
|
this.roles = [UserRolesEnum.FIRM_MANAGER];
|
|
12413
12416
|
}
|
|
@@ -12724,6 +12727,7 @@ class RestService {
|
|
|
12724
12727
|
* clear service cache
|
|
12725
12728
|
*/
|
|
12726
12729
|
refreshCache() {
|
|
12730
|
+
console.log('refreshCacheOld');
|
|
12727
12731
|
this.setCache(undefined);
|
|
12728
12732
|
this.get();
|
|
12729
12733
|
}
|
|
@@ -14759,6 +14763,7 @@ class TransactionAllocationService extends RestService {
|
|
|
14759
14763
|
this.onTransactionsCreated();
|
|
14760
14764
|
this.watchDepreciations();
|
|
14761
14765
|
this.onTransactionDeleted();
|
|
14766
|
+
this.listenNotifications();
|
|
14762
14767
|
}
|
|
14763
14768
|
/**
|
|
14764
14769
|
* Reset cache on transactions created
|
|
@@ -14792,6 +14797,13 @@ class TransactionAllocationService extends RestService {
|
|
|
14792
14797
|
this.refreshCache();
|
|
14793
14798
|
});
|
|
14794
14799
|
}
|
|
14800
|
+
listenNotifications() {
|
|
14801
|
+
this.eventDispatcherService.on(AppEventTypeEnum.NOTIFICATION_ADDED).subscribe((notification) => {
|
|
14802
|
+
if (!notification.isRead && notification.eventType === UserEventTypeTypeEnum.AUTO_ALLOCATION) {
|
|
14803
|
+
this.refreshCache();
|
|
14804
|
+
}
|
|
14805
|
+
});
|
|
14806
|
+
}
|
|
14795
14807
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TransactionAllocationService, deps: [{ token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
14796
14808
|
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TransactionAllocationService, providedIn: 'root' }); }
|
|
14797
14809
|
}
|
|
@@ -14828,6 +14840,7 @@ class TransactionService extends RestService {
|
|
|
14828
14840
|
this.listenPropertyShareUpdate();
|
|
14829
14841
|
this.listenVehicleClaimChanges();
|
|
14830
14842
|
this.listenPropertyForecastUpdate();
|
|
14843
|
+
this.listenNotifications();
|
|
14831
14844
|
}
|
|
14832
14845
|
/**
|
|
14833
14846
|
* get list of all user's TaxTank transactions
|
|
@@ -15052,6 +15065,13 @@ class TransactionService extends RestService {
|
|
|
15052
15065
|
replace(this.cache, transactionToReplace);
|
|
15053
15066
|
this.updateCache();
|
|
15054
15067
|
}
|
|
15068
|
+
listenNotifications() {
|
|
15069
|
+
this.eventDispatcherService.on(AppEventTypeEnum.NOTIFICATION_ADDED).subscribe((notification) => {
|
|
15070
|
+
if (!notification.isRead && notification.eventType === UserEventTypeTypeEnum.AUTO_ALLOCATION) {
|
|
15071
|
+
this.refreshCache();
|
|
15072
|
+
}
|
|
15073
|
+
});
|
|
15074
|
+
}
|
|
15055
15075
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TransactionService, deps: [{ token: i1.HttpClient }, { token: EventDispatcherService }, { token: 'environment' }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
15056
15076
|
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TransactionService, providedIn: 'root' }); }
|
|
15057
15077
|
}
|