@ngrx/data 12.5.1 → 13.0.0-beta.0
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/ngrx-data.umd.js +410 -498
- package/bundles/ngrx-data.umd.js.map +1 -1
- package/esm2015/ngrx-data.js +1 -2
- package/esm2015/src/actions/entity-action-factory.js +7 -5
- package/esm2015/src/dataservices/default-data.service.js +13 -20
- package/esm2015/src/dataservices/entity-cache-data.service.js +12 -20
- package/esm2015/src/dataservices/entity-data.service.js +8 -16
- package/esm2015/src/dataservices/http-url-generator.js +8 -16
- package/esm2015/src/dataservices/persistence-result-handler.service.js +9 -18
- package/esm2015/src/dispatchers/entity-cache-dispatcher.js +16 -22
- package/esm2015/src/dispatchers/entity-dispatcher-default-options.js +7 -5
- package/esm2015/src/dispatchers/entity-dispatcher-factory.js +19 -25
- package/esm2015/src/effects/entity-cache-effects.js +17 -23
- package/esm2015/src/effects/entity-effects.js +17 -23
- package/esm2015/src/entity-data-without-effects.module.js +77 -50
- package/esm2015/src/entity-data.module.js +47 -36
- package/esm2015/src/entity-metadata/entity-definition.service.js +12 -15
- package/esm2015/src/entity-services/entity-collection-service-elements-factory.js +11 -22
- package/esm2015/src/entity-services/entity-collection-service-factory.js +8 -16
- package/esm2015/src/entity-services/entity-services-base.js +8 -16
- package/esm2015/src/entity-services/entity-services-elements.js +11 -22
- package/esm2015/src/reducers/entity-cache-reducer.js +10 -20
- package/esm2015/src/reducers/entity-collection-creator.js +10 -16
- package/esm2015/src/reducers/entity-collection-reducer-methods.js +8 -16
- package/esm2015/src/reducers/entity-collection-reducer-registry.js +13 -17
- package/esm2015/src/reducers/entity-collection-reducer.js +8 -16
- package/esm2015/src/selectors/entity-selectors$.js +12 -19
- package/esm2015/src/selectors/entity-selectors.js +15 -16
- package/esm2015/src/utils/correlation-id-generator.js +7 -5
- package/esm2015/src/utils/default-logger.js +7 -5
- package/esm2015/src/utils/default-pluralizer.js +12 -15
- package/fesm2015/ngrx-data.js +311 -451
- package/fesm2015/ngrx-data.js.map +1 -1
- package/ngrx-data.d.ts +1 -1
- package/package.json +8 -9
- package/schematics-core/utility/libs-version.js +1 -1
- package/schematics-core/utility/libs-version.js.map +1 -1
- package/src/actions/entity-action-factory.d.ts +3 -0
- package/src/dataservices/default-data.service.d.ts +3 -0
- package/src/dataservices/entity-cache-data.service.d.ts +3 -0
- package/src/dataservices/entity-data.service.d.ts +3 -0
- package/src/dataservices/http-url-generator.d.ts +3 -0
- package/src/dataservices/persistence-result-handler.service.d.ts +3 -0
- package/src/dispatchers/entity-cache-dispatcher.d.ts +3 -0
- package/src/dispatchers/entity-dispatcher-default-options.d.ts +3 -0
- package/src/dispatchers/entity-dispatcher-factory.d.ts +3 -0
- package/src/effects/entity-cache-effects.d.ts +3 -0
- package/src/effects/entity-effects.d.ts +3 -0
- package/src/entity-data-without-effects.module.d.ts +5 -0
- package/src/entity-data.module.d.ts +6 -0
- package/src/entity-metadata/entity-definition.service.d.ts +3 -0
- package/src/entity-services/entity-collection-service-base.d.ts +1 -1
- package/src/entity-services/entity-collection-service-elements-factory.d.ts +3 -0
- package/src/entity-services/entity-collection-service-factory.d.ts +3 -0
- package/src/entity-services/entity-services-base.d.ts +3 -0
- package/src/entity-services/entity-services-elements.d.ts +3 -0
- package/src/reducers/entity-cache-reducer.d.ts +3 -0
- package/src/reducers/entity-collection-creator.d.ts +3 -0
- package/src/reducers/entity-collection-reducer-methods.d.ts +3 -0
- package/src/reducers/entity-collection-reducer-registry.d.ts +3 -0
- package/src/reducers/entity-collection-reducer.d.ts +3 -0
- package/src/selectors/entity-selectors$.d.ts +3 -0
- package/src/selectors/entity-selectors.d.ts +3 -0
- package/src/utils/correlation-id-generator.d.ts +3 -0
- package/src/utils/default-logger.d.ts +3 -0
- package/src/utils/default-pluralizer.d.ts +3 -0
- package/ngrx-data.metadata.json +0 -1
package/bundles/ngrx-data.umd.js
CHANGED
|
@@ -2,7 +2,33 @@
|
|
|
2
2
|
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('rxjs/operators'), require('@angular/common/http'), require('rxjs'), require('@ngrx/entity'), require('@ngrx/store'), require('@ngrx/effects')) :
|
|
3
3
|
typeof define === 'function' && define.amd ? define('@ngrx/data', ['exports', '@angular/core', 'rxjs/operators', '@angular/common/http', 'rxjs', '@ngrx/entity', '@ngrx/store', '@ngrx/effects'], factory) :
|
|
4
4
|
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.ngrx = global.ngrx || {}, global.ngrx.data = {}), global.ng.core, global.rxjs.operators, global.ng.common.http, global.rxjs, global.ngrx.entity, global.ngrx.store, global.ngrx.effects));
|
|
5
|
-
}(this, (function (exports,
|
|
5
|
+
}(this, (function (exports, i0, operators, i1, i4, entity, i1$1, i1$2) { 'use strict';
|
|
6
|
+
|
|
7
|
+
function _interopNamespace(e) {
|
|
8
|
+
if (e && e.__esModule) return e;
|
|
9
|
+
var n = Object.create(null);
|
|
10
|
+
if (e) {
|
|
11
|
+
Object.keys(e).forEach(function (k) {
|
|
12
|
+
if (k !== 'default') {
|
|
13
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
14
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: function () {
|
|
17
|
+
return e[k];
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
n['default'] = e;
|
|
24
|
+
return Object.freeze(n);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
|
|
28
|
+
var i1__namespace = /*#__PURE__*/_interopNamespace(i1);
|
|
29
|
+
var i4__namespace = /*#__PURE__*/_interopNamespace(i4);
|
|
30
|
+
var i1__namespace$1 = /*#__PURE__*/_interopNamespace(i1$1);
|
|
31
|
+
var i1__namespace$2 = /*#__PURE__*/_interopNamespace(i1$2);
|
|
6
32
|
|
|
7
33
|
var EntityActionFactory = /** @class */ (function () {
|
|
8
34
|
function EntityActionFactory() {
|
|
@@ -44,10 +70,11 @@
|
|
|
44
70
|
};
|
|
45
71
|
return EntityActionFactory;
|
|
46
72
|
}());
|
|
47
|
-
/** @
|
|
48
|
-
EntityActionFactory
|
|
49
|
-
|
|
50
|
-
|
|
73
|
+
/** @nocollapse */ EntityActionFactory.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityActionFactory, deps: [], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
74
|
+
/** @nocollapse */ EntityActionFactory.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityActionFactory });
|
|
75
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityActionFactory, decorators: [{
|
|
76
|
+
type: i0.Injectable
|
|
77
|
+
}] });
|
|
51
78
|
|
|
52
79
|
/**
|
|
53
80
|
* Guard methods that ensure EntityAction payload is as expected.
|
|
@@ -410,10 +437,16 @@
|
|
|
410
437
|
r[k] = a[j];
|
|
411
438
|
return r;
|
|
412
439
|
}
|
|
413
|
-
function __spreadArray(to, from) {
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
440
|
+
function __spreadArray(to, from, pack) {
|
|
441
|
+
if (pack || arguments.length === 2)
|
|
442
|
+
for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
443
|
+
if (ar || !(i in from)) {
|
|
444
|
+
if (!ar)
|
|
445
|
+
ar = Array.prototype.slice.call(from, 0, i);
|
|
446
|
+
ar[i] = from[i];
|
|
447
|
+
}
|
|
448
|
+
}
|
|
449
|
+
return to.concat(ar || Array.prototype.slice.call(from));
|
|
417
450
|
}
|
|
418
451
|
function __await(v) {
|
|
419
452
|
return this instanceof __await ? (this.v = v, this) : new __await(v);
|
|
@@ -920,7 +953,7 @@
|
|
|
920
953
|
}
|
|
921
954
|
return Logger;
|
|
922
955
|
}());
|
|
923
|
-
var PLURAL_NAMES_TOKEN = new
|
|
956
|
+
var PLURAL_NAMES_TOKEN = new i0.InjectionToken('@ngrx/data Plural Names');
|
|
924
957
|
var Pluralizer = /** @class */ (function () {
|
|
925
958
|
function Pluralizer() {
|
|
926
959
|
}
|
|
@@ -1005,20 +1038,11 @@
|
|
|
1005
1038
|
};
|
|
1006
1039
|
return DefaultHttpUrlGenerator;
|
|
1007
1040
|
}());
|
|
1008
|
-
/** @
|
|
1009
|
-
DefaultHttpUrlGenerator
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
* @type {function(): !Array<(null|{
|
|
1014
|
-
* type: ?,
|
|
1015
|
-
* decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
|
|
1016
|
-
* })>}
|
|
1017
|
-
* @nocollapse
|
|
1018
|
-
*/
|
|
1019
|
-
DefaultHttpUrlGenerator.ctorParameters = function () { return [
|
|
1020
|
-
{ type: Pluralizer }
|
|
1021
|
-
]; };
|
|
1041
|
+
/** @nocollapse */ DefaultHttpUrlGenerator.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultHttpUrlGenerator, deps: [{ token: Pluralizer }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
1042
|
+
/** @nocollapse */ DefaultHttpUrlGenerator.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultHttpUrlGenerator });
|
|
1043
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultHttpUrlGenerator, decorators: [{
|
|
1044
|
+
type: i0.Injectable
|
|
1045
|
+
}], ctorParameters: function () { return [{ type: Pluralizer }]; } });
|
|
1022
1046
|
/** Remove leading & trailing spaces or slashes */
|
|
1023
1047
|
function normalizeRoot(root) {
|
|
1024
1048
|
return root.replace(/^[/\s]+|[/\s]+$/g, '');
|
|
@@ -1080,7 +1104,7 @@
|
|
|
1080
1104
|
var qParams = typeof queryParams === 'string'
|
|
1081
1105
|
? { fromString: queryParams }
|
|
1082
1106
|
: { fromObject: queryParams };
|
|
1083
|
-
var params = new
|
|
1107
|
+
var params = new i1.HttpParams(qParams);
|
|
1084
1108
|
return this.execute('GET', this.entitiesUrl, undefined, { params: params });
|
|
1085
1109
|
};
|
|
1086
1110
|
DefaultDataService.prototype.update = function (update) {
|
|
@@ -1134,7 +1158,7 @@
|
|
|
1134
1158
|
}
|
|
1135
1159
|
default: {
|
|
1136
1160
|
var error = new Error('Unimplemented HTTP method, ' + method);
|
|
1137
|
-
result$ =
|
|
1161
|
+
result$ = i4.throwError(error);
|
|
1138
1162
|
}
|
|
1139
1163
|
}
|
|
1140
1164
|
if (this.timeout) {
|
|
@@ -1150,14 +1174,14 @@
|
|
|
1150
1174
|
return ok;
|
|
1151
1175
|
}
|
|
1152
1176
|
var error = new DataServiceError(err, reqData);
|
|
1153
|
-
return
|
|
1177
|
+
return i4.throwError(error);
|
|
1154
1178
|
};
|
|
1155
1179
|
};
|
|
1156
1180
|
DefaultDataService.prototype.handleDelete404 = function (error, reqData) {
|
|
1157
1181
|
if (error.status === 404 &&
|
|
1158
1182
|
reqData.method === 'DELETE' &&
|
|
1159
1183
|
this.delete404OK) {
|
|
1160
|
-
return
|
|
1184
|
+
return i4.of({});
|
|
1161
1185
|
}
|
|
1162
1186
|
return undefined;
|
|
1163
1187
|
};
|
|
@@ -1185,22 +1209,15 @@
|
|
|
1185
1209
|
};
|
|
1186
1210
|
return DefaultDataServiceFactory;
|
|
1187
1211
|
}());
|
|
1188
|
-
/** @type {
|
|
1189
|
-
DefaultDataServiceFactory
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
* @nocollapse
|
|
1198
|
-
*/
|
|
1199
|
-
DefaultDataServiceFactory.ctorParameters = function () { return [
|
|
1200
|
-
{ type: http.HttpClient },
|
|
1201
|
-
{ type: HttpUrlGenerator },
|
|
1202
|
-
{ type: DefaultDataServiceConfig, decorators: [{ type: core.Optional }] }
|
|
1203
|
-
]; };
|
|
1212
|
+
/** @nocollapse */ DefaultDataServiceFactory.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultDataServiceFactory, deps: [{ token: i1__namespace.HttpClient }, { token: HttpUrlGenerator }, { token: DefaultDataServiceConfig, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
1213
|
+
/** @nocollapse */ DefaultDataServiceFactory.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultDataServiceFactory });
|
|
1214
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultDataServiceFactory, decorators: [{
|
|
1215
|
+
type: i0.Injectable
|
|
1216
|
+
}], ctorParameters: function () {
|
|
1217
|
+
return [{ type: i1__namespace.HttpClient }, { type: HttpUrlGenerator }, { type: DefaultDataServiceConfig, decorators: [{
|
|
1218
|
+
type: i0.Optional
|
|
1219
|
+
}] }];
|
|
1220
|
+
} });
|
|
1204
1221
|
|
|
1205
1222
|
function createEntityDefinition(metadata) {
|
|
1206
1223
|
var entityName = metadata.entityName;
|
|
@@ -1226,7 +1243,7 @@
|
|
|
1226
1243
|
};
|
|
1227
1244
|
}
|
|
1228
1245
|
|
|
1229
|
-
var ENTITY_METADATA_TOKEN = new
|
|
1246
|
+
var ENTITY_METADATA_TOKEN = new i0.InjectionToken('@ngrx/data Entity Metadata');
|
|
1230
1247
|
|
|
1231
1248
|
/** Registry of EntityDefinitions for all cached entity types */
|
|
1232
1249
|
var EntityDefinitionService = /** @class */ (function () {
|
|
@@ -1311,20 +1328,18 @@
|
|
|
1311
1328
|
};
|
|
1312
1329
|
return EntityDefinitionService;
|
|
1313
1330
|
}());
|
|
1314
|
-
/** @
|
|
1315
|
-
EntityDefinitionService
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
{ type: Array, decorators: [{ type: core.Optional }, { type: core.Inject, args: [ENTITY_METADATA_TOKEN,] }] }
|
|
1327
|
-
]; };
|
|
1331
|
+
/** @nocollapse */ EntityDefinitionService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDefinitionService, deps: [{ token: ENTITY_METADATA_TOKEN, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
1332
|
+
/** @nocollapse */ EntityDefinitionService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDefinitionService });
|
|
1333
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDefinitionService, decorators: [{
|
|
1334
|
+
type: i0.Injectable
|
|
1335
|
+
}], ctorParameters: function () {
|
|
1336
|
+
return [{ type: undefined, decorators: [{
|
|
1337
|
+
type: i0.Optional
|
|
1338
|
+
}, {
|
|
1339
|
+
type: i0.Inject,
|
|
1340
|
+
args: [ENTITY_METADATA_TOKEN]
|
|
1341
|
+
}] }];
|
|
1342
|
+
} });
|
|
1328
1343
|
|
|
1329
1344
|
var updateOp = exports.ChangeSetOperation.Update;
|
|
1330
1345
|
/**
|
|
@@ -1374,7 +1389,7 @@
|
|
|
1374
1389
|
EntityCacheDataService.prototype.handleError = function (reqData) {
|
|
1375
1390
|
return function (err) {
|
|
1376
1391
|
var error = new DataServiceError(err, reqData);
|
|
1377
|
-
return
|
|
1392
|
+
return i4.throwError(error);
|
|
1378
1393
|
};
|
|
1379
1394
|
};
|
|
1380
1395
|
/**
|
|
@@ -1452,22 +1467,15 @@
|
|
|
1452
1467
|
};
|
|
1453
1468
|
return EntityCacheDataService;
|
|
1454
1469
|
}());
|
|
1455
|
-
/** @type {
|
|
1456
|
-
EntityCacheDataService
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
* @nocollapse
|
|
1465
|
-
*/
|
|
1466
|
-
EntityCacheDataService.ctorParameters = function () { return [
|
|
1467
|
-
{ type: EntityDefinitionService },
|
|
1468
|
-
{ type: http.HttpClient },
|
|
1469
|
-
{ type: DefaultDataServiceConfig, decorators: [{ type: core.Optional }] }
|
|
1470
|
-
]; };
|
|
1470
|
+
/** @nocollapse */ EntityCacheDataService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheDataService, deps: [{ token: EntityDefinitionService }, { token: i1__namespace.HttpClient }, { token: DefaultDataServiceConfig, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
1471
|
+
/** @nocollapse */ EntityCacheDataService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheDataService });
|
|
1472
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheDataService, decorators: [{
|
|
1473
|
+
type: i0.Injectable
|
|
1474
|
+
}], ctorParameters: function () {
|
|
1475
|
+
return [{ type: EntityDefinitionService }, { type: i1__namespace.HttpClient }, { type: DefaultDataServiceConfig, decorators: [{
|
|
1476
|
+
type: i0.Optional
|
|
1477
|
+
}] }];
|
|
1478
|
+
} });
|
|
1471
1479
|
|
|
1472
1480
|
/**
|
|
1473
1481
|
* Registry of EntityCollection data services that make REST-like CRUD calls
|
|
@@ -1524,20 +1532,11 @@
|
|
|
1524
1532
|
};
|
|
1525
1533
|
return EntityDataService;
|
|
1526
1534
|
}());
|
|
1527
|
-
/** @
|
|
1528
|
-
EntityDataService
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
* @type {function(): !Array<(null|{
|
|
1533
|
-
* type: ?,
|
|
1534
|
-
* decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
|
|
1535
|
-
* })>}
|
|
1536
|
-
* @nocollapse
|
|
1537
|
-
*/
|
|
1538
|
-
EntityDataService.ctorParameters = function () { return [
|
|
1539
|
-
{ type: DefaultDataServiceFactory }
|
|
1540
|
-
]; };
|
|
1535
|
+
/** @nocollapse */ EntityDataService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataService, deps: [{ token: DefaultDataServiceFactory }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
1536
|
+
/** @nocollapse */ EntityDataService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataService });
|
|
1537
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataService, decorators: [{
|
|
1538
|
+
type: i0.Injectable
|
|
1539
|
+
}], ctorParameters: function () { return [{ type: DefaultDataServiceFactory }]; } });
|
|
1541
1540
|
|
|
1542
1541
|
/**
|
|
1543
1542
|
* Handling of responses from persistence operation
|
|
@@ -1582,21 +1581,22 @@
|
|
|
1582
1581
|
};
|
|
1583
1582
|
return DefaultPersistenceResultHandler;
|
|
1584
1583
|
}());
|
|
1585
|
-
/** @
|
|
1586
|
-
DefaultPersistenceResultHandler
|
|
1587
|
-
|
|
1588
|
-
|
|
1584
|
+
/** @nocollapse */ DefaultPersistenceResultHandler.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultPersistenceResultHandler, deps: [{ token: Logger }, { token: EntityActionFactory }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
1585
|
+
/** @nocollapse */ DefaultPersistenceResultHandler.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultPersistenceResultHandler });
|
|
1586
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultPersistenceResultHandler, decorators: [{
|
|
1587
|
+
type: i0.Injectable
|
|
1588
|
+
}], ctorParameters: function () { return [{ type: Logger }, { type: EntityActionFactory }]; } });
|
|
1589
|
+
|
|
1589
1590
|
/**
|
|
1590
|
-
*
|
|
1591
|
-
* type: ?,
|
|
1592
|
-
* decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
|
|
1593
|
-
* })>}
|
|
1594
|
-
* @nocollapse
|
|
1591
|
+
* Persistence operation canceled
|
|
1595
1592
|
*/
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1593
|
+
var PersistanceCanceled = /** @class */ (function () {
|
|
1594
|
+
function PersistanceCanceled(message) {
|
|
1595
|
+
this.message = message;
|
|
1596
|
+
this.message = message || 'Canceled by user';
|
|
1597
|
+
}
|
|
1598
|
+
return PersistanceCanceled;
|
|
1599
|
+
}());
|
|
1600
1600
|
|
|
1601
1601
|
/**
|
|
1602
1602
|
* Generates a string id beginning 'CRID',
|
|
@@ -1621,10 +1621,11 @@
|
|
|
1621
1621
|
};
|
|
1622
1622
|
return CorrelationIdGenerator;
|
|
1623
1623
|
}());
|
|
1624
|
-
/** @
|
|
1625
|
-
CorrelationIdGenerator
|
|
1626
|
-
|
|
1627
|
-
|
|
1624
|
+
/** @nocollapse */ CorrelationIdGenerator.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: CorrelationIdGenerator, deps: [], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
1625
|
+
/** @nocollapse */ CorrelationIdGenerator.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: CorrelationIdGenerator });
|
|
1626
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: CorrelationIdGenerator, decorators: [{
|
|
1627
|
+
type: i0.Injectable
|
|
1628
|
+
}] });
|
|
1628
1629
|
|
|
1629
1630
|
/**
|
|
1630
1631
|
* Default options for EntityDispatcher behavior
|
|
@@ -1649,21 +1650,11 @@
|
|
|
1649
1650
|
}
|
|
1650
1651
|
return EntityDispatcherDefaultOptions;
|
|
1651
1652
|
}());
|
|
1652
|
-
/** @
|
|
1653
|
-
EntityDispatcherDefaultOptions
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
/**
|
|
1658
|
-
* Persistence operation canceled
|
|
1659
|
-
*/
|
|
1660
|
-
var PersistanceCanceled = /** @class */ (function () {
|
|
1661
|
-
function PersistanceCanceled(message) {
|
|
1662
|
-
this.message = message;
|
|
1663
|
-
this.message = message || 'Canceled by user';
|
|
1664
|
-
}
|
|
1665
|
-
return PersistanceCanceled;
|
|
1666
|
-
}());
|
|
1653
|
+
/** @nocollapse */ EntityDispatcherDefaultOptions.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDispatcherDefaultOptions, deps: [], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
1654
|
+
/** @nocollapse */ EntityDispatcherDefaultOptions.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDispatcherDefaultOptions });
|
|
1655
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDispatcherDefaultOptions, decorators: [{
|
|
1656
|
+
type: i0.Injectable
|
|
1657
|
+
}] });
|
|
1667
1658
|
|
|
1668
1659
|
/**
|
|
1669
1660
|
* Dispatches Entity Cache actions to the EntityCache reducer
|
|
@@ -1801,31 +1792,24 @@
|
|
|
1801
1792
|
act.type === exports.EntityCacheAction.SAVE_ENTITIES_ERROR ||
|
|
1802
1793
|
act.type === exports.EntityCacheAction.SAVE_ENTITIES_CANCEL; }), operators.filter(function (act) { return crid === act.payload.correlationId; }), operators.take(1), operators.mergeMap(function (act) {
|
|
1803
1794
|
return act.type === exports.EntityCacheAction.SAVE_ENTITIES_CANCEL
|
|
1804
|
-
?
|
|
1795
|
+
? i4.throwError(new PersistanceCanceled(act.payload.reason))
|
|
1805
1796
|
: act.type === exports.EntityCacheAction.SAVE_ENTITIES_SUCCESS
|
|
1806
|
-
?
|
|
1807
|
-
:
|
|
1797
|
+
? i4.of(act.payload.changeSet)
|
|
1798
|
+
: i4.throwError(act.payload);
|
|
1808
1799
|
}));
|
|
1809
1800
|
};
|
|
1810
1801
|
return EntityCacheDispatcher;
|
|
1811
1802
|
}());
|
|
1812
|
-
/** @type {
|
|
1813
|
-
EntityCacheDispatcher
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
*/
|
|
1823
|
-
EntityCacheDispatcher.ctorParameters = function () { return [
|
|
1824
|
-
{ type: CorrelationIdGenerator },
|
|
1825
|
-
{ type: EntityDispatcherDefaultOptions },
|
|
1826
|
-
{ type: rxjs.Observable, decorators: [{ type: core.Inject, args: [store.ScannedActionsSubject,] }] },
|
|
1827
|
-
{ type: store.Store }
|
|
1828
|
-
]; };
|
|
1803
|
+
/** @nocollapse */ EntityCacheDispatcher.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheDispatcher, deps: [{ token: CorrelationIdGenerator }, { token: EntityDispatcherDefaultOptions }, { token: i1$1.ScannedActionsSubject }, { token: i1__namespace$1.Store }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
1804
|
+
/** @nocollapse */ EntityCacheDispatcher.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheDispatcher });
|
|
1805
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheDispatcher, decorators: [{
|
|
1806
|
+
type: i0.Injectable
|
|
1807
|
+
}], ctorParameters: function () {
|
|
1808
|
+
return [{ type: CorrelationIdGenerator }, { type: EntityDispatcherDefaultOptions }, { type: i4__namespace.Observable, decorators: [{
|
|
1809
|
+
type: i0.Inject,
|
|
1810
|
+
args: [i1$1.ScannedActionsSubject]
|
|
1811
|
+
}] }, { type: i1__namespace$1.Store }];
|
|
1812
|
+
} });
|
|
1829
1813
|
|
|
1830
1814
|
/**
|
|
1831
1815
|
* Dispatches EntityCollection actions to their reducers and effects (default implementation).
|
|
@@ -1838,7 +1822,7 @@
|
|
|
1838
1822
|
/** Creates an {EntityAction} */
|
|
1839
1823
|
entityActionFactory,
|
|
1840
1824
|
/** The store, scoped to the EntityCache */
|
|
1841
|
-
store
|
|
1825
|
+
store,
|
|
1842
1826
|
/** Returns the primary key (id) of this entity */
|
|
1843
1827
|
selectId,
|
|
1844
1828
|
/**
|
|
@@ -1855,15 +1839,15 @@
|
|
|
1855
1839
|
if (selectId === void 0) { selectId = defaultSelectId; }
|
|
1856
1840
|
this.entityName = entityName;
|
|
1857
1841
|
this.entityActionFactory = entityActionFactory;
|
|
1858
|
-
this.store = store
|
|
1842
|
+
this.store = store;
|
|
1859
1843
|
this.selectId = selectId;
|
|
1860
1844
|
this.defaultDispatcherOptions = defaultDispatcherOptions;
|
|
1861
1845
|
this.reducedActions$ = reducedActions$;
|
|
1862
1846
|
this.correlationIdGenerator = correlationIdGenerator;
|
|
1863
1847
|
this.guard = new EntityActionGuard(entityName, selectId);
|
|
1864
1848
|
this.toUpdate = toUpdateFactory(selectId);
|
|
1865
|
-
var collectionSelector =
|
|
1866
|
-
this.entityCollection$ = store
|
|
1849
|
+
var collectionSelector = i1$1.createSelector(entityCacheSelector, function (cache) { return cache[entityName]; });
|
|
1850
|
+
this.entityCollection$ = store.select(collectionSelector);
|
|
1867
1851
|
}
|
|
1868
1852
|
/**
|
|
1869
1853
|
* Create an {EntityAction} for this entity type.
|
|
@@ -2223,10 +2207,10 @@
|
|
|
2223
2207
|
}), operators.take(1), operators.mergeMap(function (act) {
|
|
2224
2208
|
var entityOp = act.payload.entityOp;
|
|
2225
2209
|
return entityOp === exports.EntityOp.CANCEL_PERSIST
|
|
2226
|
-
?
|
|
2210
|
+
? i4.throwError(new PersistanceCanceled(act.payload.data))
|
|
2227
2211
|
: entityOp.endsWith(OP_SUCCESS)
|
|
2228
|
-
?
|
|
2229
|
-
:
|
|
2212
|
+
? i4.of(act.payload.data)
|
|
2213
|
+
: i4.throwError(act.payload.data.error);
|
|
2230
2214
|
}));
|
|
2231
2215
|
};
|
|
2232
2216
|
EntityDispatcherBase.prototype.setQueryEntityActionOptions = function (options) {
|
|
@@ -2250,20 +2234,20 @@
|
|
|
2250
2234
|
}());
|
|
2251
2235
|
|
|
2252
2236
|
var ENTITY_CACHE_NAME = 'entityCache';
|
|
2253
|
-
var ENTITY_CACHE_NAME_TOKEN = new
|
|
2254
|
-
var ENTITY_CACHE_META_REDUCERS = new
|
|
2255
|
-
var ENTITY_COLLECTION_META_REDUCERS = new
|
|
2256
|
-
var INITIAL_ENTITY_CACHE_STATE = new
|
|
2237
|
+
var ENTITY_CACHE_NAME_TOKEN = new i0.InjectionToken('@ngrx/data Entity Cache Name');
|
|
2238
|
+
var ENTITY_CACHE_META_REDUCERS = new i0.InjectionToken('@ngrx/data Entity Cache Meta Reducers');
|
|
2239
|
+
var ENTITY_COLLECTION_META_REDUCERS = new i0.InjectionToken('@ngrx/data Entity Collection Meta Reducers');
|
|
2240
|
+
var INITIAL_ENTITY_CACHE_STATE = new i0.InjectionToken('@ngrx/data Initial Entity Cache State');
|
|
2257
2241
|
|
|
2258
|
-
var ENTITY_CACHE_SELECTOR_TOKEN = new
|
|
2242
|
+
var ENTITY_CACHE_SELECTOR_TOKEN = new i0.InjectionToken('@ngrx/data Entity Cache Selector');
|
|
2259
2243
|
var entityCacheSelectorProvider = {
|
|
2260
2244
|
provide: ENTITY_CACHE_SELECTOR_TOKEN,
|
|
2261
2245
|
useFactory: createEntityCacheSelector,
|
|
2262
|
-
deps: [[new
|
|
2246
|
+
deps: [[new i0.Optional(), ENTITY_CACHE_NAME_TOKEN]],
|
|
2263
2247
|
};
|
|
2264
2248
|
function createEntityCacheSelector(entityCacheName) {
|
|
2265
2249
|
entityCacheName = entityCacheName || ENTITY_CACHE_NAME;
|
|
2266
|
-
return
|
|
2250
|
+
return i1$1.createFeatureSelector(entityCacheName);
|
|
2267
2251
|
}
|
|
2268
2252
|
|
|
2269
2253
|
/** Creates EntityDispatchers for entity collections */
|
|
@@ -2307,29 +2291,23 @@
|
|
|
2307
2291
|
};
|
|
2308
2292
|
return EntityDispatcherFactory;
|
|
2309
2293
|
}());
|
|
2310
|
-
/** @type {
|
|
2311
|
-
EntityDispatcherFactory
|
|
2312
|
-
|
|
2313
|
-
|
|
2314
|
-
|
|
2315
|
-
|
|
2316
|
-
|
|
2317
|
-
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
|
|
2321
|
-
|
|
2322
|
-
|
|
2323
|
-
{ type: store.Store },
|
|
2324
|
-
{ type: EntityDispatcherDefaultOptions },
|
|
2325
|
-
{ type: rxjs.Observable, decorators: [{ type: core.Inject, args: [store.ScannedActionsSubject,] }] },
|
|
2326
|
-
{ type: undefined, decorators: [{ type: core.Inject, args: [ENTITY_CACHE_SELECTOR_TOKEN,] }] },
|
|
2327
|
-
{ type: CorrelationIdGenerator }
|
|
2328
|
-
]; };
|
|
2294
|
+
/** @nocollapse */ EntityDispatcherFactory.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDispatcherFactory, deps: [{ token: EntityActionFactory }, { token: i1__namespace$1.Store }, { token: EntityDispatcherDefaultOptions }, { token: i1$1.ScannedActionsSubject }, { token: ENTITY_CACHE_SELECTOR_TOKEN }, { token: CorrelationIdGenerator }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
2295
|
+
/** @nocollapse */ EntityDispatcherFactory.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDispatcherFactory });
|
|
2296
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDispatcherFactory, decorators: [{
|
|
2297
|
+
type: i0.Injectable
|
|
2298
|
+
}], ctorParameters: function () {
|
|
2299
|
+
return [{ type: EntityActionFactory }, { type: i1__namespace$1.Store }, { type: EntityDispatcherDefaultOptions }, { type: i4__namespace.Observable, decorators: [{
|
|
2300
|
+
type: i0.Inject,
|
|
2301
|
+
args: [i1$1.ScannedActionsSubject]
|
|
2302
|
+
}] }, { type: undefined, decorators: [{
|
|
2303
|
+
type: i0.Inject,
|
|
2304
|
+
args: [ENTITY_CACHE_SELECTOR_TOKEN]
|
|
2305
|
+
}] }, { type: CorrelationIdGenerator }];
|
|
2306
|
+
} });
|
|
2329
2307
|
|
|
2330
2308
|
// See https://github.com/ReactiveX/rxjs/blob/master/doc/marble-testing.md
|
|
2331
2309
|
/** Token to inject a special RxJS Scheduler during marble tests. */
|
|
2332
|
-
var ENTITY_EFFECTS_SCHEDULER = new
|
|
2310
|
+
var ENTITY_EFFECTS_SCHEDULER = new i0.InjectionToken('@ngrx/data Entity Effects Scheduler');
|
|
2333
2311
|
|
|
2334
2312
|
var EntityCacheEffects = /** @class */ (function () {
|
|
2335
2313
|
function EntityCacheEffects(actions, dataService, entityActionFactory, logger,
|
|
@@ -2351,10 +2329,10 @@
|
|
|
2351
2329
|
/**
|
|
2352
2330
|
* Observable of SAVE_ENTITIES_CANCEL actions with non-null correlation ids
|
|
2353
2331
|
*/
|
|
2354
|
-
this.saveEntitiesCancel$ =
|
|
2332
|
+
this.saveEntitiesCancel$ = i1$2.createEffect(function () { return _this.actions.pipe(i1$2.ofType(exports.EntityCacheAction.SAVE_ENTITIES_CANCEL), operators.filter(function (a) { return a.payload.correlationId != null; })); }, { dispatch: false });
|
|
2355
2333
|
// Concurrent persistence requests considered unsafe.
|
|
2356
2334
|
// `mergeMap` allows for concurrent requests which may return in any order
|
|
2357
|
-
this.saveEntities$ =
|
|
2335
|
+
this.saveEntities$ = i1$2.createEffect(function () { return _this.actions.pipe(i1$2.ofType(exports.EntityCacheAction.SAVE_ENTITIES), operators.mergeMap(function (action) { return _this.saveEntities(action); })); });
|
|
2358
2336
|
}
|
|
2359
2337
|
/**
|
|
2360
2338
|
* Perform the requested SaveEntities actions and return a scalar Observable<Action>
|
|
@@ -2373,7 +2351,7 @@
|
|
|
2373
2351
|
var options = { correlationId: correlationId_1, mergeStrategy: mergeStrategy, tag: tag };
|
|
2374
2352
|
if (changeSet.changes.length === 0) {
|
|
2375
2353
|
// nothing to save
|
|
2376
|
-
return
|
|
2354
|
+
return i4.of(new SaveEntitiesSuccess(changeSet, url, options));
|
|
2377
2355
|
}
|
|
2378
2356
|
// Cancellation: returns Observable<SaveEntitiesCanceled> for a saveEntities action
|
|
2379
2357
|
// whose correlationId matches the cancellation correlationId
|
|
@@ -2381,7 +2359,7 @@
|
|
|
2381
2359
|
// Data: SaveEntities result as a SaveEntitiesSuccess action
|
|
2382
2360
|
var d = this.dataService.saveEntities(changeSet, url).pipe(operators.concatMap(function (result) { return _this.handleSaveEntitiesSuccess$(action, _this.entityActionFactory)(result); }), operators.catchError(this.handleSaveEntitiesError$(action)));
|
|
2383
2361
|
// Emit which ever gets there first; the other observable is terminated.
|
|
2384
|
-
return
|
|
2362
|
+
return i4.race(c, d);
|
|
2385
2363
|
}
|
|
2386
2364
|
catch (err) {
|
|
2387
2365
|
return this.handleSaveEntitiesError$(action)(err);
|
|
@@ -2395,7 +2373,7 @@
|
|
|
2395
2373
|
// as app likely assumes asynchronous response.
|
|
2396
2374
|
return function (err) {
|
|
2397
2375
|
var error = err instanceof DataServiceError ? err : new DataServiceError(err, null);
|
|
2398
|
-
return
|
|
2376
|
+
return i4.of(new SaveEntitiesError(error, action)).pipe(operators.delay(_this.responseDelay, _this.scheduler || i4.asyncScheduler));
|
|
2399
2377
|
};
|
|
2400
2378
|
};
|
|
2401
2379
|
/** return handler of the ChangeSet result of successful saveEntities() */
|
|
@@ -2405,7 +2383,7 @@
|
|
|
2405
2383
|
return function (changeSet) {
|
|
2406
2384
|
// DataService returned a ChangeSet with possible updates to the saved entities
|
|
2407
2385
|
if (changeSet) {
|
|
2408
|
-
return
|
|
2386
|
+
return i4.of(new SaveEntitiesSuccess(changeSet, url, options));
|
|
2409
2387
|
}
|
|
2410
2388
|
// No ChangeSet = Server probably responded '204 - No Content' because
|
|
2411
2389
|
// it made no changes to the inserted/updated entities.
|
|
@@ -2413,36 +2391,30 @@
|
|
|
2413
2391
|
changeSet = action.payload.changeSet;
|
|
2414
2392
|
// If pessimistic save, return success action with the original ChangeSet
|
|
2415
2393
|
if (!action.payload.isOptimistic) {
|
|
2416
|
-
return
|
|
2394
|
+
return i4.of(new SaveEntitiesSuccess(changeSet, url, options));
|
|
2417
2395
|
}
|
|
2418
2396
|
// If optimistic save, avoid cache grinding by just turning off the loading flags
|
|
2419
2397
|
// for all collections in the original ChangeSet
|
|
2420
2398
|
var entityNames = changeSet.changes.reduce(function (acc, item) { return acc.indexOf(item.entityName) === -1
|
|
2421
2399
|
? acc.concat(item.entityName)
|
|
2422
2400
|
: acc; }, []);
|
|
2423
|
-
return
|
|
2401
|
+
return i4.merge(entityNames.map(function (name) { return entityActionFactory.create(name, exports.EntityOp.SET_LOADING, false); }));
|
|
2424
2402
|
};
|
|
2425
2403
|
};
|
|
2426
2404
|
return EntityCacheEffects;
|
|
2427
2405
|
}());
|
|
2428
|
-
/** @type {
|
|
2429
|
-
EntityCacheEffects
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
{ type: effects.Actions },
|
|
2441
|
-
{ type: EntityCacheDataService },
|
|
2442
|
-
{ type: EntityActionFactory },
|
|
2443
|
-
{ type: Logger },
|
|
2444
|
-
{ type: undefined, decorators: [{ type: core.Optional }, { type: core.Inject, args: [ENTITY_EFFECTS_SCHEDULER,] }] }
|
|
2445
|
-
]; };
|
|
2406
|
+
/** @nocollapse */ EntityCacheEffects.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheEffects, deps: [{ token: i1__namespace$2.Actions }, { token: EntityCacheDataService }, { token: EntityActionFactory }, { token: Logger }, { token: ENTITY_EFFECTS_SCHEDULER, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
2407
|
+
/** @nocollapse */ EntityCacheEffects.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheEffects });
|
|
2408
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheEffects, decorators: [{
|
|
2409
|
+
type: i0.Injectable
|
|
2410
|
+
}], ctorParameters: function () {
|
|
2411
|
+
return [{ type: i1__namespace$2.Actions }, { type: EntityCacheDataService }, { type: EntityActionFactory }, { type: Logger }, { type: undefined, decorators: [{
|
|
2412
|
+
type: i0.Optional
|
|
2413
|
+
}, {
|
|
2414
|
+
type: i0.Inject,
|
|
2415
|
+
args: [ENTITY_EFFECTS_SCHEDULER]
|
|
2416
|
+
}] }];
|
|
2417
|
+
} });
|
|
2446
2418
|
|
|
2447
2419
|
var persistOps = [
|
|
2448
2420
|
exports.EntityOp.QUERY_ALL,
|
|
@@ -2474,9 +2446,9 @@
|
|
|
2474
2446
|
/**
|
|
2475
2447
|
* Observable of non-null cancellation correlation ids from CANCEL_PERSIST actions
|
|
2476
2448
|
*/
|
|
2477
|
-
this.cancel$ =
|
|
2449
|
+
this.cancel$ = i1$2.createEffect(function () { return _this.actions.pipe(ofEntityOp(exports.EntityOp.CANCEL_PERSIST), operators.map(function (action) { return action.payload.correlationId; }), operators.filter(function (id) { return id != null; })); }, { dispatch: false });
|
|
2478
2450
|
// `mergeMap` allows for concurrent requests which may return in any order
|
|
2479
|
-
this.persist$ =
|
|
2451
|
+
this.persist$ = i1$2.createEffect(function () { return _this.actions.pipe(ofEntityOp(persistOps), operators.mergeMap(function (action) { return _this.persist(action); })); });
|
|
2480
2452
|
}
|
|
2481
2453
|
/**
|
|
2482
2454
|
* Perform the requested persistence operation and return a scalar Observable<Action>
|
|
@@ -2501,7 +2473,7 @@
|
|
|
2501
2473
|
// Data: entity collection DataService result as a successful persistence EntityAction
|
|
2502
2474
|
var d = this.callDataService(action).pipe(operators.map(this.resultHandler.handleSuccess(action)), operators.catchError(this.handleError$(action)));
|
|
2503
2475
|
// Emit which ever gets there first; the other observable is terminated.
|
|
2504
|
-
return
|
|
2476
|
+
return i4.race(c, d);
|
|
2505
2477
|
}
|
|
2506
2478
|
catch (err) {
|
|
2507
2479
|
return this.handleError$(action)(err);
|
|
@@ -2555,7 +2527,7 @@
|
|
|
2555
2527
|
// Although error may return immediately,
|
|
2556
2528
|
// ensure observable takes some time,
|
|
2557
2529
|
// as app likely assumes asynchronous response.
|
|
2558
|
-
return function (error) { return
|
|
2530
|
+
return function (error) { return i4.of(_this.resultHandler.handleError(action)(error)).pipe(operators.delay(_this.responseDelay, _this.scheduler || i4.asyncScheduler)); };
|
|
2559
2531
|
};
|
|
2560
2532
|
/**
|
|
2561
2533
|
* Because EntityAction.payload.skip is true, skip the persistence step and
|
|
@@ -2569,28 +2541,22 @@
|
|
|
2569
2541
|
// Although returns immediately,
|
|
2570
2542
|
// ensure observable takes one tick (by using a promise),
|
|
2571
2543
|
// as app likely assumes asynchronous response.
|
|
2572
|
-
return
|
|
2544
|
+
return i4.of(successAction).pipe(operators.delay(this.responseDelay, this.scheduler || i4.asyncScheduler));
|
|
2573
2545
|
};
|
|
2574
2546
|
return EntityEffects;
|
|
2575
2547
|
}());
|
|
2576
|
-
/** @type {
|
|
2577
|
-
EntityEffects
|
|
2578
|
-
|
|
2579
|
-
|
|
2580
|
-
|
|
2581
|
-
|
|
2582
|
-
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
|
|
2586
|
-
|
|
2587
|
-
|
|
2588
|
-
{ type: effects.Actions },
|
|
2589
|
-
{ type: EntityDataService },
|
|
2590
|
-
{ type: EntityActionFactory },
|
|
2591
|
-
{ type: PersistenceResultHandler },
|
|
2592
|
-
{ type: undefined, decorators: [{ type: core.Optional }, { type: core.Inject, args: [ENTITY_EFFECTS_SCHEDULER,] }] }
|
|
2593
|
-
]; };
|
|
2548
|
+
/** @nocollapse */ EntityEffects.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityEffects, deps: [{ token: i1__namespace$2.Actions }, { token: EntityDataService }, { token: EntityActionFactory }, { token: PersistenceResultHandler }, { token: ENTITY_EFFECTS_SCHEDULER, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
2549
|
+
/** @nocollapse */ EntityEffects.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityEffects });
|
|
2550
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityEffects, decorators: [{
|
|
2551
|
+
type: i0.Injectable
|
|
2552
|
+
}], ctorParameters: function () {
|
|
2553
|
+
return [{ type: i1__namespace$2.Actions }, { type: EntityDataService }, { type: EntityActionFactory }, { type: PersistenceResultHandler }, { type: undefined, decorators: [{
|
|
2554
|
+
type: i0.Optional
|
|
2555
|
+
}, {
|
|
2556
|
+
type: i0.Inject,
|
|
2557
|
+
args: [ENTITY_EFFECTS_SCHEDULER]
|
|
2558
|
+
}] }];
|
|
2559
|
+
} });
|
|
2594
2560
|
|
|
2595
2561
|
/**
|
|
2596
2562
|
* Creates an {EntityFilterFn} that matches RegExp or RegExp string pattern
|
|
@@ -2897,20 +2863,15 @@
|
|
|
2897
2863
|
};
|
|
2898
2864
|
return EntityCollectionCreator;
|
|
2899
2865
|
}());
|
|
2900
|
-
/** @
|
|
2901
|
-
EntityCollectionCreator
|
|
2902
|
-
|
|
2903
|
-
|
|
2904
|
-
|
|
2905
|
-
|
|
2906
|
-
|
|
2907
|
-
|
|
2908
|
-
|
|
2909
|
-
* @nocollapse
|
|
2910
|
-
*/
|
|
2911
|
-
EntityCollectionCreator.ctorParameters = function () { return [
|
|
2912
|
-
{ type: EntityDefinitionService, decorators: [{ type: core.Optional }] }
|
|
2913
|
-
]; };
|
|
2866
|
+
/** @nocollapse */ EntityCollectionCreator.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionCreator, deps: [{ token: EntityDefinitionService, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
2867
|
+
/** @nocollapse */ EntityCollectionCreator.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionCreator });
|
|
2868
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionCreator, decorators: [{
|
|
2869
|
+
type: i0.Injectable
|
|
2870
|
+
}], ctorParameters: function () {
|
|
2871
|
+
return [{ type: EntityDefinitionService, decorators: [{
|
|
2872
|
+
type: i0.Optional
|
|
2873
|
+
}] }];
|
|
2874
|
+
} });
|
|
2914
2875
|
function createEmptyEntityCollection(entityName) {
|
|
2915
2876
|
return {
|
|
2916
2877
|
entityName: entityName,
|
|
@@ -2943,7 +2904,7 @@
|
|
|
2943
2904
|
return ((cache[entityName] ||
|
|
2944
2905
|
_this.entityCollectionCreator.create(entityName)));
|
|
2945
2906
|
};
|
|
2946
|
-
return
|
|
2907
|
+
return i1$1.createSelector(this.selectEntityCache, getCollection);
|
|
2947
2908
|
};
|
|
2948
2909
|
// createCollectionSelectors implementation
|
|
2949
2910
|
EntitySelectorsFactory.prototype.createCollectionSelectors = function (metadataOrName) {
|
|
@@ -2952,13 +2913,13 @@
|
|
|
2952
2913
|
: metadataOrName;
|
|
2953
2914
|
var selectKeys = function (c) { return c.ids; };
|
|
2954
2915
|
var selectEntityMap = function (c) { return c.entities; };
|
|
2955
|
-
var selectEntities =
|
|
2956
|
-
var selectCount =
|
|
2916
|
+
var selectEntities = i1$1.createSelector(selectKeys, selectEntityMap, function (keys, entities) { return keys.map(function (key) { return entities[key]; }); });
|
|
2917
|
+
var selectCount = i1$1.createSelector(selectKeys, function (keys) { return keys.length; });
|
|
2957
2918
|
// EntityCollection selectors that go beyond the ngrx/entity/EntityState selectors
|
|
2958
2919
|
var selectFilter = function (c) { return c.filter; };
|
|
2959
2920
|
var filterFn = metadata.filterFn;
|
|
2960
2921
|
var selectFilteredEntities = filterFn
|
|
2961
|
-
?
|
|
2922
|
+
? i1$1.createSelector(selectEntities, selectFilter, function (entities, pattern) { return filterFn(entities, pattern); })
|
|
2962
2923
|
: selectEntities;
|
|
2963
2924
|
var selectLoaded = function (c) { return c.loaded; };
|
|
2964
2925
|
var selectLoading = function (c) { return c.loading; };
|
|
@@ -2982,27 +2943,26 @@
|
|
|
2982
2943
|
var collectionSelectors = this.createCollectionSelectors(metadata);
|
|
2983
2944
|
var entitySelectors = {};
|
|
2984
2945
|
Object.keys(collectionSelectors).forEach(function (k) {
|
|
2985
|
-
entitySelectors[k] =
|
|
2946
|
+
entitySelectors[k] = i1$1.createSelector(selectCollection, collectionSelectors[k]);
|
|
2986
2947
|
});
|
|
2987
2948
|
return Object.assign({ entityName: entityName, selectCollection: selectCollection, selectEntityCache: this.selectEntityCache }, entitySelectors);
|
|
2988
2949
|
};
|
|
2989
2950
|
return EntitySelectorsFactory;
|
|
2990
2951
|
}());
|
|
2991
|
-
/** @type {
|
|
2992
|
-
EntitySelectorsFactory
|
|
2993
|
-
|
|
2994
|
-
|
|
2995
|
-
|
|
2996
|
-
|
|
2997
|
-
|
|
2998
|
-
|
|
2999
|
-
|
|
3000
|
-
|
|
3001
|
-
|
|
3002
|
-
|
|
3003
|
-
|
|
3004
|
-
|
|
3005
|
-
]; };
|
|
2952
|
+
/** @nocollapse */ EntitySelectorsFactory.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntitySelectorsFactory, deps: [{ token: EntityCollectionCreator, optional: true }, { token: ENTITY_CACHE_SELECTOR_TOKEN, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
2953
|
+
/** @nocollapse */ EntitySelectorsFactory.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntitySelectorsFactory });
|
|
2954
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntitySelectorsFactory, decorators: [{
|
|
2955
|
+
type: i0.Injectable
|
|
2956
|
+
}], ctorParameters: function () {
|
|
2957
|
+
return [{ type: EntityCollectionCreator, decorators: [{
|
|
2958
|
+
type: i0.Optional
|
|
2959
|
+
}] }, { type: undefined, decorators: [{
|
|
2960
|
+
type: i0.Optional
|
|
2961
|
+
}, {
|
|
2962
|
+
type: i0.Inject,
|
|
2963
|
+
args: [ENTITY_CACHE_SELECTOR_TOKEN]
|
|
2964
|
+
}] }];
|
|
2965
|
+
} });
|
|
3006
2966
|
|
|
3007
2967
|
/** Creates observable EntitySelectors$ for entity collections. */
|
|
3008
2968
|
var EntitySelectors$Factory = /** @class */ (function () {
|
|
@@ -3041,22 +3001,16 @@
|
|
|
3041
3001
|
};
|
|
3042
3002
|
return EntitySelectors$Factory;
|
|
3043
3003
|
}());
|
|
3044
|
-
/** @type {
|
|
3045
|
-
EntitySelectors$Factory
|
|
3046
|
-
|
|
3047
|
-
|
|
3048
|
-
|
|
3049
|
-
|
|
3050
|
-
|
|
3051
|
-
|
|
3052
|
-
|
|
3053
|
-
|
|
3054
|
-
*/
|
|
3055
|
-
EntitySelectors$Factory.ctorParameters = function () { return [
|
|
3056
|
-
{ type: store.Store },
|
|
3057
|
-
{ type: effects.Actions },
|
|
3058
|
-
{ type: undefined, decorators: [{ type: core.Inject, args: [ENTITY_CACHE_SELECTOR_TOKEN,] }] }
|
|
3059
|
-
]; };
|
|
3004
|
+
/** @nocollapse */ EntitySelectors$Factory.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntitySelectors$Factory, deps: [{ token: i1__namespace$1.Store }, { token: i1__namespace$2.Actions }, { token: ENTITY_CACHE_SELECTOR_TOKEN }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
3005
|
+
/** @nocollapse */ EntitySelectors$Factory.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntitySelectors$Factory });
|
|
3006
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntitySelectors$Factory, decorators: [{
|
|
3007
|
+
type: i0.Injectable
|
|
3008
|
+
}], ctorParameters: function () {
|
|
3009
|
+
return [{ type: i1__namespace$1.Store }, { type: i1__namespace$2.Actions }, { type: undefined, decorators: [{
|
|
3010
|
+
type: i0.Inject,
|
|
3011
|
+
args: [ENTITY_CACHE_SELECTOR_TOKEN]
|
|
3012
|
+
}] }];
|
|
3013
|
+
} });
|
|
3060
3014
|
|
|
3061
3015
|
/** Creates the core elements of the EntityCollectionService for an entity type. */
|
|
3062
3016
|
var EntityCollectionServiceElementsFactory = /** @class */ (function () {
|
|
@@ -3085,23 +3039,11 @@
|
|
|
3085
3039
|
};
|
|
3086
3040
|
return EntityCollectionServiceElementsFactory;
|
|
3087
3041
|
}());
|
|
3088
|
-
/** @type {
|
|
3089
|
-
EntityCollectionServiceElementsFactory
|
|
3090
|
-
|
|
3091
|
-
|
|
3092
|
-
|
|
3093
|
-
* @type {function(): !Array<(null|{
|
|
3094
|
-
* type: ?,
|
|
3095
|
-
* decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
|
|
3096
|
-
* })>}
|
|
3097
|
-
* @nocollapse
|
|
3098
|
-
*/
|
|
3099
|
-
EntityCollectionServiceElementsFactory.ctorParameters = function () { return [
|
|
3100
|
-
{ type: EntityDispatcherFactory },
|
|
3101
|
-
{ type: EntityDefinitionService },
|
|
3102
|
-
{ type: EntitySelectorsFactory },
|
|
3103
|
-
{ type: EntitySelectors$Factory }
|
|
3104
|
-
]; };
|
|
3042
|
+
/** @nocollapse */ EntityCollectionServiceElementsFactory.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionServiceElementsFactory, deps: [{ token: EntityDispatcherFactory }, { token: EntityDefinitionService }, { token: EntitySelectorsFactory }, { token: EntitySelectors$Factory }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
3043
|
+
/** @nocollapse */ EntityCollectionServiceElementsFactory.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionServiceElementsFactory });
|
|
3044
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionServiceElementsFactory, decorators: [{
|
|
3045
|
+
type: i0.Injectable
|
|
3046
|
+
}], ctorParameters: function () { return [{ type: EntityDispatcherFactory }, { type: EntityDefinitionService }, { type: EntitySelectorsFactory }, { type: EntitySelectors$Factory }]; } });
|
|
3105
3047
|
|
|
3106
3048
|
/**
|
|
3107
3049
|
* Creates EntityCollectionService instances for
|
|
@@ -3122,20 +3064,11 @@
|
|
|
3122
3064
|
};
|
|
3123
3065
|
return EntityCollectionServiceFactory;
|
|
3124
3066
|
}());
|
|
3125
|
-
/** @
|
|
3126
|
-
EntityCollectionServiceFactory
|
|
3127
|
-
|
|
3128
|
-
|
|
3129
|
-
|
|
3130
|
-
* @type {function(): !Array<(null|{
|
|
3131
|
-
* type: ?,
|
|
3132
|
-
* decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
|
|
3133
|
-
* })>}
|
|
3134
|
-
* @nocollapse
|
|
3135
|
-
*/
|
|
3136
|
-
EntityCollectionServiceFactory.ctorParameters = function () { return [
|
|
3137
|
-
{ type: EntityCollectionServiceElementsFactory }
|
|
3138
|
-
]; };
|
|
3067
|
+
/** @nocollapse */ EntityCollectionServiceFactory.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionServiceFactory, deps: [{ token: EntityCollectionServiceElementsFactory }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
3068
|
+
/** @nocollapse */ EntityCollectionServiceFactory.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionServiceFactory });
|
|
3069
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionServiceFactory, decorators: [{
|
|
3070
|
+
type: i0.Injectable
|
|
3071
|
+
}], ctorParameters: function () { return [{ type: EntityCollectionServiceElementsFactory }]; } });
|
|
3139
3072
|
|
|
3140
3073
|
/** Core ingredients of an EntityServices class */
|
|
3141
3074
|
var EntityServicesElements = /** @class */ (function () {
|
|
@@ -3159,23 +3092,11 @@
|
|
|
3159
3092
|
}
|
|
3160
3093
|
return EntityServicesElements;
|
|
3161
3094
|
}());
|
|
3162
|
-
/** @type {
|
|
3163
|
-
EntityServicesElements
|
|
3164
|
-
|
|
3165
|
-
|
|
3166
|
-
|
|
3167
|
-
* @type {function(): !Array<(null|{
|
|
3168
|
-
* type: ?,
|
|
3169
|
-
* decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
|
|
3170
|
-
* })>}
|
|
3171
|
-
* @nocollapse
|
|
3172
|
-
*/
|
|
3173
|
-
EntityServicesElements.ctorParameters = function () { return [
|
|
3174
|
-
{ type: EntityCollectionServiceFactory },
|
|
3175
|
-
{ type: EntityDispatcherFactory },
|
|
3176
|
-
{ type: EntitySelectors$Factory },
|
|
3177
|
-
{ type: store.Store }
|
|
3178
|
-
]; };
|
|
3095
|
+
/** @nocollapse */ EntityServicesElements.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityServicesElements, deps: [{ token: EntityCollectionServiceFactory }, { token: EntityDispatcherFactory }, { token: EntitySelectors$Factory }, { token: i1__namespace$1.Store }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
3096
|
+
/** @nocollapse */ EntityServicesElements.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityServicesElements });
|
|
3097
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityServicesElements, decorators: [{
|
|
3098
|
+
type: i0.Injectable
|
|
3099
|
+
}], ctorParameters: function () { return [{ type: EntityCollectionServiceFactory }, { type: EntityDispatcherFactory }, { type: EntitySelectors$Factory }, { type: i1__namespace$1.Store }]; } });
|
|
3179
3100
|
|
|
3180
3101
|
/* eslint-disable @typescript-eslint/member-ordering */
|
|
3181
3102
|
/**
|
|
@@ -3309,20 +3230,11 @@
|
|
|
3309
3230
|
};
|
|
3310
3231
|
return EntityServicesBase;
|
|
3311
3232
|
}());
|
|
3312
|
-
/** @
|
|
3313
|
-
EntityServicesBase
|
|
3314
|
-
|
|
3315
|
-
|
|
3316
|
-
|
|
3317
|
-
* @type {function(): !Array<(null|{
|
|
3318
|
-
* type: ?,
|
|
3319
|
-
* decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
|
|
3320
|
-
* })>}
|
|
3321
|
-
* @nocollapse
|
|
3322
|
-
*/
|
|
3323
|
-
EntityServicesBase.ctorParameters = function () { return [
|
|
3324
|
-
{ type: EntityServicesElements }
|
|
3325
|
-
]; };
|
|
3233
|
+
/** @nocollapse */ EntityServicesBase.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityServicesBase, deps: [{ token: EntityServicesElements }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
3234
|
+
/** @nocollapse */ EntityServicesBase.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityServicesBase });
|
|
3235
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityServicesBase, decorators: [{
|
|
3236
|
+
type: i0.Injectable
|
|
3237
|
+
}], ctorParameters: function () { return [{ type: EntityServicesElements }]; } });
|
|
3326
3238
|
|
|
3327
3239
|
/* eslint-disable @typescript-eslint/member-ordering */
|
|
3328
3240
|
/**
|
|
@@ -4705,20 +4617,11 @@
|
|
|
4705
4617
|
};
|
|
4706
4618
|
return EntityCollectionReducerMethodsFactory;
|
|
4707
4619
|
}());
|
|
4708
|
-
/** @
|
|
4709
|
-
EntityCollectionReducerMethodsFactory
|
|
4710
|
-
|
|
4711
|
-
|
|
4712
|
-
|
|
4713
|
-
* @type {function(): !Array<(null|{
|
|
4714
|
-
* type: ?,
|
|
4715
|
-
* decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
|
|
4716
|
-
* })>}
|
|
4717
|
-
* @nocollapse
|
|
4718
|
-
*/
|
|
4719
|
-
EntityCollectionReducerMethodsFactory.ctorParameters = function () { return [
|
|
4720
|
-
{ type: EntityDefinitionService }
|
|
4721
|
-
]; };
|
|
4620
|
+
/** @nocollapse */ EntityCollectionReducerMethodsFactory.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionReducerMethodsFactory, deps: [{ token: EntityDefinitionService }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
4621
|
+
/** @nocollapse */ EntityCollectionReducerMethodsFactory.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionReducerMethodsFactory });
|
|
4622
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionReducerMethodsFactory, decorators: [{
|
|
4623
|
+
type: i0.Injectable
|
|
4624
|
+
}], ctorParameters: function () { return [{ type: EntityDefinitionService }]; } });
|
|
4722
4625
|
|
|
4723
4626
|
/** Create a default reducer for a specific entity collection */
|
|
4724
4627
|
var EntityCollectionReducerFactory = /** @class */ (function () {
|
|
@@ -4736,20 +4639,11 @@
|
|
|
4736
4639
|
};
|
|
4737
4640
|
return EntityCollectionReducerFactory;
|
|
4738
4641
|
}());
|
|
4739
|
-
/** @
|
|
4740
|
-
EntityCollectionReducerFactory
|
|
4741
|
-
|
|
4742
|
-
|
|
4743
|
-
|
|
4744
|
-
* @type {function(): !Array<(null|{
|
|
4745
|
-
* type: ?,
|
|
4746
|
-
* decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
|
|
4747
|
-
* })>}
|
|
4748
|
-
* @nocollapse
|
|
4749
|
-
*/
|
|
4750
|
-
EntityCollectionReducerFactory.ctorParameters = function () { return [
|
|
4751
|
-
{ type: EntityCollectionReducerMethodsFactory }
|
|
4752
|
-
]; };
|
|
4642
|
+
/** @nocollapse */ EntityCollectionReducerFactory.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionReducerFactory, deps: [{ token: EntityCollectionReducerMethodsFactory }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
4643
|
+
/** @nocollapse */ EntityCollectionReducerFactory.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionReducerFactory });
|
|
4644
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionReducerFactory, decorators: [{
|
|
4645
|
+
type: i0.Injectable
|
|
4646
|
+
}], ctorParameters: function () { return [{ type: EntityCollectionReducerMethodsFactory }]; } });
|
|
4753
4647
|
|
|
4754
4648
|
/**
|
|
4755
4649
|
* Registry of entity types and their previously-constructed reducers.
|
|
@@ -4760,7 +4654,7 @@
|
|
|
4760
4654
|
this.entityCollectionReducerFactory = entityCollectionReducerFactory;
|
|
4761
4655
|
this.entityCollectionReducers = {};
|
|
4762
4656
|
// eslint-disable-next-line prefer-spread
|
|
4763
|
-
this.entityCollectionMetaReducer =
|
|
4657
|
+
this.entityCollectionMetaReducer = i1$1.compose.apply(null, entityCollectionMetaReducers || []);
|
|
4764
4658
|
}
|
|
4765
4659
|
/**
|
|
4766
4660
|
* Get the registered EntityCollectionReducer<T> for this entity type or create one and register it.
|
|
@@ -4805,21 +4699,18 @@
|
|
|
4805
4699
|
};
|
|
4806
4700
|
return EntityCollectionReducerRegistry;
|
|
4807
4701
|
}());
|
|
4808
|
-
/** @type {
|
|
4809
|
-
EntityCollectionReducerRegistry
|
|
4810
|
-
|
|
4811
|
-
|
|
4812
|
-
|
|
4813
|
-
|
|
4814
|
-
|
|
4815
|
-
|
|
4816
|
-
|
|
4817
|
-
|
|
4818
|
-
|
|
4819
|
-
|
|
4820
|
-
{ type: EntityCollectionReducerFactory },
|
|
4821
|
-
{ type: Array, decorators: [{ type: core.Optional }, { type: core.Inject, args: [ENTITY_COLLECTION_META_REDUCERS,] }] }
|
|
4822
|
-
]; };
|
|
4702
|
+
/** @nocollapse */ EntityCollectionReducerRegistry.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionReducerRegistry, deps: [{ token: EntityCollectionReducerFactory }, { token: ENTITY_COLLECTION_META_REDUCERS, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
4703
|
+
/** @nocollapse */ EntityCollectionReducerRegistry.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionReducerRegistry });
|
|
4704
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCollectionReducerRegistry, decorators: [{
|
|
4705
|
+
type: i0.Injectable
|
|
4706
|
+
}], ctorParameters: function () {
|
|
4707
|
+
return [{ type: EntityCollectionReducerFactory }, { type: undefined, decorators: [{
|
|
4708
|
+
type: i0.Optional
|
|
4709
|
+
}, {
|
|
4710
|
+
type: i0.Inject,
|
|
4711
|
+
args: [ENTITY_COLLECTION_META_REDUCERS]
|
|
4712
|
+
}] }];
|
|
4713
|
+
} });
|
|
4823
4714
|
|
|
4824
4715
|
/**
|
|
4825
4716
|
* Creates the EntityCacheReducer via its create() method
|
|
@@ -5086,22 +4977,11 @@
|
|
|
5086
4977
|
};
|
|
5087
4978
|
return EntityCacheReducerFactory;
|
|
5088
4979
|
}());
|
|
5089
|
-
/** @type {
|
|
5090
|
-
EntityCacheReducerFactory
|
|
5091
|
-
|
|
5092
|
-
|
|
5093
|
-
|
|
5094
|
-
* @type {function(): !Array<(null|{
|
|
5095
|
-
* type: ?,
|
|
5096
|
-
* decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
|
|
5097
|
-
* })>}
|
|
5098
|
-
* @nocollapse
|
|
5099
|
-
*/
|
|
5100
|
-
EntityCacheReducerFactory.ctorParameters = function () { return [
|
|
5101
|
-
{ type: EntityCollectionCreator },
|
|
5102
|
-
{ type: EntityCollectionReducerRegistry },
|
|
5103
|
-
{ type: Logger }
|
|
5104
|
-
]; };
|
|
4980
|
+
/** @nocollapse */ EntityCacheReducerFactory.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheReducerFactory, deps: [{ token: EntityCollectionCreator }, { token: EntityCollectionReducerRegistry }, { token: Logger }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
4981
|
+
/** @nocollapse */ EntityCacheReducerFactory.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheReducerFactory });
|
|
4982
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityCacheReducerFactory, decorators: [{
|
|
4983
|
+
type: i0.Injectable
|
|
4984
|
+
}], ctorParameters: function () { return [{ type: EntityCollectionCreator }, { type: EntityCollectionReducerRegistry }, { type: Logger }]; } });
|
|
5105
4985
|
|
|
5106
4986
|
var DefaultLogger = /** @class */ (function () {
|
|
5107
4987
|
function DefaultLogger() {
|
|
@@ -5123,10 +5003,11 @@
|
|
|
5123
5003
|
};
|
|
5124
5004
|
return DefaultLogger;
|
|
5125
5005
|
}());
|
|
5126
|
-
/** @
|
|
5127
|
-
DefaultLogger
|
|
5128
|
-
|
|
5129
|
-
|
|
5006
|
+
/** @nocollapse */ DefaultLogger.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultLogger, deps: [], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
5007
|
+
/** @nocollapse */ DefaultLogger.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultLogger });
|
|
5008
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultLogger, decorators: [{
|
|
5009
|
+
type: i0.Injectable
|
|
5010
|
+
}] });
|
|
5130
5011
|
|
|
5131
5012
|
var uncountable = [
|
|
5132
5013
|
// 'sheep',
|
|
@@ -5187,20 +5068,18 @@
|
|
|
5187
5068
|
};
|
|
5188
5069
|
return DefaultPluralizer;
|
|
5189
5070
|
}());
|
|
5190
|
-
/** @
|
|
5191
|
-
DefaultPluralizer
|
|
5192
|
-
|
|
5193
|
-
|
|
5194
|
-
|
|
5195
|
-
|
|
5196
|
-
|
|
5197
|
-
|
|
5198
|
-
|
|
5199
|
-
|
|
5200
|
-
|
|
5201
|
-
|
|
5202
|
-
{ type: Array, decorators: [{ type: core.Optional }, { type: core.Inject, args: [PLURAL_NAMES_TOKEN,] }] }
|
|
5203
|
-
]; };
|
|
5071
|
+
/** @nocollapse */ DefaultPluralizer.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultPluralizer, deps: [{ token: PLURAL_NAMES_TOKEN, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
5072
|
+
/** @nocollapse */ DefaultPluralizer.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultPluralizer });
|
|
5073
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: DefaultPluralizer, decorators: [{
|
|
5074
|
+
type: i0.Injectable
|
|
5075
|
+
}], ctorParameters: function () {
|
|
5076
|
+
return [{ type: undefined, decorators: [{
|
|
5077
|
+
type: i0.Optional
|
|
5078
|
+
}, {
|
|
5079
|
+
type: i0.Inject,
|
|
5080
|
+
args: [PLURAL_NAMES_TOKEN]
|
|
5081
|
+
}] }];
|
|
5082
|
+
} });
|
|
5204
5083
|
|
|
5205
5084
|
/**
|
|
5206
5085
|
Client-side id-generators
|
|
@@ -5271,7 +5150,6 @@
|
|
|
5271
5150
|
: +(l !== r);
|
|
5272
5151
|
}
|
|
5273
5152
|
|
|
5274
|
-
var ɵ0 = ENTITY_CACHE_NAME;
|
|
5275
5153
|
/**
|
|
5276
5154
|
* Module without effects or dataservices which means no HTTP calls
|
|
5277
5155
|
* This module helpful for internal testing.
|
|
@@ -5293,12 +5171,12 @@
|
|
|
5293
5171
|
initialState =
|
|
5294
5172
|
typeof initialState === 'function' ? initialState() : initialState;
|
|
5295
5173
|
var reducers = (metaReducers || []).map(function (mr) {
|
|
5296
|
-
return mr instanceof
|
|
5174
|
+
return mr instanceof i0.InjectionToken ? injector.get(mr) : mr;
|
|
5297
5175
|
});
|
|
5298
5176
|
this.entityCacheFeature = {
|
|
5299
5177
|
key: key,
|
|
5300
5178
|
reducers: entityCacheReducerFactory.create(),
|
|
5301
|
-
reducerFactory:
|
|
5179
|
+
reducerFactory: i1$1.combineReducers,
|
|
5302
5180
|
initialState: initialState || {},
|
|
5303
5181
|
metaReducers: reducers,
|
|
5304
5182
|
};
|
|
@@ -5334,51 +5212,79 @@
|
|
|
5334
5212
|
};
|
|
5335
5213
|
return EntityDataModuleWithoutEffects;
|
|
5336
5214
|
}());
|
|
5337
|
-
/** @type {
|
|
5338
|
-
EntityDataModuleWithoutEffects
|
|
5339
|
-
|
|
5340
|
-
|
|
5341
|
-
|
|
5342
|
-
|
|
5343
|
-
|
|
5344
|
-
|
|
5345
|
-
|
|
5346
|
-
|
|
5347
|
-
|
|
5348
|
-
|
|
5349
|
-
|
|
5350
|
-
|
|
5351
|
-
|
|
5352
|
-
|
|
5353
|
-
|
|
5354
|
-
|
|
5355
|
-
|
|
5356
|
-
|
|
5357
|
-
|
|
5358
|
-
|
|
5359
|
-
|
|
5360
|
-
|
|
5361
|
-
|
|
5362
|
-
|
|
5363
|
-
|
|
5364
|
-
|
|
5365
|
-
|
|
5366
|
-
|
|
5367
|
-
|
|
5368
|
-
|
|
5369
|
-
|
|
5370
|
-
|
|
5371
|
-
|
|
5372
|
-
|
|
5373
|
-
|
|
5374
|
-
|
|
5375
|
-
|
|
5376
|
-
|
|
5377
|
-
|
|
5378
|
-
|
|
5379
|
-
|
|
5380
|
-
|
|
5381
|
-
|
|
5215
|
+
/** @nocollapse */ EntityDataModuleWithoutEffects.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataModuleWithoutEffects, deps: [{ token: i1__namespace$1.ReducerManager }, { token: EntityCacheReducerFactory }, { token: i0__namespace.Injector }, { token: ENTITY_CACHE_NAME_TOKEN, optional: true }, { token: INITIAL_ENTITY_CACHE_STATE, optional: true }, { token: ENTITY_CACHE_META_REDUCERS, optional: true }], target: i0__namespace.ɵɵFactoryTarget.NgModule });
|
|
5216
|
+
/** @nocollapse */ EntityDataModuleWithoutEffects.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataModuleWithoutEffects, imports: [i1$1.StoreModule] });
|
|
5217
|
+
/** @nocollapse */ EntityDataModuleWithoutEffects.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataModuleWithoutEffects, providers: [
|
|
5218
|
+
CorrelationIdGenerator,
|
|
5219
|
+
EntityDispatcherDefaultOptions,
|
|
5220
|
+
EntityActionFactory,
|
|
5221
|
+
EntityCacheDispatcher,
|
|
5222
|
+
EntityCacheReducerFactory,
|
|
5223
|
+
entityCacheSelectorProvider,
|
|
5224
|
+
EntityCollectionCreator,
|
|
5225
|
+
EntityCollectionReducerFactory,
|
|
5226
|
+
EntityCollectionReducerMethodsFactory,
|
|
5227
|
+
EntityCollectionReducerRegistry,
|
|
5228
|
+
EntityCollectionServiceElementsFactory,
|
|
5229
|
+
EntityCollectionServiceFactory,
|
|
5230
|
+
EntityDefinitionService,
|
|
5231
|
+
EntityDispatcherFactory,
|
|
5232
|
+
EntitySelectorsFactory,
|
|
5233
|
+
EntitySelectors$Factory,
|
|
5234
|
+
EntityServicesElements,
|
|
5235
|
+
{ provide: ENTITY_CACHE_NAME_TOKEN, useValue: ENTITY_CACHE_NAME },
|
|
5236
|
+
{ provide: EntityServices, useClass: EntityServicesBase },
|
|
5237
|
+
{ provide: Logger, useClass: DefaultLogger },
|
|
5238
|
+
], imports: [[
|
|
5239
|
+
i1$1.StoreModule, // rely on Store feature providers rather than Store.forFeature()
|
|
5240
|
+
]] });
|
|
5241
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataModuleWithoutEffects, decorators: [{
|
|
5242
|
+
type: i0.NgModule,
|
|
5243
|
+
args: [{
|
|
5244
|
+
imports: [
|
|
5245
|
+
i1$1.StoreModule, // rely on Store feature providers rather than Store.forFeature()
|
|
5246
|
+
],
|
|
5247
|
+
providers: [
|
|
5248
|
+
CorrelationIdGenerator,
|
|
5249
|
+
EntityDispatcherDefaultOptions,
|
|
5250
|
+
EntityActionFactory,
|
|
5251
|
+
EntityCacheDispatcher,
|
|
5252
|
+
EntityCacheReducerFactory,
|
|
5253
|
+
entityCacheSelectorProvider,
|
|
5254
|
+
EntityCollectionCreator,
|
|
5255
|
+
EntityCollectionReducerFactory,
|
|
5256
|
+
EntityCollectionReducerMethodsFactory,
|
|
5257
|
+
EntityCollectionReducerRegistry,
|
|
5258
|
+
EntityCollectionServiceElementsFactory,
|
|
5259
|
+
EntityCollectionServiceFactory,
|
|
5260
|
+
EntityDefinitionService,
|
|
5261
|
+
EntityDispatcherFactory,
|
|
5262
|
+
EntitySelectorsFactory,
|
|
5263
|
+
EntitySelectors$Factory,
|
|
5264
|
+
EntityServicesElements,
|
|
5265
|
+
{ provide: ENTITY_CACHE_NAME_TOKEN, useValue: ENTITY_CACHE_NAME },
|
|
5266
|
+
{ provide: EntityServices, useClass: EntityServicesBase },
|
|
5267
|
+
{ provide: Logger, useClass: DefaultLogger },
|
|
5268
|
+
],
|
|
5269
|
+
}]
|
|
5270
|
+
}], ctorParameters: function () {
|
|
5271
|
+
return [{ type: i1__namespace$1.ReducerManager }, { type: EntityCacheReducerFactory }, { type: i0__namespace.Injector }, { type: undefined, decorators: [{
|
|
5272
|
+
type: i0.Optional
|
|
5273
|
+
}, {
|
|
5274
|
+
type: i0.Inject,
|
|
5275
|
+
args: [ENTITY_CACHE_NAME_TOKEN]
|
|
5276
|
+
}] }, { type: undefined, decorators: [{
|
|
5277
|
+
type: i0.Optional
|
|
5278
|
+
}, {
|
|
5279
|
+
type: i0.Inject,
|
|
5280
|
+
args: [INITIAL_ENTITY_CACHE_STATE]
|
|
5281
|
+
}] }, { type: undefined, decorators: [{
|
|
5282
|
+
type: i0.Optional
|
|
5283
|
+
}, {
|
|
5284
|
+
type: i0.Inject,
|
|
5285
|
+
args: [ENTITY_CACHE_META_REDUCERS]
|
|
5286
|
+
}] }];
|
|
5287
|
+
} });
|
|
5382
5288
|
|
|
5383
5289
|
/**
|
|
5384
5290
|
* entity-data main module includes effects and HTTP data services
|
|
@@ -5442,40 +5348,47 @@
|
|
|
5442
5348
|
};
|
|
5443
5349
|
return EntityDataModule;
|
|
5444
5350
|
}());
|
|
5445
|
-
/** @type {
|
|
5446
|
-
EntityDataModule
|
|
5447
|
-
|
|
5448
|
-
|
|
5449
|
-
|
|
5450
|
-
|
|
5451
|
-
|
|
5452
|
-
|
|
5453
|
-
|
|
5454
|
-
|
|
5455
|
-
|
|
5456
|
-
|
|
5457
|
-
|
|
5458
|
-
|
|
5459
|
-
|
|
5460
|
-
|
|
5461
|
-
|
|
5462
|
-
|
|
5463
|
-
|
|
5464
|
-
|
|
5465
|
-
|
|
5466
|
-
|
|
5467
|
-
|
|
5468
|
-
|
|
5469
|
-
|
|
5470
|
-
|
|
5471
|
-
|
|
5472
|
-
|
|
5473
|
-
|
|
5474
|
-
|
|
5475
|
-
|
|
5476
|
-
|
|
5477
|
-
|
|
5478
|
-
|
|
5351
|
+
/** @nocollapse */ EntityDataModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataModule, deps: [{ token: i1__namespace$2.EffectSources }, { token: EntityCacheEffects }, { token: EntityEffects }], target: i0__namespace.ɵɵFactoryTarget.NgModule });
|
|
5352
|
+
/** @nocollapse */ EntityDataModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataModule, imports: [EntityDataModuleWithoutEffects,
|
|
5353
|
+
i1$2.EffectsModule] });
|
|
5354
|
+
/** @nocollapse */ EntityDataModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataModule, providers: [
|
|
5355
|
+
DefaultDataServiceFactory,
|
|
5356
|
+
EntityCacheDataService,
|
|
5357
|
+
EntityDataService,
|
|
5358
|
+
EntityCacheEffects,
|
|
5359
|
+
EntityEffects,
|
|
5360
|
+
{ provide: HttpUrlGenerator, useClass: DefaultHttpUrlGenerator },
|
|
5361
|
+
{
|
|
5362
|
+
provide: PersistenceResultHandler,
|
|
5363
|
+
useClass: DefaultPersistenceResultHandler,
|
|
5364
|
+
},
|
|
5365
|
+
{ provide: Pluralizer, useClass: DefaultPluralizer },
|
|
5366
|
+
], imports: [[
|
|
5367
|
+
EntityDataModuleWithoutEffects,
|
|
5368
|
+
i1$2.EffectsModule, // do not supply effects because can't replace later
|
|
5369
|
+
]] });
|
|
5370
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0__namespace, type: EntityDataModule, decorators: [{
|
|
5371
|
+
type: i0.NgModule,
|
|
5372
|
+
args: [{
|
|
5373
|
+
imports: [
|
|
5374
|
+
EntityDataModuleWithoutEffects,
|
|
5375
|
+
i1$2.EffectsModule, // do not supply effects because can't replace later
|
|
5376
|
+
],
|
|
5377
|
+
providers: [
|
|
5378
|
+
DefaultDataServiceFactory,
|
|
5379
|
+
EntityCacheDataService,
|
|
5380
|
+
EntityDataService,
|
|
5381
|
+
EntityCacheEffects,
|
|
5382
|
+
EntityEffects,
|
|
5383
|
+
{ provide: HttpUrlGenerator, useClass: DefaultHttpUrlGenerator },
|
|
5384
|
+
{
|
|
5385
|
+
provide: PersistenceResultHandler,
|
|
5386
|
+
useClass: DefaultPersistenceResultHandler,
|
|
5387
|
+
},
|
|
5388
|
+
{ provide: Pluralizer, useClass: DefaultPluralizer },
|
|
5389
|
+
],
|
|
5390
|
+
}]
|
|
5391
|
+
}], ctorParameters: function () { return [{ type: i1__namespace$2.EffectSources }, { type: EntityCacheEffects }, { type: EntityEffects }]; } });
|
|
5479
5392
|
|
|
5480
5393
|
// actions
|
|
5481
5394
|
|
|
@@ -5571,7 +5484,6 @@
|
|
|
5571
5484
|
exports.ofEntityType = ofEntityType;
|
|
5572
5485
|
exports.persistOps = persistOps;
|
|
5573
5486
|
exports.toUpdateFactory = toUpdateFactory;
|
|
5574
|
-
exports.ɵa = ENTITY_EFFECTS_SCHEDULER;
|
|
5575
5487
|
|
|
5576
5488
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
5577
5489
|
|