@kipicore/dbcore 1.1.84 → 1.1.86

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,29 +1,17 @@
1
1
  import { Document } from 'mongoose';
2
2
  import { USER_TYPES, COMMAN_STATUS } from '../constants/app';
3
3
  import { IDefaultAttributes } from './commonInterface';
4
- export interface IWebModuleList {
5
- webSequenceNumber: number;
4
+ export interface IModuleList {
5
+ sequenceNumber: number;
6
6
  moduleName: string;
7
- webConfig: string;
8
- webStatus: COMMAN_STATUS;
7
+ config: string;
8
+ status: COMMAN_STATUS;
9
9
  }
10
- export interface IMobileModuleList {
11
- mobileSequenceNumber: number;
10
+ export interface IQuickLinkList {
11
+ sequenceNumber: number;
12
12
  moduleName: string;
13
- mobileConfig: string;
14
- mobileStatus: COMMAN_STATUS;
15
- }
16
- export interface IWebQuickLinkList {
17
- webSequenceNumber: number;
18
- moduleName: string;
19
- webRoute: string;
20
- webStatus: COMMAN_STATUS;
21
- }
22
- export interface IMobileQuickLinkList {
23
- mobileSequenceNumber: number;
24
- moduleName: string;
25
- mobileRoute: string;
26
- mobileStatus: COMMAN_STATUS;
13
+ route: string;
14
+ status: COMMAN_STATUS;
27
15
  }
28
16
  export interface IDashboardManagementAttributes extends IDefaultAttributes, Document {
29
17
  id: string;
@@ -31,8 +19,8 @@ export interface IDashboardManagementAttributes extends IDefaultAttributes, Docu
31
19
  userId: string;
32
20
  instituteId: string;
33
21
  userType: USER_TYPES;
34
- webModuleList: IWebModuleList[];
35
- mobileModuleList: IMobileModuleList[];
36
- webQuickLinkList: IWebQuickLinkList[];
37
- mobileQuickLinkList: IMobileQuickLinkList[];
22
+ webModuleList: IModuleList[];
23
+ mobileModuleList: IModuleList[];
24
+ webQuickLinkList: IQuickLinkList[];
25
+ mobileQuickLinkList: IQuickLinkList[];
38
26
  }
@@ -35,8 +35,8 @@ var __importStar = (this && this.__importStar) || (function () {
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  const mongoose_1 = __importStar(require("mongoose"));
37
37
  const app_1 = require("../../constants/app");
38
- const webModuleSchema = new mongoose_1.Schema({
39
- webSequenceNumber: {
38
+ const DashboardManagementSchema = new mongoose_1.Schema({
39
+ sequenceNumber: {
40
40
  type: Number,
41
41
  required: false,
42
42
  },
@@ -44,19 +44,19 @@ const webModuleSchema = new mongoose_1.Schema({
44
44
  type: String,
45
45
  required: false,
46
46
  },
47
- webConfig: {
47
+ config: {
48
48
  type: String,
49
49
  required: false,
50
50
  },
51
- webStatus: {
51
+ status: {
52
52
  type: String,
53
53
  enum: Object.values(app_1.COMMAN_STATUS),
54
54
  default: app_1.COMMAN_STATUS.ACTIVE,
55
55
  required: false,
56
56
  },
57
57
  }, { _id: false });
58
- const mobileModuleSchema = new mongoose_1.Schema({
59
- mobileSequenceNumber: {
58
+ const quickLinkListSchema = new mongoose_1.Schema({
59
+ sequenceNumber: {
60
60
  type: Number,
61
61
  required: false,
62
62
  },
@@ -64,51 +64,11 @@ const mobileModuleSchema = new mongoose_1.Schema({
64
64
  type: String,
65
65
  required: false,
66
66
  },
67
- mobileConfig: {
67
+ route: {
68
68
  type: String,
69
69
  required: false,
70
70
  },
71
- mobileStatus: {
72
- type: String,
73
- enum: Object.values(app_1.COMMAN_STATUS),
74
- default: app_1.COMMAN_STATUS.ACTIVE,
75
- required: false,
76
- },
77
- }, { _id: false });
78
- const webQuickLinkListSchema = new mongoose_1.Schema({
79
- webSequenceNumber: {
80
- type: Number,
81
- required: false,
82
- },
83
- moduleName: {
84
- type: String,
85
- required: false,
86
- },
87
- webRoute: {
88
- type: String,
89
- required: false,
90
- },
91
- webStatus: {
92
- type: String,
93
- enum: Object.values(app_1.COMMAN_STATUS),
94
- default: app_1.COMMAN_STATUS.ACTIVE,
95
- required: false,
96
- },
97
- }, { _id: false });
98
- const mobileQuickLinkListSchema = new mongoose_1.Schema({
99
- mobileSequenceNumber: {
100
- type: Number,
101
- required: false,
102
- },
103
- moduleName: {
104
- type: String,
105
- required: false,
106
- },
107
- mobileRoute: {
108
- type: String,
109
- required: false,
110
- },
111
- mobileStatus: {
71
+ status: {
112
72
  type: String,
113
73
  enum: Object.values(app_1.COMMAN_STATUS),
114
74
  default: app_1.COMMAN_STATUS.ACTIVE,
@@ -133,20 +93,20 @@ const DashboardManagementModelSchema = new mongoose_1.Schema({
133
93
  enum: Object.values(app_1.USER_TYPES),
134
94
  required: false,
135
95
  },
136
- webModuleList: {
137
- type: [webModuleSchema],
138
- required: false,
139
- },
140
96
  webQuickLinkList: {
141
- type: [webQuickLinkListSchema],
97
+ type: [quickLinkListSchema],
142
98
  required: false,
143
99
  },
144
100
  mobileModuleList: {
145
- type: [mobileModuleSchema],
101
+ type: [DashboardManagementSchema],
102
+ required: false,
103
+ },
104
+ webModuleList: {
105
+ type: [DashboardManagementSchema],
146
106
  required: false,
147
107
  },
148
108
  mobileQuickLinkList: {
149
- type: [mobileQuickLinkListSchema],
109
+ type: [quickLinkListSchema],
150
110
  required: false,
151
111
  },
152
112
  createdBy: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kipicore/dbcore",
3
- "version": "1.1.84",
3
+ "version": "1.1.86",
4
4
  "description": "Reusable DB core package with Postgres, MongoDB, models, services, interfaces, and types",
5
5
  "types": "dist/index.d.ts",
6
6
  "main": "dist/index.js",