@sumaris-net/ngx-components 2.4.23-rc2 → 2.4.23-rc3
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/src/app/core/form/entity/entity-editor.class.mjs +16 -7
- package/fesm2015/sumaris-net.ngx-components.mjs +25 -14
- package/fesm2015/sumaris-net.ngx-components.mjs.map +1 -1
- package/fesm2020/sumaris-net.ngx-components.mjs +15 -6
- package/fesm2020/sumaris-net.ngx-components.mjs.map +1 -1
- package/package.json +1 -1
- package/src/app/core/form/entity/entity-editor.class.d.ts +2 -0
|
@@ -60,7 +60,7 @@ import { timer, merge, fromEvent, BehaviorSubject, Subscription, Subject, isObse
|
|
|
60
60
|
import { filter, map, takeUntil, first, switchMap, tap, debounceTime, startWith, distinctUntilChanged, mergeMap, catchError, throttleTime, skip, bufferWhen, mapTo, take } from 'rxjs/operators';
|
|
61
61
|
import { trigger, transition, style, animate, state } from '@angular/animations';
|
|
62
62
|
import * as i1 from '@ionic/angular';
|
|
63
|
-
import { IonicModule, Platform, ToastController, IonicSafeString, createAnimation, IonicRouteStrategy, ModalController, AlertController, IonContent, IonItem, IonModal, IonInfiniteScroll } from '@ionic/angular';
|
|
63
|
+
import { IonicModule, Platform, ToastController, IonicSafeString, createAnimation, IonicRouteStrategy, ModalController, AlertController, IonContent, IonRouterOutlet, IonItem, IonModal, IonInfiniteScroll } from '@ionic/angular';
|
|
64
64
|
import { Capacitor } from '@capacitor/core';
|
|
65
65
|
import { Keyboard } from '@capacitor/keyboard';
|
|
66
66
|
import * as i1$2 from '@ngx-translate/core';
|
|
@@ -28076,6 +28076,7 @@ class AppEntityEditor extends AppTabEditor {
|
|
|
28076
28076
|
};
|
|
28077
28077
|
this.settings = injector.get(LocalSettingsService);
|
|
28078
28078
|
this.errorTranslator = injector.get(FormErrorTranslator);
|
|
28079
|
+
this.routerOutlet = injector.get(IonRouterOutlet);
|
|
28079
28080
|
this.cd = injector.get(ChangeDetectorRef);
|
|
28080
28081
|
this.dateFormat = injector.get(DateFormatService);
|
|
28081
28082
|
this.toastController = injector.get(ToastController);
|
|
@@ -28640,15 +28641,23 @@ class AppEntityEditor extends AppTabEditor {
|
|
|
28640
28641
|
this.markForCheck();
|
|
28641
28642
|
}
|
|
28642
28643
|
}
|
|
28643
|
-
updateRoute(data, queryParams) {
|
|
28644
|
+
async updateRoute(data, queryParams) {
|
|
28644
28645
|
const path = this.computePageUrl(isNotNil(data.id) ? data.id : 'new');
|
|
28645
28646
|
const commands = (path && typeof path === 'string') ? path.split('/') : path;
|
|
28646
28647
|
if (isNotEmptyArray(commands)) {
|
|
28647
28648
|
this.queryParams = queryParams || this.queryParams;
|
|
28648
|
-
|
|
28649
|
-
|
|
28650
|
-
|
|
28651
|
-
|
|
28649
|
+
// Disabling router animation
|
|
28650
|
+
this.routerOutlet.animated = false;
|
|
28651
|
+
try {
|
|
28652
|
+
return await this.router.navigate(commands, {
|
|
28653
|
+
replaceUrl: true,
|
|
28654
|
+
queryParams: this.queryParams
|
|
28655
|
+
});
|
|
28656
|
+
}
|
|
28657
|
+
finally {
|
|
28658
|
+
// Re enabling router animation
|
|
28659
|
+
this.routerOutlet.animated = true;
|
|
28660
|
+
}
|
|
28652
28661
|
}
|
|
28653
28662
|
else {
|
|
28654
28663
|
console.warn('Skip page route update. Invalid page path: ', path);
|