@etsoo/appscript 1.2.33 → 1.2.34

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.
@@ -320,8 +320,9 @@ export interface ICoreApp<S extends IAppSettings, N, C extends NotificationCallP
320
320
  switchOrg(id: number, serviceId?: number): Promise<boolean | undefined>;
321
321
  /**
322
322
  * Go to the login page
323
+ * @param tryLogin Try to login again
323
324
  */
324
- toLoginPage(): void;
325
+ toLoginPage(tryLogin?: boolean): void;
325
326
  /**
326
327
  * Transform URL
327
328
  * @param url URL
@@ -723,8 +724,9 @@ export declare abstract class CoreApp<S extends IAppSettings, N, C extends Notif
723
724
  switchOrg(id: number, serviceId?: number): Promise<boolean | undefined>;
724
725
  /**
725
726
  * Go to the login page
727
+ * @param tryLogin Try to login again
726
728
  */
727
- toLoginPage(): void;
729
+ toLoginPage(tryLogin?: boolean): void;
728
730
  /**
729
731
  * Transform URL
730
732
  * @param url URL
@@ -896,8 +896,10 @@ class CoreApp {
896
896
  }
897
897
  /**
898
898
  * Go to the login page
899
+ * @param tryLogin Try to login again
899
900
  */
900
- toLoginPage() {
901
+ toLoginPage(tryLogin) {
902
+ const url = this.transformUrl('/' + (tryLogin ? '' : '?tryLogin=false'));
901
903
  window.location.replace(this.transformUrl('/'));
902
904
  }
903
905
  /**
@@ -320,8 +320,9 @@ export interface ICoreApp<S extends IAppSettings, N, C extends NotificationCallP
320
320
  switchOrg(id: number, serviceId?: number): Promise<boolean | undefined>;
321
321
  /**
322
322
  * Go to the login page
323
+ * @param tryLogin Try to login again
323
324
  */
324
- toLoginPage(): void;
325
+ toLoginPage(tryLogin?: boolean): void;
325
326
  /**
326
327
  * Transform URL
327
328
  * @param url URL
@@ -723,8 +724,9 @@ export declare abstract class CoreApp<S extends IAppSettings, N, C extends Notif
723
724
  switchOrg(id: number, serviceId?: number): Promise<boolean | undefined>;
724
725
  /**
725
726
  * Go to the login page
727
+ * @param tryLogin Try to login again
726
728
  */
727
- toLoginPage(): void;
729
+ toLoginPage(tryLogin?: boolean): void;
728
730
  /**
729
731
  * Transform URL
730
732
  * @param url URL
@@ -893,8 +893,10 @@ export class CoreApp {
893
893
  }
894
894
  /**
895
895
  * Go to the login page
896
+ * @param tryLogin Try to login again
896
897
  */
897
- toLoginPage() {
898
+ toLoginPage(tryLogin) {
899
+ const url = this.transformUrl('/' + (tryLogin ? '' : '?tryLogin=false'));
898
900
  window.location.replace(this.transformUrl('/'));
899
901
  }
900
902
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@etsoo/appscript",
3
- "version": "1.2.33",
3
+ "version": "1.2.34",
4
4
  "description": "Applications shared TypeScript framework",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/mjs/index.js",
@@ -437,8 +437,9 @@ export interface ICoreApp<
437
437
 
438
438
  /**
439
439
  * Go to the login page
440
+ * @param tryLogin Try to login again
440
441
  */
441
- toLoginPage(): void;
442
+ toLoginPage(tryLogin?: boolean): void;
442
443
 
443
444
  /**
444
445
  * Transform URL
@@ -1611,8 +1612,12 @@ export abstract class CoreApp<
1611
1612
 
1612
1613
  /**
1613
1614
  * Go to the login page
1615
+ * @param tryLogin Try to login again
1614
1616
  */
1615
- toLoginPage() {
1617
+ toLoginPage(tryLogin?: boolean) {
1618
+ const url = this.transformUrl(
1619
+ '/' + (tryLogin ? '' : '?tryLogin=false')
1620
+ );
1616
1621
  window.location.replace(this.transformUrl('/'));
1617
1622
  }
1618
1623