@eeplatform/basic-edu 1.10.31 → 1.10.32
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 +6 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -3081,7 +3081,9 @@ var learnerInfoSchema = import_joi5.default.object({
|
|
|
3081
3081
|
firstName: import_joi5.default.string().required(),
|
|
3082
3082
|
middleName: import_joi5.default.string().optional().allow("", null),
|
|
3083
3083
|
extensionName: import_joi5.default.string().optional().allow("", null),
|
|
3084
|
-
birthDate: import_joi5.default.string().required()
|
|
3084
|
+
birthDate: import_joi5.default.string().regex(/^\d{2}-\d{2}-\d{4}$/).required().messages({
|
|
3085
|
+
"string.pattern.base": "Birth date must be in the format DD-MM-YYYY"
|
|
3086
|
+
}),
|
|
3085
3087
|
sex: import_joi5.default.string().required(),
|
|
3086
3088
|
// Changed to accept any string to match frontend
|
|
3087
3089
|
age: import_joi5.default.number().integer().min(0).max(150).required(),
|
|
@@ -3249,6 +3251,7 @@ function MLearner(value) {
|
|
|
3249
3251
|
throw new import_nodejs_utils8.BadRequestError("Invalid specialProgram format");
|
|
3250
3252
|
}
|
|
3251
3253
|
}
|
|
3254
|
+
value.learnerInfo.birthDate = new Date(value.learnerInfo.birthDate);
|
|
3252
3255
|
return {
|
|
3253
3256
|
_id: value._id ?? void 0,
|
|
3254
3257
|
region: value.region,
|