get profile by token

This commit is contained in:
Kittapath 2024-05-24 01:11:47 +07:00
parent 58fe2f08fd
commit 85f8fbb03a
5 changed files with 124 additions and 59 deletions

View file

@ -71,19 +71,19 @@ export class ProfileGovernmentEmployeeController extends Controller {
orgChild4: true,
},
});
const position = await this.positionRepo.findOne({
where: {
positionIsSelected: true,
posMaster: {
orgRevision: {
orgRevisionIsCurrent: true,
orgRevisionIsDraft: false,
},
current_holderId: profile.id,
},
},
order: { createdAt: "DESC" },
});
// const position = await this.positionRepo.findOne({
// where: {
// positionIsSelected: true,
// posMaster: {
// orgRevision: {
// orgRevisionIsCurrent: true,
// orgRevisionIsDraft: false,
// },
// current_holderId: profile.id,
// },
// },
// order: { createdAt: "DESC" },
// });
if (!record) throw new HttpError(HttpStatus.NOT_FOUND, "ไม่พบข้อมูล");
const fullNameParts = [