cloud-ide-lms-model 1.0.95 → 1.0.97

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.
@@ -1,3 +1,9 @@
1
+ type IPageNotesManagerErrorLogger = {
2
+ [key in keyof ICoreSypn]: string;
3
+ };
4
+ /**
5
+ * @description core_system_page_notes_manager (Reference: sypn)
6
+ */
1
7
  declare class ICoreSypn {
2
8
  _id?: string;
3
9
  sypn_titile?: string;
@@ -10,5 +16,7 @@ declare class ICoreSypn {
10
16
  sypn_is_user_specific?: string;
11
17
  sypn_is_entity_specific?: string;
12
18
  sypn_is_theme_specific?: string;
19
+ constructor(init: ICoreSypn);
20
+ Validate?(): Partial<IPageNotesManagerErrorLogger>;
13
21
  }
14
22
  export { ICoreSypn };
@@ -1,7 +1,34 @@
1
1
  "use strict";
2
+ /* INTERFASE START */
2
3
  Object.defineProperty(exports, "__esModule", { value: true });
3
4
  exports.ICoreSypn = void 0;
4
- /* INTERFASE START */
5
+ /* INTERFACE END */
6
+ /**
7
+ * @description core_system_page_notes_manager (Reference: sypn)
8
+ */
5
9
  class ICoreSypn {
10
+ constructor(init) {
11
+ Object.assign(this, init);
12
+ }
13
+ Validate() {
14
+ let errorLogger = {};
15
+ // Log errors here
16
+ if (!this.sypn_titile) {
17
+ errorLogger.sypn_titile = "Title is Required!";
18
+ }
19
+ if (this.sypn_is_page_specific && !this.sypn_page_id_sypg) {
20
+ errorLogger.sypn_page_id_sypg = "Page Id is Required!";
21
+ }
22
+ if (this.sypn_is_entity_specific && !this.sypn_entity_id_sype) {
23
+ errorLogger.sypn_entity_id_sype = "Entity Id is Required!";
24
+ }
25
+ if (this.sypn_is_user_specific && !this.sypn_user_id_user) {
26
+ errorLogger.sypn_entity_id_sype = "User Id is Required!";
27
+ }
28
+ if (this.sypn_is_theme_specific && !this.sypn_page_them_id_sytm) {
29
+ errorLogger.sypn_entity_id_sype = "Theme Id is Required!";
30
+ }
31
+ return errorLogger;
32
+ }
6
33
  }
7
34
  exports.ICoreSypn = ICoreSypn;
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.0.95",
8
+ "version": "1.0.97",
9
9
  "description": "Package for Model management of Cloud IDEsys LMS",
10
10
  "main": "lib/index.js",
11
11
  "types": "lib/index.d.ts",