@kipicore/dbcore 1.1.258 → 1.1.260

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.
@@ -4,7 +4,7 @@ import { IDefaultAttributes } from './commonInterface';
4
4
  export interface IModuleList {
5
5
  sequenceNumber: number;
6
6
  moduleName: string;
7
- config: Object;
7
+ config: object;
8
8
  status: COMMAN_STATUS;
9
9
  }
10
10
  export interface IQuickLinkList {
@@ -19,5 +19,5 @@ export interface IReplaceTeacherModelAttributes extends IDefaultAttributes, Docu
19
19
  teacherType: TEACHER_TYPE;
20
20
  batches: IReplaceTeacherBatchesSchema[];
21
21
  replaceTeacherStatus: REPLACE_TEACHER_STATUS;
22
- academicCalendarId: String;
22
+ academicCalendarId: string;
23
23
  }
@@ -1,3 +1,4 @@
1
+ import { Document } from "mongoose";
1
2
  import { TICKET_RAISE_PRIORITY, TICKET_RAISE_STATUS } from "../constants";
2
3
  import { IDefaultAttributes } from "./commonInterface";
3
4
  export interface ITicketRaiseConversationAttributes {
@@ -9,8 +9,8 @@ export interface IUserInstituteMetaSlots {
9
9
  }
10
10
  export interface IUserTrip {
11
11
  tripId: string;
12
- pickUpNo: Number;
13
- dropNo: Number;
12
+ pickUpNo: number;
13
+ dropNo: number;
14
14
  }
15
15
  export interface IStudentFeeService {
16
16
  feeTypeId: string;
@@ -55,4 +55,5 @@ export interface IUserInstituteMetaAttributes extends IDefaultAttributes, Docume
55
55
  previousEntities?: string[];
56
56
  studentFeeService?: IStudentFeeService[];
57
57
  studentFeeType?: FEE_COLLECTION_TYPE;
58
+ isSchoolMeta?: boolean;
58
59
  }
@@ -512,9 +512,7 @@ const addDocsDetailsHook = async (subjectIndexList, where = {}, options = {}) =>
512
512
  attributes: { exclude: defaultModelAttributes_1.DEFAULT_EXCLUDES_ATTRIBUTES },
513
513
  });
514
514
  const fileCategoryListById = (0, utils_1.keyByFieldOrFields)(fileCategoryList, 'id');
515
- return await Promise.all(
516
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
517
- subjectIndexList.map(async (subject) => {
515
+ return await Promise.all(subjectIndexList.map(async (subject) => {
518
516
  subject.batchDetails = batchListById[subject.batch] || {};
519
517
  subject.userDetails = userListById[subject.userId] || {};
520
518
  subject.createdByUser = userListById[subject.createdBy] || {};
@@ -559,9 +557,7 @@ const addDocsDetailsHook = async (subjectIndexList, where = {}, options = {}) =>
559
557
  }
560
558
  }
561
559
  if (subject.chapterIndex?.length) {
562
- subject.chapterIndex = await Promise.all(
563
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
564
- subject.chapterIndex.map(async (chapter) => {
560
+ subject.chapterIndex = await Promise.all(subject.chapterIndex.map(async (chapter) => {
565
561
  if (chapter.files?.length) {
566
562
  if (subject.type === app_1.SUBJECT_INDEX_TYPE.BATCH &&
567
563
  options.reqUser &&
@@ -223,6 +223,10 @@ const userInstituteMetaSchema = new mongoose_1.Schema({
223
223
  type: [String],
224
224
  required: false,
225
225
  },
226
+ isSchoolMeta: {
227
+ type: Boolean,
228
+ default: true,
229
+ },
226
230
  }, {
227
231
  timestamps: true,
228
232
  versionKey: false,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kipicore/dbcore",
3
- "version": "1.1.258",
3
+ "version": "1.1.260",
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",
@@ -13,6 +13,7 @@
13
13
  }
14
14
  },
15
15
  "scripts": {
16
+ "prepare": "husky install",
16
17
  "clean": "rm -rf dist",
17
18
  "build": "tsc -p tsconfig.json",
18
19
  "prebuild": "npm run clean",
@@ -49,13 +50,18 @@
49
50
  "uuid": "^8.3.2"
50
51
  },
51
52
  "devDependencies": {
53
+ "@eslint/js": "^9.17.0",
52
54
  "@types/mongoose": "^5.11.97",
53
55
  "@types/node": "^24.5.2",
54
56
  "@types/sequelize": "^4.28.14",
55
57
  "country-state-city": "^3.2.1",
58
+ "eslint": "^9.17.0",
59
+ "globals": "^15.14.0",
60
+ "husky": "^9.1.7",
56
61
  "prettier": "^3.3.3",
57
62
  "sequelize-cli": "^6.6.2",
58
- "typescript": "^5.5.4"
63
+ "typescript": "^5.5.4",
64
+ "typescript-eslint": "^8.18.2"
59
65
  },
60
66
  "files": [
61
67
  "dist",