@eeplatform/basic-edu 1.1.0 → 1.1.2
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.
- package/CHANGELOG.md +12 -0
- package/dist/index.d.ts +46 -19
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -3,7 +3,6 @@ import * as mongodb from 'mongodb';
|
|
|
3
3
|
import { ObjectId, ClientSession } from 'mongodb';
|
|
4
4
|
import * as bson from 'bson';
|
|
5
5
|
import { Request, Response, NextFunction } from 'express';
|
|
6
|
-
import { Express } from 'express-serve-static-core';
|
|
7
6
|
|
|
8
7
|
type TCurriculumSubject = {
|
|
9
8
|
educationLevel: string;
|
|
@@ -58,7 +57,11 @@ declare function useCurriculumRepo(): {
|
|
|
58
57
|
limit?: number | undefined;
|
|
59
58
|
sort?: {} | undefined;
|
|
60
59
|
status?: string | undefined;
|
|
61
|
-
}) => Promise<Record<string, any
|
|
60
|
+
}) => Promise<Record<string, any> | {
|
|
61
|
+
items: any[];
|
|
62
|
+
pages: number;
|
|
63
|
+
pageRange: string;
|
|
64
|
+
}>;
|
|
62
65
|
getById: (_id: string | ObjectId) => Promise<TCurriculum | null>;
|
|
63
66
|
updateById: (_id: ObjectId | string, value: {
|
|
64
67
|
code?: string;
|
|
@@ -206,7 +209,11 @@ declare function useEnrollmentRepo(): {
|
|
|
206
209
|
school?: string | undefined;
|
|
207
210
|
schoolYear?: string | undefined;
|
|
208
211
|
gradeLevelToEnroll?: string | undefined;
|
|
209
|
-
}) => Promise<Record<string, any
|
|
212
|
+
}) => Promise<Record<string, any> | {
|
|
213
|
+
items: any[];
|
|
214
|
+
pages: number;
|
|
215
|
+
pageRange: string;
|
|
216
|
+
}>;
|
|
210
217
|
getById: (_id: string | ObjectId) => Promise<BasicEducEnrForm>;
|
|
211
218
|
getByLrn: (lrn: string, schoolYear?: string) => Promise<BasicEducEnrForm | null>;
|
|
212
219
|
deleteById: (_id: string | ObjectId, deletedBy?: string, session?: ClientSession) => Promise<mongodb.UpdateResult<bson.Document>>;
|
|
@@ -231,7 +238,11 @@ declare function useEnrollmentService(): {
|
|
|
231
238
|
school?: string | undefined;
|
|
232
239
|
schoolYear?: string | undefined;
|
|
233
240
|
gradeLevelToEnroll?: string | undefined;
|
|
234
|
-
}) => Promise<Record<string, any
|
|
241
|
+
}) => Promise<Record<string, any> | {
|
|
242
|
+
items: any[];
|
|
243
|
+
pages: number;
|
|
244
|
+
pageRange: string;
|
|
245
|
+
}>;
|
|
235
246
|
getEnrollmentById: (_id: string | ObjectId) => Promise<BasicEducEnrForm>;
|
|
236
247
|
getEnrollmentByLrn: (lrn: string, schoolYear?: string) => Promise<BasicEducEnrForm | null>;
|
|
237
248
|
deleteEnrollment: (_id: string | ObjectId, deletedBy?: string) => Promise<{
|
|
@@ -315,8 +326,12 @@ declare function useGradeLevelRepo(): {
|
|
|
315
326
|
teachingStyle?: string | undefined;
|
|
316
327
|
school?: string | undefined;
|
|
317
328
|
status?: string | undefined;
|
|
318
|
-
}) => Promise<Record<string, any
|
|
319
|
-
|
|
329
|
+
}) => Promise<Record<string, any> | {
|
|
330
|
+
items: any[];
|
|
331
|
+
pages: number;
|
|
332
|
+
pageRange: string;
|
|
333
|
+
}>;
|
|
334
|
+
getById: (_id: string | ObjectId) => Promise<bson.Document | TGradeLevel>;
|
|
320
335
|
updateById: (_id: ObjectId | string, value: {
|
|
321
336
|
educationLevel?: string;
|
|
322
337
|
gradeLevel?: string;
|
|
@@ -359,7 +374,11 @@ declare function useRegionRepo(): {
|
|
|
359
374
|
page?: number | undefined;
|
|
360
375
|
limit?: number | undefined;
|
|
361
376
|
sort?: {} | undefined;
|
|
362
|
-
}) => Promise<Record<string, any
|
|
377
|
+
}) => Promise<Record<string, any> | {
|
|
378
|
+
items: any[];
|
|
379
|
+
pages: number;
|
|
380
|
+
pageRange: string;
|
|
381
|
+
}>;
|
|
363
382
|
getById: (_id: string | ObjectId) => Promise<TRegion>;
|
|
364
383
|
updateFieldById: ({ _id, field, value }?: {
|
|
365
384
|
_id: string | ObjectId;
|
|
@@ -404,7 +423,11 @@ declare function useDivisionRepo(): {
|
|
|
404
423
|
limit?: number | undefined;
|
|
405
424
|
sort?: {} | undefined;
|
|
406
425
|
region?: string | undefined;
|
|
407
|
-
}) => Promise<Record<string, any
|
|
426
|
+
}) => Promise<Record<string, any> | {
|
|
427
|
+
items: any[];
|
|
428
|
+
pages: number;
|
|
429
|
+
pageRange: string;
|
|
430
|
+
}>;
|
|
408
431
|
getById: (_id: string | ObjectId) => Promise<TDivision>;
|
|
409
432
|
updateFieldById: ({ _id, field, value }?: {
|
|
410
433
|
_id: string | ObjectId;
|
|
@@ -545,12 +568,12 @@ declare function useAssetRepo(): {
|
|
|
545
568
|
deleteById: (_id: string | ObjectId) => Promise<string>;
|
|
546
569
|
getById: (_id: string | ObjectId) => Promise<TAsset>;
|
|
547
570
|
getAll: ({ page, search, limit, status, school, sort, asset_type, }?: {
|
|
548
|
-
page?: number
|
|
549
|
-
search?: string
|
|
550
|
-
limit?: number
|
|
551
|
-
status?: string
|
|
552
|
-
school?: string | ObjectId
|
|
553
|
-
sort?: Record<string, any
|
|
571
|
+
page?: number;
|
|
572
|
+
search?: string;
|
|
573
|
+
limit?: number;
|
|
574
|
+
status?: string;
|
|
575
|
+
school?: string | ObjectId;
|
|
576
|
+
sort?: Record<string, any>;
|
|
554
577
|
asset_type: string;
|
|
555
578
|
}) => Promise<{}>;
|
|
556
579
|
getCategories: (school: string | ObjectId, asset_type: string) => Promise<{}>;
|
|
@@ -596,10 +619,10 @@ declare function useStockCardRepository(): {
|
|
|
596
619
|
add: (value: TStockCard, session?: ClientSession) => Promise<ObjectId>;
|
|
597
620
|
getById: (_id: string | ObjectId) => Promise<{}>;
|
|
598
621
|
getAll: ({ page, limit, school, sort, id }?: {
|
|
599
|
-
page?: number
|
|
600
|
-
limit?: number
|
|
601
|
-
school?: string | ObjectId
|
|
602
|
-
sort?: Record<string, any
|
|
622
|
+
page?: number;
|
|
623
|
+
limit?: number;
|
|
624
|
+
school?: string | ObjectId;
|
|
625
|
+
sort?: Record<string, any>;
|
|
603
626
|
id: string | ObjectId;
|
|
604
627
|
}) => Promise<{}>;
|
|
605
628
|
getSuppliers: (school: string | ObjectId) => Promise<{}>;
|
|
@@ -652,7 +675,11 @@ declare function usePlantillaRepo(): {
|
|
|
652
675
|
sort?: {} | undefined;
|
|
653
676
|
org?: string | undefined;
|
|
654
677
|
status?: string | undefined;
|
|
655
|
-
}) => Promise<Record<string, any
|
|
678
|
+
}) => Promise<Record<string, any> | {
|
|
679
|
+
items: any[];
|
|
680
|
+
pages: number;
|
|
681
|
+
pageRange: string;
|
|
682
|
+
}>;
|
|
656
683
|
getById: (_id: string | ObjectId) => Promise<TPlantilla | null>;
|
|
657
684
|
updateById: (_id: ObjectId | string, value: Partial<Pick<TPlantilla, "status" | "positionTitle" | "updatedAt">>, session?: ClientSession) => Promise<mongodb.UpdateResult<bson.Document>>;
|
|
658
685
|
deleteById: (_id: string | ObjectId, session?: ClientSession) => Promise<mongodb.UpdateResult<bson.Document>>;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eeplatform/basic-edu",
|
|
3
3
|
"license": "MIT",
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.2",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
@@ -16,11 +16,11 @@
|
|
|
16
16
|
"@types/multer": "^1.4.13",
|
|
17
17
|
"@types/nodemailer": "^6.4.15",
|
|
18
18
|
"tsup": "^6.5.0",
|
|
19
|
-
"typescript": "^
|
|
19
|
+
"typescript": "^5.2.2"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
22
|
"@eeplatform/core": "^1.7.0",
|
|
23
|
-
"@eeplatform/nodejs-utils": "^1.2.
|
|
23
|
+
"@eeplatform/nodejs-utils": "^1.2.2",
|
|
24
24
|
"dotenv": "^16.4.5",
|
|
25
25
|
"express": "^4.21.2",
|
|
26
26
|
"handlebars": "^4.7.8",
|