@abp/ng.core 7.0.1 → 7.0.3
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/esm2020/lib/abstracts/auth-response.model.mjs +2 -0
- package/esm2020/lib/abstracts/auth.service.mjs +6 -3
- package/esm2020/lib/abstracts/index.mjs +2 -1
- package/esm2020/lib/abstracts/ng-model.component.mjs +1 -1
- package/esm2020/lib/clients/http.client.mjs +34 -0
- package/esm2020/lib/clients/index.mjs +2 -0
- package/esm2020/lib/components/dynamic-layout.component.mjs +6 -4
- package/esm2020/lib/components/replaceable-route-container.component.mjs +1 -1
- package/esm2020/lib/directives/debounce.directive.mjs +1 -1
- package/esm2020/lib/directives/for.directive.mjs +20 -12
- package/esm2020/lib/directives/form-submit.directive.mjs +2 -2
- package/esm2020/lib/directives/replaceable-template.directive.mjs +9 -5
- package/esm2020/lib/directives/stop-propagation.directive.mjs +2 -2
- package/esm2020/lib/handlers/routes.handler.mjs +9 -7
- package/esm2020/lib/interceptors/api.interceptor.mjs +3 -2
- package/esm2020/lib/models/auth.mjs +1 -1
- package/esm2020/lib/models/dtos.mjs +6 -6
- package/esm2020/lib/models/environment.mjs +1 -1
- package/esm2020/lib/models/session.mjs +1 -1
- package/esm2020/lib/providers/include-localization-resources.provider.mjs +2 -2
- package/esm2020/lib/providers/locale.provider.mjs +6 -2
- package/esm2020/lib/proxy/pages/abp/multi-tenancy/abp-tenant.service.mjs +1 -1
- package/esm2020/lib/proxy/volo/abp/asp-net-core/mvc/api-exploring/abp-api-definition.service.mjs +1 -1
- package/esm2020/lib/proxy/volo/abp/asp-net-core/mvc/application-configurations/abp-application-configuration.service.mjs +1 -1
- package/esm2020/lib/proxy/volo/abp/asp-net-core/mvc/application-configurations/abp-application-localization.service.mjs +2 -2
- package/esm2020/lib/proxy/volo/abp/http/modeling/models.mjs +1 -1
- package/esm2020/lib/proxy/volo/abp/localization/models.mjs +1 -1
- package/esm2020/lib/services/config-state.service.mjs +4 -1
- package/esm2020/lib/services/dom-insertion.service.mjs +6 -4
- package/esm2020/lib/services/environment.service.mjs +5 -5
- package/esm2020/lib/services/http-wait.service.mjs +4 -1
- package/esm2020/lib/services/lazy-load.service.mjs +6 -4
- package/esm2020/lib/services/localization.service.mjs +7 -7
- package/esm2020/lib/services/multi-tenancy.service.mjs +1 -1
- package/esm2020/lib/services/permission.service.mjs +1 -1
- package/esm2020/lib/services/replaceable-components.service.mjs +1 -1
- package/esm2020/lib/services/resource-wait.service.mjs +2 -2
- package/esm2020/lib/services/rest.service.mjs +2 -3
- package/esm2020/lib/services/router-events.service.mjs +2 -2
- package/esm2020/lib/services/routes.service.mjs +2 -2
- package/esm2020/lib/services/session-state.service.mjs +1 -1
- package/esm2020/lib/services/subscription.service.mjs +4 -2
- package/esm2020/lib/strategies/content-security.strategy.mjs +4 -2
- package/esm2020/lib/strategies/content.strategy.mjs +6 -2
- package/esm2020/lib/strategies/context.strategy.mjs +1 -1
- package/esm2020/lib/strategies/cross-origin.strategy.mjs +4 -2
- package/esm2020/lib/strategies/loading.strategy.mjs +1 -1
- package/esm2020/lib/tokens/http-context.token.mjs +3 -0
- package/esm2020/lib/tokens/include-localization-resources.token.mjs +2 -2
- package/esm2020/lib/tokens/index.mjs +2 -1
- package/esm2020/lib/tokens/localization.token.mjs +1 -1
- package/esm2020/lib/tokens/set-token-response-to-storage.token.mjs +4 -1
- package/esm2020/lib/utils/common-utils.mjs +4 -1
- package/esm2020/lib/utils/date-utils.mjs +3 -3
- package/esm2020/lib/utils/environment-utils.mjs +2 -2
- package/esm2020/lib/utils/factory-utils.mjs +2 -2
- package/esm2020/lib/utils/internal-store-utils.mjs +2 -1
- package/esm2020/lib/utils/lazy-load-utils.mjs +2 -2
- package/esm2020/lib/utils/localization-utils.mjs +1 -1
- package/esm2020/lib/utils/multi-tenancy-utils.mjs +7 -4
- package/esm2020/lib/utils/object-utils.mjs +1 -1
- package/esm2020/lib/utils/route-utils.mjs +2 -2
- package/esm2020/lib/utils/tree-utils.mjs +1 -1
- package/esm2020/lib/validators/range.validator.mjs +1 -1
- package/esm2020/lib/validators/required.validator.mjs +1 -1
- package/esm2020/lib/validators/string-length.validator.mjs +1 -1
- package/esm2020/lib/validators/username.validator.mjs +2 -2
- package/esm2020/locale/utils/register-locale.mjs +2 -2
- package/esm2020/public-api.mjs +2 -1
- package/esm2020/testing/lib/services/mock-permission.service.mjs +1 -1
- package/esm2020/testing/lib/services/mock-rest.service.mjs +2 -2
- package/fesm2015/abp-ng.core-locale.mjs +1 -1
- package/fesm2015/abp-ng.core-locale.mjs.map +1 -1
- package/fesm2015/abp-ng.core-testing.mjs.map +1 -1
- package/fesm2015/abp-ng.core.mjs +163 -75
- package/fesm2015/abp-ng.core.mjs.map +1 -1
- package/fesm2020/abp-ng.core-locale.mjs +1 -1
- package/fesm2020/abp-ng.core-locale.mjs.map +1 -1
- package/fesm2020/abp-ng.core-testing.mjs.map +1 -1
- package/fesm2020/abp-ng.core.mjs +153 -71
- package/fesm2020/abp-ng.core.mjs.map +1 -1
- package/lib/abstracts/auth-response.model.d.ts +10 -0
- package/lib/abstracts/auth.service.d.ts +4 -1
- package/lib/abstracts/index.d.ts +1 -0
- package/lib/abstracts/ng-model.component.d.ts +4 -4
- package/lib/clients/http.client.d.ts +11 -0
- package/lib/clients/index.d.ts +1 -0
- package/lib/components/dynamic-layout.component.d.ts +2 -2
- package/lib/components/replaceable-route-container.component.d.ts +1 -1
- package/lib/directives/for.directive.d.ts +6 -6
- package/lib/directives/form-submit.directive.d.ts +1 -1
- package/lib/models/auth.d.ts +4 -1
- package/lib/models/dtos.d.ts +11 -11
- package/lib/models/environment.d.ts +3 -1
- package/lib/models/session.d.ts +1 -1
- package/lib/providers/include-localization-resources.provider.d.ts +1 -1
- package/lib/proxy/volo/abp/http/modeling/models.d.ts +1 -1
- package/lib/proxy/volo/abp/localization/models.d.ts +1 -0
- package/lib/services/config-state.service.d.ts +5 -3
- package/lib/services/dom-insertion.service.d.ts +1 -1
- package/lib/services/environment.service.d.ts +1 -1
- package/lib/services/localization.service.d.ts +5 -2
- package/lib/services/multi-tenancy.service.d.ts +1 -1
- package/lib/services/permission.service.d.ts +2 -2
- package/lib/services/replaceable-components.service.d.ts +2 -2
- package/lib/services/rest.service.d.ts +1 -1
- package/lib/services/router-events.service.d.ts +2 -2
- package/lib/services/routes.service.d.ts +3 -1
- package/lib/services/session-state.service.d.ts +1 -1
- package/lib/services/subscription.service.d.ts +1 -1
- package/lib/strategies/cross-origin.strategy.d.ts +2 -2
- package/lib/tokens/http-context.token.d.ts +2 -0
- package/lib/tokens/include-localization-resources.token.d.ts +1 -1
- package/lib/tokens/index.d.ts +1 -0
- package/lib/tokens/localization.token.d.ts +2 -2
- package/lib/tokens/set-token-response-to-storage.token.d.ts +3 -0
- package/lib/utils/common-utils.d.ts +9 -8
- package/lib/utils/factory-utils.d.ts +3 -1
- package/lib/utils/localization-utils.d.ts +1 -1
- package/lib/utils/object-utils.d.ts +2 -1
- package/lib/utils/route-utils.d.ts +2 -2
- package/lib/utils/tree-utils.d.ts +3 -3
- package/package.json +3 -3
- package/public-api.d.ts +1 -0
package/fesm2015/abp-ng.core.mjs
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { ChangeDetectorRef, Component, Input, Injectable, InjectionToken, Inject, isDevMode, Optional, SkipSelf, Directive, EventEmitter, Output, Self, Injector, Pipe, NgModule, APP_INITIALIZER, LOCALE_ID, NgModuleFactory, Compiler, ComponentFactoryResolver, ApplicationRef } from '@angular/core';
|
|
3
|
-
import { of, BehaviorSubject, Subject, throwError, Subscription, combineLatest, from, fromEvent, ReplaySubject, lastValueFrom, Observable, timer, concat } from 'rxjs';
|
|
3
|
+
import { of, BehaviorSubject, Subject, throwError, Subscription, combineLatest, from, fromEvent, ReplaySubject, lastValueFrom, Observable, timer, pipe, concat } from 'rxjs';
|
|
4
4
|
import * as i1$1 from '@angular/router';
|
|
5
5
|
import { PRIMARY_OUTLET, NavigationCancel, NavigationEnd, NavigationError, NavigationStart, ActivatedRoute, Router, RouterModule } from '@angular/router';
|
|
6
|
-
import { map, distinctUntilChanged, filter, catchError, switchMap, take, tap, debounceTime, mapTo, takeUntil,
|
|
6
|
+
import { map, distinctUntilChanged, filter, catchError, switchMap, take, tap, debounceTime, mapTo, takeUntil, delay, retryWhen, shareReplay, finalize } from 'rxjs/operators';
|
|
7
7
|
import compare from 'just-compare';
|
|
8
|
-
import { __rest, __awaiter } from 'tslib';
|
|
8
|
+
import { __rest, __awaiter, __classPrivateFieldGet } from 'tslib';
|
|
9
9
|
import * as i1 from '@angular/common/http';
|
|
10
|
-
import { HttpParams, HttpClient, HttpClientModule, HttpClientXsrfModule } from '@angular/common/http';
|
|
10
|
+
import { HttpParams, HttpClient, HttpClientModule, HttpClientXsrfModule, HttpContextToken, HttpHeaders, HttpContext } from '@angular/common/http';
|
|
11
11
|
import * as i5 from '@angular/common';
|
|
12
12
|
import { registerLocaleData, DOCUMENT, DatePipe, DATE_PIPE_DEFAULT_TIMEZONE, CommonModule } from '@angular/common';
|
|
13
13
|
import * as i1$2 from '@angular/forms';
|
|
@@ -90,7 +90,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
90
90
|
* Abstract service for Authentication.
|
|
91
91
|
*/
|
|
92
92
|
class AuthService {
|
|
93
|
-
constructor() { }
|
|
94
93
|
warningMessage() {
|
|
95
94
|
console.error('You should add @abp/ng-oauth packages or create your own auth packages.');
|
|
96
95
|
}
|
|
@@ -115,6 +114,10 @@ class AuthService {
|
|
|
115
114
|
this.warningMessage();
|
|
116
115
|
return false;
|
|
117
116
|
}
|
|
117
|
+
loginUsingGrant(grantType, parameters, headers) {
|
|
118
|
+
console.log({ grantType, parameters, headers });
|
|
119
|
+
return Promise.reject(new Error('not implemented'));
|
|
120
|
+
}
|
|
118
121
|
}
|
|
119
122
|
AuthService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AuthService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
120
123
|
AuthService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AuthService, providedIn: 'root' });
|
|
@@ -123,7 +126,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
123
126
|
args: [{
|
|
124
127
|
providedIn: 'root',
|
|
125
128
|
}]
|
|
126
|
-
}]
|
|
129
|
+
}] });
|
|
127
130
|
|
|
128
131
|
function pushValueTo(array) {
|
|
129
132
|
return (element) => {
|
|
@@ -218,6 +221,9 @@ function isNode(obj) {
|
|
|
218
221
|
}
|
|
219
222
|
function isObjectAndNotArrayNotNode(obj) {
|
|
220
223
|
return isObjectAndNotArray(obj) && !isNode(obj);
|
|
224
|
+
}
|
|
225
|
+
function checkHasProp(object, key) {
|
|
226
|
+
return Object.prototype.hasOwnProperty.call(object, key);
|
|
221
227
|
}
|
|
222
228
|
|
|
223
229
|
function deepMerge(target, source) {
|
|
@@ -276,6 +282,7 @@ class InternalStore {
|
|
|
276
282
|
this.update$.next(patchedState);
|
|
277
283
|
}
|
|
278
284
|
deepPatch(state) {
|
|
285
|
+
// TODO: Strict improve deepMerge
|
|
279
286
|
this.state$.next(deepMerge(this.state, state));
|
|
280
287
|
this.update$.next(state);
|
|
281
288
|
}
|
|
@@ -294,7 +301,7 @@ function coreOptionsFactory(_a) {
|
|
|
294
301
|
return Object.assign({}, options);
|
|
295
302
|
}
|
|
296
303
|
|
|
297
|
-
const mapToApiUrl = (key) => (apis) => (apis[key] || apis.default).url || apis.default.url;
|
|
304
|
+
const mapToApiUrl = (key) => (apis) => ((key && apis[key]) || apis.default).url || apis.default.url;
|
|
298
305
|
const mapToIssuer = (issuer) => {
|
|
299
306
|
if (!issuer) {
|
|
300
307
|
return issuer;
|
|
@@ -315,7 +322,8 @@ class EnvironmentService {
|
|
|
315
322
|
return this.store.state;
|
|
316
323
|
}
|
|
317
324
|
getApiUrl(key) {
|
|
318
|
-
|
|
325
|
+
var _a;
|
|
326
|
+
return mapToApiUrl(key)((_a = this.store.state) === null || _a === void 0 ? void 0 : _a.apis);
|
|
319
327
|
}
|
|
320
328
|
getApiUrl$(key) {
|
|
321
329
|
return this.store.sliceState(state => state.apis).pipe(map(mapToApiUrl(key)));
|
|
@@ -324,11 +332,12 @@ class EnvironmentService {
|
|
|
324
332
|
this.store.set(environment);
|
|
325
333
|
}
|
|
326
334
|
getIssuer() {
|
|
327
|
-
|
|
335
|
+
var _a, _b;
|
|
336
|
+
const issuer = (_b = (_a = this.store.state) === null || _a === void 0 ? void 0 : _a.oAuthConfig) === null || _b === void 0 ? void 0 : _b.issuer;
|
|
328
337
|
return mapToIssuer(issuer);
|
|
329
338
|
}
|
|
330
339
|
getIssuer$() {
|
|
331
|
-
return this.store.sliceState(state => state.oAuthConfig.issuer).pipe(map(mapToIssuer));
|
|
340
|
+
return this.store.sliceState(state => { var _a; return (_a = state === null || state === void 0 ? void 0 : state.oAuthConfig) === null || _a === void 0 ? void 0 : _a.issuer; }).pipe(map(mapToIssuer));
|
|
332
341
|
}
|
|
333
342
|
}
|
|
334
343
|
EnvironmentService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: EnvironmentService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
@@ -391,8 +400,7 @@ class RestService {
|
|
|
391
400
|
.pipe(catchError(err => (skipHandleError ? throwError(err) : this.handleError(err))));
|
|
392
401
|
}
|
|
393
402
|
getParams(params, encoder) {
|
|
394
|
-
const filteredParams = Object.
|
|
395
|
-
const value = params[key];
|
|
403
|
+
const filteredParams = Object.entries(params).reduce((acc, [key, value]) => {
|
|
396
404
|
if (isUndefinedOrEmptyString(value))
|
|
397
405
|
return acc;
|
|
398
406
|
if (value === null && !this.options.sendNullsAsQueryParam)
|
|
@@ -483,6 +491,9 @@ class ConfigStateService {
|
|
|
483
491
|
.subscribe(res => this.store.set(res));
|
|
484
492
|
}
|
|
485
493
|
getLocalizationAndCombineWithAppState(appState) {
|
|
494
|
+
if (!appState.localization.currentCulture.cultureName) {
|
|
495
|
+
throw new Error('culture name should defined');
|
|
496
|
+
}
|
|
486
497
|
return this.getlocalizationResource(appState.localization.currentCulture.cultureName).pipe(map(result => (Object.assign(Object.assign({}, appState), { localization: Object.assign(Object.assign({}, appState.localization), result) }))));
|
|
487
498
|
}
|
|
488
499
|
getlocalizationResource(cultureName) {
|
|
@@ -808,7 +819,7 @@ class AbstractNavTreeService extends AbstractTreeService {
|
|
|
808
819
|
hasInvisibleChild(identifier) {
|
|
809
820
|
var _a;
|
|
810
821
|
const node = this.find(item => item[this.id] === identifier);
|
|
811
|
-
return (_a = node === null || node === void 0 ? void 0 : node.children) === null || _a === void 0 ? void 0 : _a.some(child => child.invisible);
|
|
822
|
+
return ((_a = node === null || node === void 0 ? void 0 : node.children) === null || _a === void 0 ? void 0 : _a.some(child => child.invisible)) || false;
|
|
812
823
|
}
|
|
813
824
|
/* istanbul ignore next */
|
|
814
825
|
ngOnDestroy() {
|
|
@@ -846,7 +857,9 @@ class SubscriptionService {
|
|
|
846
857
|
}
|
|
847
858
|
closeOne(subscription) {
|
|
848
859
|
this.removeOne(subscription);
|
|
849
|
-
subscription
|
|
860
|
+
if (subscription) {
|
|
861
|
+
subscription.unsubscribe();
|
|
862
|
+
}
|
|
850
863
|
}
|
|
851
864
|
ngOnDestroy() {
|
|
852
865
|
this.subscription.unsubscribe();
|
|
@@ -1097,13 +1110,13 @@ class LocalizationService {
|
|
|
1097
1110
|
Object.entries(remote).forEach(entry => {
|
|
1098
1111
|
const resourceName = entry[0];
|
|
1099
1112
|
const remoteTexts = entry[1];
|
|
1100
|
-
let resource = local.get(resourceName) || {};
|
|
1113
|
+
let resource = (local === null || local === void 0 ? void 0 : local.get(resourceName)) || {};
|
|
1101
1114
|
resource = Object.assign(Object.assign({}, resource), remoteTexts);
|
|
1102
|
-
local.set(resourceName, resource);
|
|
1115
|
+
local === null || local === void 0 ? void 0 : local.set(resourceName, resource);
|
|
1103
1116
|
});
|
|
1104
1117
|
}
|
|
1105
1118
|
return local;
|
|
1106
|
-
}))
|
|
1119
|
+
}), filter(Boolean))
|
|
1107
1120
|
.subscribe(val => this.localizations$.next(val));
|
|
1108
1121
|
}
|
|
1109
1122
|
addLocalization(localizations) {
|
|
@@ -1124,7 +1137,7 @@ class LocalizationService {
|
|
|
1124
1137
|
listenToSetLanguage() {
|
|
1125
1138
|
this.sessionState
|
|
1126
1139
|
.onLanguageChange$()
|
|
1127
|
-
.pipe(filter(lang => this.configState.getDeep('localization.currentCulture.cultureName') !== lang), switchMap(lang => this.configState.refreshAppState().pipe(map(() => lang))), switchMap(lang => from(this.registerLocale(lang).then(() => lang))))
|
|
1140
|
+
.pipe(filter(lang => this.configState.getDeep('localization.currentCulture.cultureName') !== lang), switchMap(lang => this.configState.refreshAppState().pipe(map(() => lang))), filter(Boolean), switchMap(lang => from(this.registerLocale(lang).then(() => lang))))
|
|
1128
1141
|
.subscribe(lang => this._languageChange$.next(lang));
|
|
1129
1142
|
}
|
|
1130
1143
|
registerLocale(locale) {
|
|
@@ -1176,14 +1189,14 @@ class LocalizationService {
|
|
|
1176
1189
|
getLocalization(state, key, ...interpolateParams) {
|
|
1177
1190
|
if (!key)
|
|
1178
1191
|
key = '';
|
|
1179
|
-
let defaultValue;
|
|
1192
|
+
let defaultValue = '';
|
|
1180
1193
|
if (typeof key !== 'string') {
|
|
1181
1194
|
defaultValue = key.defaultValue;
|
|
1182
1195
|
key = key.key;
|
|
1183
1196
|
}
|
|
1184
1197
|
const keys = key.split('::');
|
|
1185
1198
|
const warn = (message) => {
|
|
1186
|
-
if (isDevMode)
|
|
1199
|
+
if (isDevMode())
|
|
1187
1200
|
console.warn(message);
|
|
1188
1201
|
};
|
|
1189
1202
|
if (keys.length < 2) {
|
|
@@ -1344,7 +1357,7 @@ class DynamicLayoutComponent {
|
|
|
1344
1357
|
]);
|
|
1345
1358
|
this.isLayoutVisible = true;
|
|
1346
1359
|
if (dynamicLayoutComponent) {
|
|
1347
|
-
if (isDevMode)
|
|
1360
|
+
if (isDevMode())
|
|
1348
1361
|
console.warn('DynamicLayoutComponent must be used only in AppComponent.');
|
|
1349
1362
|
return;
|
|
1350
1363
|
}
|
|
@@ -1377,8 +1390,10 @@ class DynamicLayoutComponent {
|
|
|
1377
1390
|
if (this.layoutKey === expectedLayout)
|
|
1378
1391
|
return;
|
|
1379
1392
|
const key = this.layouts.get(expectedLayout);
|
|
1380
|
-
|
|
1381
|
-
|
|
1393
|
+
if (key) {
|
|
1394
|
+
this.layout = (_a = this.getComponent(key)) === null || _a === void 0 ? void 0 : _a.component;
|
|
1395
|
+
this.layoutKey = expectedLayout;
|
|
1396
|
+
}
|
|
1382
1397
|
if (!this.layout) {
|
|
1383
1398
|
this.showLayoutNotFoundError(expectedLayout);
|
|
1384
1399
|
}
|
|
@@ -1886,16 +1901,20 @@ class ForDirective {
|
|
|
1886
1901
|
const rw = [];
|
|
1887
1902
|
changes.forEachOperation((record, previousIndex, currentIndex) => {
|
|
1888
1903
|
if (record.previousIndex == null) {
|
|
1889
|
-
const view = this.vcRef.createEmbeddedView(this.tempRef, new AbpForContext(null, -1, -1, this.items), currentIndex);
|
|
1904
|
+
const view = this.vcRef.createEmbeddedView(this.tempRef, new AbpForContext(null, -1, -1, this.items), currentIndex || 0);
|
|
1890
1905
|
rw.push(new RecordView(record, view));
|
|
1891
1906
|
}
|
|
1892
|
-
else if (currentIndex == null) {
|
|
1907
|
+
else if (currentIndex == null && previousIndex !== null) {
|
|
1893
1908
|
this.vcRef.remove(previousIndex);
|
|
1894
1909
|
}
|
|
1895
1910
|
else {
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1911
|
+
if (previousIndex !== null) {
|
|
1912
|
+
const view = this.vcRef.get(previousIndex);
|
|
1913
|
+
if (view && currentIndex !== null) {
|
|
1914
|
+
this.vcRef.move(view, currentIndex);
|
|
1915
|
+
rw.push(new RecordView(record, view));
|
|
1916
|
+
}
|
|
1917
|
+
}
|
|
1899
1918
|
}
|
|
1900
1919
|
});
|
|
1901
1920
|
for (let i = 0, l = rw.length; i < l; i++) {
|
|
@@ -1910,8 +1929,10 @@ class ForDirective {
|
|
|
1910
1929
|
viewRef.context.list = this.items;
|
|
1911
1930
|
}
|
|
1912
1931
|
changes.forEachIdentityChange((record) => {
|
|
1913
|
-
|
|
1914
|
-
|
|
1932
|
+
if (record.currentIndex !== null) {
|
|
1933
|
+
const viewRef = this.vcRef.get(record.currentIndex);
|
|
1934
|
+
viewRef.context.$implicit = record.item;
|
|
1935
|
+
}
|
|
1915
1936
|
});
|
|
1916
1937
|
}
|
|
1917
1938
|
projectItems(items) {
|
|
@@ -1938,8 +1959,9 @@ class ForDirective {
|
|
|
1938
1959
|
}
|
|
1939
1960
|
}
|
|
1940
1961
|
sortItems(items) {
|
|
1941
|
-
|
|
1942
|
-
|
|
1962
|
+
const orderBy = this.orderBy;
|
|
1963
|
+
if (orderBy) {
|
|
1964
|
+
items.sort((a, b) => (a[orderBy] > b[orderBy] ? 1 : a[orderBy] < b[orderBy] ? -1 : 0));
|
|
1943
1965
|
}
|
|
1944
1966
|
else {
|
|
1945
1967
|
items.sort();
|
|
@@ -1950,10 +1972,11 @@ class ForDirective {
|
|
|
1950
1972
|
if (!Array.isArray(items))
|
|
1951
1973
|
return;
|
|
1952
1974
|
const compareFn = this.compareFn;
|
|
1953
|
-
|
|
1975
|
+
const filterBy = this.filterBy;
|
|
1976
|
+
if (typeof filterBy !== 'undefined' &&
|
|
1954
1977
|
typeof this.filterVal !== 'undefined' &&
|
|
1955
1978
|
this.filterVal !== '') {
|
|
1956
|
-
items = items.filter(item => compareFn(item[
|
|
1979
|
+
items = items.filter(item => compareFn(item[filterBy], this.filterVal));
|
|
1957
1980
|
}
|
|
1958
1981
|
switch (this.orderDir) {
|
|
1959
1982
|
case 'ASC':
|
|
@@ -2024,7 +2047,7 @@ class FormSubmitDirective {
|
|
|
2024
2047
|
}
|
|
2025
2048
|
this.executedNgSubmit = true;
|
|
2026
2049
|
});
|
|
2027
|
-
const keyup$ = fromEvent(this.host.nativeElement, 'keyup').pipe(debounceTime(this.debounce), filter(event => !(event.target instanceof HTMLTextAreaElement)), filter(
|
|
2050
|
+
const keyup$ = fromEvent(this.host.nativeElement, 'keyup').pipe(debounceTime(this.debounce), filter(event => !(event.target instanceof HTMLTextAreaElement)), filter(event => event && event.key === 'Enter'));
|
|
2028
2051
|
this.subscription.addOne(keyup$, () => {
|
|
2029
2052
|
if (!this.executedNgSubmit) {
|
|
2030
2053
|
this.host.nativeElement.dispatchEvent(new Event('submit', { bubbles: true, cancelable: true }));
|
|
@@ -2249,11 +2272,16 @@ class ReplaceableTemplateDirective {
|
|
|
2249
2272
|
if (!this.data.inputs)
|
|
2250
2273
|
return;
|
|
2251
2274
|
Object.defineProperties(this.providedData.inputs, Object.assign({}, Object.keys(this.data.inputs).reduce((acc, key) => {
|
|
2252
|
-
var _a;
|
|
2253
|
-
return (Object.assign(Object.assign({}, acc), { [key]: Object.assign({ enumerable: true, configurable: true, get: () => { var _a; return (_a = this.data.inputs[key]) === null ||
|
|
2275
|
+
var _a, _b;
|
|
2276
|
+
return (Object.assign(Object.assign({}, acc), { [key]: Object.assign({ enumerable: true, configurable: true, get: () => { var _a, _b; return (_b = (_a = this.data.inputs) === null || _a === void 0 ? void 0 : _a[key]) === null || _b === void 0 ? void 0 : _b.value; } }, (((_b = (_a = this.data.inputs) === null || _a === void 0 ? void 0 : _a[key]) === null || _b === void 0 ? void 0 : _b.twoWay) && {
|
|
2254
2277
|
set: (newValue) => {
|
|
2255
|
-
|
|
2256
|
-
this.data.
|
|
2278
|
+
var _a, _b;
|
|
2279
|
+
if ((_a = this.data.inputs) === null || _a === void 0 ? void 0 : _a[key]) {
|
|
2280
|
+
this.data.inputs[key].value = newValue;
|
|
2281
|
+
}
|
|
2282
|
+
if ((_b = this.data.outputs) === null || _b === void 0 ? void 0 : _b[`${key}Change`]) {
|
|
2283
|
+
this.data.outputs[`${key}Change`](newValue);
|
|
2284
|
+
}
|
|
2257
2285
|
},
|
|
2258
2286
|
})) }));
|
|
2259
2287
|
}, {})));
|
|
@@ -2286,7 +2314,7 @@ class StopPropagationDirective {
|
|
|
2286
2314
|
this.stopPropEvent = new EventEmitter();
|
|
2287
2315
|
}
|
|
2288
2316
|
ngOnInit() {
|
|
2289
|
-
this.subscription.addOne(fromEvent(this.el.nativeElement, 'click'),
|
|
2317
|
+
this.subscription.addOne(fromEvent(this.el.nativeElement, 'click'), event => {
|
|
2290
2318
|
event.stopPropagation();
|
|
2291
2319
|
this.stopPropEvent.emit(event);
|
|
2292
2320
|
});
|
|
@@ -2315,14 +2343,16 @@ class RoutesHandler {
|
|
|
2315
2343
|
addRoutes() {
|
|
2316
2344
|
var _a, _b;
|
|
2317
2345
|
(_b = (_a = this.router) === null || _a === void 0 ? void 0 : _a.config) === null || _b === void 0 ? void 0 : _b.forEach(({ path = '', data }) => {
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
if (Array.isArray(data.routes)) {
|
|
2321
|
-
this.routes.add(data.routes);
|
|
2346
|
+
const routes = data === null || data === void 0 ? void 0 : data.routes;
|
|
2347
|
+
if (!routes)
|
|
2322
2348
|
return;
|
|
2349
|
+
if (Array.isArray(routes)) {
|
|
2350
|
+
this.routes.add(routes);
|
|
2351
|
+
}
|
|
2352
|
+
else {
|
|
2353
|
+
const routesFlatten = flatRoutes([Object.assign({ path }, routes)], { path: '' });
|
|
2354
|
+
this.routes.add(routesFlatten);
|
|
2323
2355
|
}
|
|
2324
|
-
const routes = flatRoutes([Object.assign({ path }, data.routes)], { path: '' });
|
|
2325
|
-
this.routes.add(routes);
|
|
2326
2356
|
});
|
|
2327
2357
|
}
|
|
2328
2358
|
}
|
|
@@ -2493,7 +2523,10 @@ class LocaleId extends String {
|
|
|
2493
2523
|
}
|
|
2494
2524
|
toString() {
|
|
2495
2525
|
const { currentLang } = this.localizationService;
|
|
2496
|
-
|
|
2526
|
+
if (checkHasProp(differentLocales, currentLang)) {
|
|
2527
|
+
return differentLocales[currentLang];
|
|
2528
|
+
}
|
|
2529
|
+
return currentLang;
|
|
2497
2530
|
}
|
|
2498
2531
|
valueOf() {
|
|
2499
2532
|
return this.toString();
|
|
@@ -2528,7 +2561,7 @@ function getRemoteEnv(injector, environment) {
|
|
|
2528
2561
|
httpErrorReporter.reportError(err);
|
|
2529
2562
|
return of(null);
|
|
2530
2563
|
}), // TODO: Consider get handle function from a provider
|
|
2531
|
-
tap(env => environmentService.setState(mergeEnvironments(environment, env, remoteEnv))))
|
|
2564
|
+
tap(env => environmentService.setState(mergeEnvironments(environment, env || {}, remoteEnv))))
|
|
2532
2565
|
.toPromise();
|
|
2533
2566
|
}
|
|
2534
2567
|
function mergeEnvironments(local, remote, config) {
|
|
@@ -2665,18 +2698,22 @@ function parseTenantFromUrl(injector) {
|
|
|
2665
2698
|
});
|
|
2666
2699
|
}
|
|
2667
2700
|
function replaceTenantNameWithinEnvironment(injector, tenancyName, placeholder = tenancyPlaceholder) {
|
|
2701
|
+
var _a;
|
|
2668
2702
|
const environmentService = injector.get(EnvironmentService);
|
|
2669
2703
|
const environment = clone(environmentService.getEnvironment());
|
|
2670
2704
|
if (environment.application.baseUrl) {
|
|
2671
2705
|
environment.application.baseUrl = environment.application.baseUrl.replace(placeholder, tenancyName);
|
|
2672
2706
|
}
|
|
2673
|
-
if (environment.oAuthConfig.redirectUri) {
|
|
2707
|
+
if ((_a = environment.oAuthConfig) === null || _a === void 0 ? void 0 : _a.redirectUri) {
|
|
2674
2708
|
environment.oAuthConfig.redirectUri = environment.oAuthConfig.redirectUri.replace(placeholder, tenancyName);
|
|
2675
2709
|
}
|
|
2676
|
-
|
|
2710
|
+
if (!environment.oAuthConfig) {
|
|
2711
|
+
environment.oAuthConfig = {};
|
|
2712
|
+
}
|
|
2713
|
+
environment.oAuthConfig.issuer = (environment.oAuthConfig.issuer || '').replace(placeholder, tenancyName);
|
|
2677
2714
|
Object.keys(environment.apis).forEach(api => {
|
|
2678
2715
|
Object.keys(environment.apis[api]).forEach(key => {
|
|
2679
|
-
environment.apis[api][key] = environment.apis[api][key].replace(placeholder, tenancyName);
|
|
2716
|
+
environment.apis[api][key] = (environment.apis[api][key] || '').replace(placeholder, tenancyName);
|
|
2680
2717
|
});
|
|
2681
2718
|
});
|
|
2682
2719
|
return environmentService.setState(environment);
|
|
@@ -2736,12 +2773,14 @@ function getShortDateFormat(configStateService) {
|
|
|
2736
2773
|
return dateTimeFormat.shortDatePattern;
|
|
2737
2774
|
}
|
|
2738
2775
|
function getShortTimeFormat(configStateService) {
|
|
2776
|
+
var _a;
|
|
2739
2777
|
const dateTimeFormat = configStateService.getDeep('localization.currentCulture.dateTimeFormat');
|
|
2740
|
-
return dateTimeFormat.shortTimePattern.replace('tt', 'a');
|
|
2778
|
+
return (_a = dateTimeFormat === null || dateTimeFormat === void 0 ? void 0 : dateTimeFormat.shortTimePattern) === null || _a === void 0 ? void 0 : _a.replace('tt', 'a');
|
|
2741
2779
|
}
|
|
2742
2780
|
function getShortDateShortTimeFormat(configStateService) {
|
|
2781
|
+
var _a;
|
|
2743
2782
|
const dateTimeFormat = configStateService.getDeep('localization.currentCulture.dateTimeFormat');
|
|
2744
|
-
return `${dateTimeFormat.shortDatePattern} ${dateTimeFormat.shortTimePattern.replace('tt', 'a')}`;
|
|
2783
|
+
return `${dateTimeFormat.shortDatePattern} ${(_a = dateTimeFormat === null || dateTimeFormat === void 0 ? void 0 : dateTimeFormat.shortTimePattern) === null || _a === void 0 ? void 0 : _a.replace('tt', 'a')}`;
|
|
2745
2784
|
}
|
|
2746
2785
|
|
|
2747
2786
|
class ContentProjectionService {
|
|
@@ -2768,10 +2807,7 @@ class LazyModuleFactory extends NgModuleFactory {
|
|
|
2768
2807
|
return this.moduleWithProviders.ngModule;
|
|
2769
2808
|
}
|
|
2770
2809
|
create(parentInjector) {
|
|
2771
|
-
const injector = Injector.create({
|
|
2772
|
-
parent: parentInjector,
|
|
2773
|
-
providers: this.moduleWithProviders.providers,
|
|
2774
|
-
});
|
|
2810
|
+
const injector = Injector.create(Object.assign(Object.assign({}, (parentInjector && { parent: parentInjector })), { providers: this.moduleWithProviders.providers }));
|
|
2775
2811
|
const compiler = injector.get(Compiler);
|
|
2776
2812
|
const factory = compiler.compileModuleSync(this.moduleType);
|
|
2777
2813
|
return factory.create(injector);
|
|
@@ -2871,7 +2907,9 @@ class CrossOriginStrategy {
|
|
|
2871
2907
|
setCrossOrigin(element) {
|
|
2872
2908
|
if (this.integrity)
|
|
2873
2909
|
element.setAttribute('integrity', this.integrity);
|
|
2874
|
-
|
|
2910
|
+
if (this.crossorigin) {
|
|
2911
|
+
element.setAttribute('crossorigin', this.crossorigin);
|
|
2912
|
+
}
|
|
2875
2913
|
}
|
|
2876
2914
|
}
|
|
2877
2915
|
class NoCrossOriginStrategy extends CrossOriginStrategy {
|
|
@@ -2939,8 +2977,9 @@ function fromLazyLoad(element, domStrategy = DOM_STRATEGY.AppendToHead(), crossO
|
|
|
2939
2977
|
}
|
|
2940
2978
|
function createErrorHandler(observer, element) {
|
|
2941
2979
|
return function (event) {
|
|
2980
|
+
var _a;
|
|
2942
2981
|
clearCallbacks(element);
|
|
2943
|
-
element.parentNode.removeChild(element);
|
|
2982
|
+
(_a = element.parentNode) === null || _a === void 0 ? void 0 : _a.removeChild(element);
|
|
2944
2983
|
observer.error(event);
|
|
2945
2984
|
};
|
|
2946
2985
|
}
|
|
@@ -3007,9 +3046,12 @@ class DomInsertionService {
|
|
|
3007
3046
|
return element;
|
|
3008
3047
|
}
|
|
3009
3048
|
removeContent(element) {
|
|
3010
|
-
|
|
3011
|
-
|
|
3012
|
-
|
|
3049
|
+
var _a;
|
|
3050
|
+
if (element.textContent) {
|
|
3051
|
+
const hash = generateHash(element.textContent);
|
|
3052
|
+
this.inserted.delete(hash);
|
|
3053
|
+
(_a = element.parentNode) === null || _a === void 0 ? void 0 : _a.removeChild(element);
|
|
3054
|
+
}
|
|
3013
3055
|
}
|
|
3014
3056
|
has(content) {
|
|
3015
3057
|
const hash = generateHash(content);
|
|
@@ -3073,6 +3115,9 @@ class HttpWaitService {
|
|
|
3073
3115
|
this.store.patch({ filteredRequests });
|
|
3074
3116
|
}
|
|
3075
3117
|
applyFilter(requests) {
|
|
3118
|
+
if (!requests) {
|
|
3119
|
+
return [];
|
|
3120
|
+
}
|
|
3076
3121
|
const { filteredRequests } = this.store.state;
|
|
3077
3122
|
return requests.filter(({ method, url }) => !filteredRequests.find(filteredRequest => this.isSameRequest(filteredRequest, { method, endpoint: getPathName(url) })));
|
|
3078
3123
|
}
|
|
@@ -3101,7 +3146,7 @@ class ResourceWaitService {
|
|
|
3101
3146
|
return this.store.sliceState(({ resources }) => !!resources.size);
|
|
3102
3147
|
}
|
|
3103
3148
|
updateLoading$() {
|
|
3104
|
-
return this.store.sliceUpdate(({ resources }) => !!resources.size);
|
|
3149
|
+
return this.store.sliceUpdate(({ resources }) => !!(resources === null || resources === void 0 ? void 0 : resources.size));
|
|
3105
3150
|
}
|
|
3106
3151
|
clearLoading() {
|
|
3107
3152
|
this.store.patch({ resources: new Set() });
|
|
@@ -3135,16 +3180,19 @@ class LazyLoadService {
|
|
|
3135
3180
|
if (this.loaded.has(strategy.path))
|
|
3136
3181
|
return of(new CustomEvent('load'));
|
|
3137
3182
|
this.resourceWaitService.addResource(strategy.path);
|
|
3138
|
-
|
|
3183
|
+
const delayOperator = retryDelay ? pipe(delay(retryDelay)) : pipe();
|
|
3184
|
+
const takeOp = retryTimes ? pipe(take(retryTimes)) : pipe();
|
|
3185
|
+
return strategy.createStream().pipe(retryWhen(error$ => concat(error$.pipe(delayOperator, takeOp), throwError(() => new CustomEvent('error')))), tap(() => {
|
|
3139
3186
|
this.loaded.set(strategy.path, strategy.element);
|
|
3140
3187
|
this.resourceWaitService.deleteResource(strategy.path);
|
|
3141
3188
|
}), delay(100), shareReplay({ bufferSize: 1, refCount: true }));
|
|
3142
3189
|
}
|
|
3143
3190
|
remove(path) {
|
|
3191
|
+
var _a;
|
|
3144
3192
|
const element = this.loaded.get(path);
|
|
3145
3193
|
if (!element)
|
|
3146
3194
|
return false;
|
|
3147
|
-
element.parentNode.removeChild(element);
|
|
3195
|
+
(_a = element.parentNode) === null || _a === void 0 ? void 0 : _a.removeChild(element);
|
|
3148
3196
|
this.loaded.delete(path);
|
|
3149
3197
|
return true;
|
|
3150
3198
|
}
|
|
@@ -3680,7 +3728,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
3680
3728
|
class ListResultDto {
|
|
3681
3729
|
constructor(initialValues = {}) {
|
|
3682
3730
|
for (const key in initialValues) {
|
|
3683
|
-
if (
|
|
3731
|
+
if (checkHasProp(initialValues, key)) {
|
|
3684
3732
|
this[key] = initialValues[key];
|
|
3685
3733
|
}
|
|
3686
3734
|
}
|
|
@@ -3695,8 +3743,7 @@ class LimitedResultRequestDto {
|
|
|
3695
3743
|
constructor(initialValues = {}) {
|
|
3696
3744
|
this.maxResultCount = 10;
|
|
3697
3745
|
for (const key in initialValues) {
|
|
3698
|
-
if (
|
|
3699
|
-
initialValues[key] !== undefined) {
|
|
3746
|
+
if (checkHasProp(initialValues, key) && initialValues[key] !== undefined) {
|
|
3700
3747
|
this[key] = initialValues[key];
|
|
3701
3748
|
}
|
|
3702
3749
|
}
|
|
@@ -3715,7 +3762,7 @@ class PagedAndSortedResultRequestDto extends PagedResultRequestDto {
|
|
|
3715
3762
|
class EntityDto {
|
|
3716
3763
|
constructor(initialValues = {}) {
|
|
3717
3764
|
for (const key in initialValues) {
|
|
3718
|
-
if (
|
|
3765
|
+
if (checkHasProp(initialValues, key)) {
|
|
3719
3766
|
this[key] = initialValues[key];
|
|
3720
3767
|
}
|
|
3721
3768
|
}
|
|
@@ -3754,7 +3801,7 @@ class FullAuditedEntityWithUserDto extends FullAuditedEntityDto {
|
|
|
3754
3801
|
class ExtensibleObject {
|
|
3755
3802
|
constructor(initialValues = {}) {
|
|
3756
3803
|
for (const key in initialValues) {
|
|
3757
|
-
if (
|
|
3804
|
+
if (checkHasProp(initialValues, key)) {
|
|
3758
3805
|
this[key] = initialValues[key];
|
|
3759
3806
|
}
|
|
3760
3807
|
}
|
|
@@ -3868,7 +3915,9 @@ class LooseContentSecurityStrategy extends ContentSecurityStrategy {
|
|
|
3868
3915
|
super(nonce);
|
|
3869
3916
|
}
|
|
3870
3917
|
applyCSP(element) {
|
|
3871
|
-
|
|
3918
|
+
if (this.nonce) {
|
|
3919
|
+
element.setAttribute('nonce', this.nonce);
|
|
3920
|
+
}
|
|
3872
3921
|
}
|
|
3873
3922
|
}
|
|
3874
3923
|
class NoContentSecurityStrategy extends ContentSecurityStrategy {
|
|
@@ -3896,7 +3945,11 @@ class ContentStrategy {
|
|
|
3896
3945
|
insertElement() {
|
|
3897
3946
|
const element = this.createElement();
|
|
3898
3947
|
if (this.options && Object.keys(this.options).length > 0) {
|
|
3899
|
-
Object.keys(this.options).forEach(key =>
|
|
3948
|
+
Object.keys(this.options).forEach(key => {
|
|
3949
|
+
if (this.options[key]) {
|
|
3950
|
+
element[key] = this.options[key];
|
|
3951
|
+
}
|
|
3952
|
+
});
|
|
3900
3953
|
}
|
|
3901
3954
|
this.contentSecurityStrategy.applyCSP(element);
|
|
3902
3955
|
this.domStrategy.insertElement(element);
|
|
@@ -4102,8 +4155,13 @@ const NAVIGATE_TO_MANAGE_PROFILE = new InjectionToken('NAVIGATE_TO_MANAGE_PROFIL
|
|
|
4102
4155
|
|
|
4103
4156
|
const PIPE_TO_LOGIN_FN_KEY = new InjectionToken('PIPE_TO_LOGIN_FN_KEY');
|
|
4104
4157
|
|
|
4158
|
+
/**
|
|
4159
|
+
* @deprecated The token should not be used anymore.
|
|
4160
|
+
*/
|
|
4105
4161
|
const SET_TOKEN_RESPONSE_TO_STORAGE_FN_KEY = new InjectionToken('SET_TOKEN_RESPONSE_TO_STORAGE_FN_KEY');
|
|
4106
4162
|
|
|
4163
|
+
const IS_EXTERNAL_REQUEST = new HttpContextToken(() => false);
|
|
4164
|
+
|
|
4107
4165
|
function validateMinAge({ age = 18 } = {}) {
|
|
4108
4166
|
return (control) => {
|
|
4109
4167
|
if (['', null, undefined].indexOf(control.value) > -1)
|
|
@@ -4201,7 +4259,7 @@ function isValidUrl(value) {
|
|
|
4201
4259
|
}
|
|
4202
4260
|
|
|
4203
4261
|
const onlyLetterAndNumberRegex = /^[a-zA-Z0-9]+$/;
|
|
4204
|
-
function validateUsername({ pattern } = { pattern: onlyLetterAndNumberRegex }) {
|
|
4262
|
+
function validateUsername({ pattern = /.*/ } = { pattern: onlyLetterAndNumberRegex }) {
|
|
4205
4263
|
return (control) => {
|
|
4206
4264
|
const isValid = isValidUserName(control.value, pattern);
|
|
4207
4265
|
return isValid ? null : { usernamePattern: { actualValue: control.value } };
|
|
@@ -4229,7 +4287,7 @@ class ApiInterceptor {
|
|
|
4229
4287
|
this.httpWaitService = httpWaitService;
|
|
4230
4288
|
}
|
|
4231
4289
|
getAdditionalHeaders(existingHeaders) {
|
|
4232
|
-
return existingHeaders;
|
|
4290
|
+
return existingHeaders || new HttpHeaders();
|
|
4233
4291
|
}
|
|
4234
4292
|
intercept(request, next) {
|
|
4235
4293
|
this.httpWaitService.addRequest(request);
|
|
@@ -4245,11 +4303,41 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
4245
4303
|
}]
|
|
4246
4304
|
}], ctorParameters: function () { return [{ type: HttpWaitService }]; } });
|
|
4247
4305
|
|
|
4306
|
+
var _ExternalHttpClient_instances, _ExternalHttpClient_setPlaceholderContext;
|
|
4307
|
+
// source : https://github.com/armanozak/demo-angular-server-specific-interceptors
|
|
4308
|
+
class ExternalHttpClient extends HttpClient {
|
|
4309
|
+
constructor() {
|
|
4310
|
+
super(...arguments);
|
|
4311
|
+
_ExternalHttpClient_instances.add(this);
|
|
4312
|
+
}
|
|
4313
|
+
request(first, url, options = {}) {
|
|
4314
|
+
if (typeof first === 'string') {
|
|
4315
|
+
__classPrivateFieldGet(this, _ExternalHttpClient_instances, "m", _ExternalHttpClient_setPlaceholderContext).call(this, options);
|
|
4316
|
+
return super.request(first, url || '', options);
|
|
4317
|
+
}
|
|
4318
|
+
__classPrivateFieldGet(this, _ExternalHttpClient_instances, "m", _ExternalHttpClient_setPlaceholderContext).call(this, first);
|
|
4319
|
+
return super.request(first);
|
|
4320
|
+
}
|
|
4321
|
+
}
|
|
4322
|
+
_ExternalHttpClient_instances = new WeakSet(), _ExternalHttpClient_setPlaceholderContext = function _ExternalHttpClient_setPlaceholderContext(optionsOrRequest) {
|
|
4323
|
+
var _a;
|
|
4324
|
+
(_a = optionsOrRequest.context) !== null && _a !== void 0 ? _a : (optionsOrRequest.context = new HttpContext());
|
|
4325
|
+
optionsOrRequest.context.set(IS_EXTERNAL_REQUEST, true);
|
|
4326
|
+
};
|
|
4327
|
+
ExternalHttpClient.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: ExternalHttpClient, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
|
|
4328
|
+
ExternalHttpClient.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: ExternalHttpClient, providedIn: 'root' });
|
|
4329
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: ExternalHttpClient, decorators: [{
|
|
4330
|
+
type: Injectable,
|
|
4331
|
+
args: [{
|
|
4332
|
+
providedIn: 'root',
|
|
4333
|
+
}]
|
|
4334
|
+
}] });
|
|
4335
|
+
|
|
4248
4336
|
// export * from './lib/handlers';
|
|
4249
4337
|
|
|
4250
4338
|
/**
|
|
4251
4339
|
* Generated bundle index. Do not edit.
|
|
4252
4340
|
*/
|
|
4253
4341
|
|
|
4254
|
-
export { APP_INIT_ERROR_HANDLERS, AbpApiDefinitionService, AbpApplicationConfigurationService, AbpApplicationLocalizationService, AbpTenantService, AbpValidators, AbstractNavTreeService, AbstractNgModelComponent, AbstractTreeService, ApiInterceptor, AuditedEntityDto, AuditedEntityWithUserDto, AuthGuard, AuthService, AutofocusDirective, BaseCoreModule, BaseTreeNode, CHECK_AUTHENTICATION_STATE_FN_KEY, CONTAINER_STRATEGY, CONTENT_SECURITY_STRATEGY, CONTENT_STRATEGY, CONTEXT_STRATEGY, COOKIE_LANGUAGE_KEY, CORE_OPTIONS, CROSS_ORIGIN_STRATEGY, ClearContainerStrategy, ComponentContextStrategy, ComponentProjectionStrategy, ConfigStateService, ContainerStrategy, ContentProjectionService, ContentSecurityStrategy, ContentStrategy, ContextStrategy, CoreModule, CreationAuditedEntityDto, CreationAuditedEntityWithUserDto, CrossOriginStrategy, DOM_STRATEGY, DefaultQueueManager, DomInsertionService, DomStrategy, DynamicLayoutComponent, EntityDto, EnvironmentService, ExtensibleAuditedEntityDto, ExtensibleAuditedEntityWithUserDto, ExtensibleCreationAuditedEntityDto, ExtensibleCreationAuditedEntityWithUserDto, ExtensibleEntityDto, ExtensibleFullAuditedEntityDto, ExtensibleFullAuditedEntityWithUserDto, ExtensibleObject, ForDirective, FormSubmitDirective, FullAuditedEntityDto, FullAuditedEntityWithUserDto, HttpErrorReporterService, HttpWaitService, INCUDE_LOCALIZATION_RESOURCES_TOKEN, INJECTOR_PIPE_DATA_TOKEN, InitDirective, InputEventDebounceDirective, InsertIntoContainerStrategy, InternalStore, LIST_QUERY_DEBOUNCE_TIME, LOADER_DELAY, LOADING_STRATEGY, LOCALIZATIONS, LazyLoadService, LazyModuleFactory, LimitedResultRequestDto, ListResultDto, ListService, LoadingStrategy, LocalizationModule, LocalizationPipe, LocalizationService, LooseContentSecurityStrategy, MultiTenancyService, NAVIGATE_TO_MANAGE_PROFILE, NavigationEvent, NoContentSecurityStrategy, NoContextStrategy, NoCrossOriginStrategy, index as ObjectExtending, PIPE_TO_LOGIN_FN_KEY, PROJECTION_STRATEGY, PagedAndSortedResultRequestDto, PagedResultDto, PagedResultRequestDto, PermissionDirective, PermissionGuard, PermissionService, ProjectionStrategy, QUEUE_MANAGER, ReplaceableComponentsService, ReplaceableRouteContainerComponent, ReplaceableTemplateDirective, ResourceWaitService, RestService, RootComponentProjectionStrategy, RootCoreModule, RouterEvents, RouterOutletComponent, RouterWaitService, RoutesService, SET_TOKEN_RESPONSE_TO_STORAGE_FN_KEY, ScriptContentStrategy, ScriptLoadingStrategy, SessionStateService, ShortDatePipe, ShortDateTimePipe, ShortTimePipe, SortPipe, StopPropagationDirective, StyleContentStrategy, StyleLoadingStrategy, SubscriptionService, TENANT_KEY, TemplateContextStrategy, TemplateProjectionStrategy, ToInjectorPipe, TrackByService, WebHttpUrlEncodingCodec, coreOptionsFactory, createLocalizationPipeKeyGenerator, createLocalizer, createLocalizerWithFallback, createMapFromList, createTokenParser, createTreeFromList, createTreeNodeFilterCreator, deepMerge, differentLocales, downloadBlob, escapeHtmlChars, exists, featuresFactory, findRoute, fromLazyLoad, generateHash, generatePassword, getInitialData, getLocaleDirection, getPathName, getRemoteEnv, getRoutePath, getShortDateFormat, getShortDateShortTimeFormat, getShortTimeFormat, interpolate, isArray, isNode, isNullOrEmpty, isNullOrUndefined, isNumber, isObject, isObjectAndNotArray, isObjectAndNotArrayNotNode, isUndefinedOrEmptyString, localeInitializer, localizationContributor, localizations$, mapEnumToOptions, noop, parseTenantFromUrl, pushValueTo, reloadRoute, trackBy, trackByDeep, uuid, validateCreditCard, validateMinAge, validateRange, validateRequired, validateStringLength, validateUrl };
|
|
4342
|
+
export { APP_INIT_ERROR_HANDLERS, AbpApiDefinitionService, AbpApplicationConfigurationService, AbpApplicationLocalizationService, AbpTenantService, AbpValidators, AbstractNavTreeService, AbstractNgModelComponent, AbstractTreeService, ApiInterceptor, AuditedEntityDto, AuditedEntityWithUserDto, AuthGuard, AuthService, AutofocusDirective, BaseCoreModule, BaseTreeNode, CHECK_AUTHENTICATION_STATE_FN_KEY, CONTAINER_STRATEGY, CONTENT_SECURITY_STRATEGY, CONTENT_STRATEGY, CONTEXT_STRATEGY, COOKIE_LANGUAGE_KEY, CORE_OPTIONS, CROSS_ORIGIN_STRATEGY, ClearContainerStrategy, ComponentContextStrategy, ComponentProjectionStrategy, ConfigStateService, ContainerStrategy, ContentProjectionService, ContentSecurityStrategy, ContentStrategy, ContextStrategy, CoreModule, CreationAuditedEntityDto, CreationAuditedEntityWithUserDto, CrossOriginStrategy, DOM_STRATEGY, DefaultQueueManager, DomInsertionService, DomStrategy, DynamicLayoutComponent, EntityDto, EnvironmentService, ExtensibleAuditedEntityDto, ExtensibleAuditedEntityWithUserDto, ExtensibleCreationAuditedEntityDto, ExtensibleCreationAuditedEntityWithUserDto, ExtensibleEntityDto, ExtensibleFullAuditedEntityDto, ExtensibleFullAuditedEntityWithUserDto, ExtensibleObject, ExternalHttpClient, ForDirective, FormSubmitDirective, FullAuditedEntityDto, FullAuditedEntityWithUserDto, HttpErrorReporterService, HttpWaitService, INCUDE_LOCALIZATION_RESOURCES_TOKEN, INJECTOR_PIPE_DATA_TOKEN, IS_EXTERNAL_REQUEST, InitDirective, InputEventDebounceDirective, InsertIntoContainerStrategy, InternalStore, LIST_QUERY_DEBOUNCE_TIME, LOADER_DELAY, LOADING_STRATEGY, LOCALIZATIONS, LazyLoadService, LazyModuleFactory, LimitedResultRequestDto, ListResultDto, ListService, LoadingStrategy, LocalizationModule, LocalizationPipe, LocalizationService, LooseContentSecurityStrategy, MultiTenancyService, NAVIGATE_TO_MANAGE_PROFILE, NavigationEvent, NoContentSecurityStrategy, NoContextStrategy, NoCrossOriginStrategy, index as ObjectExtending, PIPE_TO_LOGIN_FN_KEY, PROJECTION_STRATEGY, PagedAndSortedResultRequestDto, PagedResultDto, PagedResultRequestDto, PermissionDirective, PermissionGuard, PermissionService, ProjectionStrategy, QUEUE_MANAGER, ReplaceableComponentsService, ReplaceableRouteContainerComponent, ReplaceableTemplateDirective, ResourceWaitService, RestService, RootComponentProjectionStrategy, RootCoreModule, RouterEvents, RouterOutletComponent, RouterWaitService, RoutesService, SET_TOKEN_RESPONSE_TO_STORAGE_FN_KEY, ScriptContentStrategy, ScriptLoadingStrategy, SessionStateService, ShortDatePipe, ShortDateTimePipe, ShortTimePipe, SortPipe, StopPropagationDirective, StyleContentStrategy, StyleLoadingStrategy, SubscriptionService, TENANT_KEY, TemplateContextStrategy, TemplateProjectionStrategy, ToInjectorPipe, TrackByService, WebHttpUrlEncodingCodec, checkHasProp, coreOptionsFactory, createLocalizationPipeKeyGenerator, createLocalizer, createLocalizerWithFallback, createMapFromList, createTokenParser, createTreeFromList, createTreeNodeFilterCreator, deepMerge, differentLocales, downloadBlob, escapeHtmlChars, exists, featuresFactory, findRoute, fromLazyLoad, generateHash, generatePassword, getInitialData, getLocaleDirection, getPathName, getRemoteEnv, getRoutePath, getShortDateFormat, getShortDateShortTimeFormat, getShortTimeFormat, interpolate, isArray, isNode, isNullOrEmpty, isNullOrUndefined, isNumber, isObject, isObjectAndNotArray, isObjectAndNotArrayNotNode, isUndefinedOrEmptyString, localeInitializer, localizationContributor, localizations$, mapEnumToOptions, noop, parseTenantFromUrl, pushValueTo, reloadRoute, trackBy, trackByDeep, uuid, validateCreditCard, validateMinAge, validateRange, validateRequired, validateStringLength, validateUrl };
|
|
4255
4343
|
//# sourceMappingURL=abp-ng.core.mjs.map
|