cloud-ide-lms-model 1.1.12 → 1.1.14

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.
@@ -0,0 +1,21 @@
1
+ import { CoreSystemEntity, AuthUserMst } from "../../schema";
2
+ import { controllerResponse } from "../../utilities";
3
+ type IEntitySwitchErrorLogger = {
4
+ [key in keyof MEntitySwitch]: string;
5
+ };
6
+ declare class MEntitySwitch {
7
+ syen_id?: string;
8
+ constructor(init: MEntitySwitch);
9
+ Validate(): Partial<IEntitySwitchErrorLogger>;
10
+ }
11
+ interface switchEntityControllerResponse extends controllerResponse {
12
+ data?: Partial<switchEntityResponseData>;
13
+ token?: string;
14
+ }
15
+ interface switchEntityResponseData {
16
+ auth_user_mst: Partial<AuthUserMst>;
17
+ core_system_entity?: CoreSystemEntity;
18
+ }
19
+ export { IEntitySwitchErrorLogger, // interface
20
+ MEntitySwitch, // model
21
+ switchEntityControllerResponse, switchEntityResponseData };
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.MEntitySwitch = void 0;
4
+ /* INTERFACE END */
5
+ /* MODEL START */
6
+ class MEntitySwitch {
7
+ constructor(init) {
8
+ Object.assign(this, init);
9
+ }
10
+ Validate() {
11
+ let errorLogger = {};
12
+ if (!this.syen_id) {
13
+ errorLogger.syen_id = "Entity ID is Required";
14
+ }
15
+ return errorLogger;
16
+ }
17
+ }
18
+ exports.MEntitySwitch = MEntitySwitch;
@@ -4,3 +4,4 @@ export * from "./register";
4
4
  export * from "./reset-password";
5
5
  export * from "./auth_user_mst";
6
6
  export * from "./generate-view-only-token";
7
+ export * from "./entity-switch";
@@ -20,3 +20,4 @@ __exportStar(require("./register"), exports);
20
20
  __exportStar(require("./reset-password"), exports);
21
21
  __exportStar(require("./auth_user_mst"), exports);
22
22
  __exportStar(require("./generate-view-only-token"), exports);
23
+ __exportStar(require("./entity-switch"), exports);
@@ -18,5 +18,7 @@ declare const authRoutesUrl: {
18
18
  signOut: string;
19
19
  /** Endpoint to generate view-only token for public APIs */
20
20
  generateViewOnlyToken: string;
21
+ /** Endpoint to switch entity for logged-in user */
22
+ switchEntity: string;
21
23
  };
22
24
  export { authRoutesUrl };
@@ -21,6 +21,8 @@ const authRoutesUrl = {
21
21
  signOut: 'sign-out',
22
22
  /** Endpoint to generate view-only token for public APIs */
23
23
  generateViewOnlyToken: 'generate-view-only-token',
24
+ /** Endpoint to switch entity for logged-in user */
25
+ switchEntity: 'switch-entity',
24
26
  };
25
27
  exports.authRoutesUrl = authRoutesUrl;
26
28
  // Freeze the authRoutesUrl object to prevent modifications
package/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "typescript": "^5.4.2"
6
6
  },
7
7
  "name": "cloud-ide-lms-model",
8
- "version": "1.1.12",
8
+ "version": "1.1.14",
9
9
  "description": "Package for Model management of Cloud IDEsys LMS",
10
10
  "main": "lib/index.js",
11
11
  "types": "lib/index.d.ts",