diff --git a/src/controllers/EducationLevelController.ts b/src/controllers/EducationLevelController.ts index cbdb68d5..a8ba9cbe 100644 --- a/src/controllers/EducationLevelController.ts +++ b/src/controllers/EducationLevelController.ts @@ -135,7 +135,7 @@ export class EducationLevelController extends Controller { async detailEducationLevel(@Path() id: string) { const educationLevel = await this.educationLevelRepository.findOne({ where: { id }, - select: ["id", "name", "rank"], + select: ["id", "name", "rank", "createdAt", "lastUpdatedAt", "createdFullName", "lastUpdateFullName"], }); if (!educationLevel) { throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่พบข้อมูล"); @@ -156,7 +156,7 @@ export class EducationLevelController extends Controller { @Get() async listEducationLevel() { const educationLevel = await this.educationLevelRepository.find({ - select: ["id", "name", "createdAt", "lastUpdatedAt", "createdFullName", "lastUpdateFullName"], + select: ["id", "name","rank", "createdAt", "lastUpdatedAt", "createdFullName", "lastUpdateFullName"], order: { createdAt: "ASC" }, }); diff --git a/src/controllers/PositionController.ts b/src/controllers/PositionController.ts index 5ba95b57..a65b07de 100644 --- a/src/controllers/PositionController.ts +++ b/src/controllers/PositionController.ts @@ -492,7 +492,7 @@ export class PositionController extends Controller { posMaster.orgRevisionId = orgRoot.orgRevisionId; } - posMaster.createdUserId = request.user.sub; + posMaster.createdUserId = request.user.sub; //สงสัยว่าทำให้ bug แก้ไขไม่ได้ posMaster.createdFullName = request.user.name; posMaster.lastUpdateUserId = request.user.sub; posMaster.lastUpdateFullName = request.user.name; diff --git a/src/controllers/ReportController.ts b/src/controllers/ReportController.ts index 2df2ef49..bffe8e04 100644 --- a/src/controllers/ReportController.ts +++ b/src/controllers/ReportController.ts @@ -251,7 +251,6 @@ export class ReportController extends Controller { posMaster.next_holder == null ? "- ว่าง -" : `${posMaster.next_holder.prefix}${posMaster.next_holder.firstName} ${posMaster.next_holder.lastName}`, - profilePosMasterNo: posMaster.next_holder == null ? null : "xxx", profilePositionName: posMaster.next_holder == null ? positionName : "xxx", profilePosType: posMaster.next_holder == null ? posType : "xxx", @@ -262,7 +261,6 @@ export class ReportController extends Controller { // profilePosType: (positionOld == null ? null : positionOld.posType.posTypeName), // profilePosLevel: (positionOld == null ? null : positionOld.posLevel.posLevelName), // profilePositionField: (positionOld == null ? null : positionOld.positionField), - PositionName: positionName, PosType: posType, PosLevel: posLevel,