nuxeo-development-framework 4.4.7 → 4.4.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/nuxeo-development-framework.umd.js +13 -11
- package/bundles/nuxeo-development-framework.umd.js.map +1 -1
- package/esm2015/lib/shared/services/base/cache-base.service.js +26 -24
- package/fesm2015/nuxeo-development-framework.js +15 -13
- package/fesm2015/nuxeo-development-framework.js.map +1 -1
- package/lib/shared/services/base/cache-base.service.d.ts +4 -4
- package/package.json +1 -1
|
@@ -3392,10 +3392,10 @@
|
|
|
3392
3392
|
.filter(function (key) {
|
|
3393
3393
|
var _a;
|
|
3394
3394
|
var options = {
|
|
3395
|
-
cacheKey: key.replace(prefix,
|
|
3395
|
+
cacheKey: key.replace(prefix, ""),
|
|
3396
3396
|
userName: userName,
|
|
3397
3397
|
request: DEFAULT_CACHE_OPTIONS.REQUEST,
|
|
3398
|
-
prepareDataBeforeCaching: DEFAULT_CACHE_OPTIONS.PREPARE_DATA
|
|
3398
|
+
prepareDataBeforeCaching: DEFAULT_CACHE_OPTIONS.PREPARE_DATA,
|
|
3399
3399
|
};
|
|
3400
3400
|
var firstFetchingDate = (_a = __classPrivateFieldGet(_this, _CacheBaseService_instances, "m", _CacheBaseService_getItem).call(_this, options)) === null || _a === void 0 ? void 0 : _a.firstFetchingDate;
|
|
3401
3401
|
if (!firstFetchingDate)
|
|
@@ -3461,7 +3461,7 @@
|
|
|
3461
3461
|
data: _fetchedItems.data,
|
|
3462
3462
|
lastModifiedDate: _fetchedItems.lastModifiedDate,
|
|
3463
3463
|
firstFetchingDate: _fetchedItems.firstFetchingDate,
|
|
3464
|
-
resultsCount: _fetchedItems[options.resultsCount]
|
|
3464
|
+
resultsCount: _fetchedItems[options.resultsCount],
|
|
3465
3465
|
}, options);
|
|
3466
3466
|
}
|
|
3467
3467
|
return _fetchedItems;
|
|
@@ -3473,6 +3473,7 @@
|
|
|
3473
3473
|
_j[options.resultsCount] = res[options.resultsCount],
|
|
3474
3474
|
_j));
|
|
3475
3475
|
res.onFinishFetching.next(result);
|
|
3476
|
+
res.onFinishFetching.complete();
|
|
3476
3477
|
return result;
|
|
3477
3478
|
}));
|
|
3478
3479
|
}, _CacheBaseService_findNode = function _CacheBaseService_findNode(items, uniqueCompareKey, childrenPath, value) {
|
|
@@ -3509,7 +3510,8 @@
|
|
|
3509
3510
|
return;
|
|
3510
3511
|
var children = _this.utilityService.getValue(node, childrenPath);
|
|
3511
3512
|
var nodeDate = _this.utilityService.getValue(node, datePath);
|
|
3512
|
-
if (nodeDate &&
|
|
3513
|
+
if (nodeDate &&
|
|
3514
|
+
(!largestDate || new Date(nodeDate) > new Date(largestDate))) {
|
|
3513
3515
|
largestDate = nodeDate;
|
|
3514
3516
|
}
|
|
3515
3517
|
if (children === null || children === void 0 ? void 0 : children.length) {
|
|
@@ -3616,7 +3618,7 @@
|
|
|
3616
3618
|
DEFAULT_TTL_CONFIG.UNIT =
|
|
3617
3619
|
((_d = (_c = EnvManager.environment) === null || _c === void 0 ? void 0 : _c.cache) === null || _d === void 0 ? void 0 : _d.ttlUnit) || DEFAULT_TTL_CONFIG.UNIT;
|
|
3618
3620
|
DEFAULT_TTL_CONFIG.AUTO_CHECK =
|
|
3619
|
-
((_f = (_e = EnvManager.environment) === null || _e === void 0 ? void 0 : _e.cache) === null || _f === void 0 ? void 0 : _f.autoCheck) ==
|
|
3621
|
+
((_f = (_e = EnvManager.environment) === null || _e === void 0 ? void 0 : _e.cache) === null || _f === void 0 ? void 0 : _f.autoCheck) == "YES";
|
|
3620
3622
|
DEFAULT_TTL_CONFIG.RETRY =
|
|
3621
3623
|
((_h = (_g = EnvManager.environment) === null || _g === void 0 ? void 0 : _g.cache) === null || _h === void 0 ? void 0 : _h.retry) || DEFAULT_TTL_CONFIG.RETRY;
|
|
3622
3624
|
}, _CacheBaseService_add1SecondToModifiedDate = function _CacheBaseService_add1SecondToModifiedDate(date) {
|
|
@@ -3624,7 +3626,7 @@
|
|
|
3624
3626
|
newDate.setSeconds(newDate.getSeconds() + 1);
|
|
3625
3627
|
return newDate;
|
|
3626
3628
|
}, _CacheBaseService_clear = function _CacheBaseService_clear(userName, keyOrAll) {
|
|
3627
|
-
if (keyOrAll === void 0) { keyOrAll =
|
|
3629
|
+
if (keyOrAll === void 0) { keyOrAll = ""; }
|
|
3628
3630
|
Object.keys(window.localStorage)
|
|
3629
3631
|
.filter(function (q) { return q.startsWith(userName + "__" + DEFAULT_CACHE_OPTIONS.PREFIX + keyOrAll); })
|
|
3630
3632
|
.forEach(function (key) {
|
|
@@ -3643,11 +3645,11 @@
|
|
|
3643
3645
|
}, _CacheBaseService_setItemInMap = function _CacheBaseService_setItemInMap(key, val) {
|
|
3644
3646
|
var empty = {
|
|
3645
3647
|
data: [],
|
|
3646
|
-
firstFetchingDate:
|
|
3647
|
-
lastModifiedDate:
|
|
3648
|
+
firstFetchingDate: "",
|
|
3649
|
+
lastModifiedDate: "",
|
|
3648
3650
|
resultsCount: 0,
|
|
3649
3651
|
fetchingItemsFromTheServer: false,
|
|
3650
|
-
onFinishFetching: new rxjs.Subject()
|
|
3652
|
+
onFinishFetching: new rxjs.Subject(),
|
|
3651
3653
|
};
|
|
3652
3654
|
var value = val ? val : empty;
|
|
3653
3655
|
__classPrivateFieldGet(this, _CacheBaseService_fetchedItems, "f")[key] = value;
|
|
@@ -3671,11 +3673,11 @@
|
|
|
3671
3673
|
}
|
|
3672
3674
|
};
|
|
3673
3675
|
CacheBaseService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CacheBaseService, deps: [{ token: UserPreferencesService }, { token: UtilityService }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
3674
|
-
CacheBaseService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CacheBaseService, providedIn:
|
|
3676
|
+
CacheBaseService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CacheBaseService, providedIn: "root" });
|
|
3675
3677
|
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CacheBaseService, decorators: [{
|
|
3676
3678
|
type: i0.Injectable,
|
|
3677
3679
|
args: [{
|
|
3678
|
-
providedIn:
|
|
3680
|
+
providedIn: "root",
|
|
3679
3681
|
}]
|
|
3680
3682
|
}], ctorParameters: function () { return [{ type: UserPreferencesService }, { type: UtilityService }]; } });
|
|
3681
3683
|
|