no message
This commit is contained in:
parent
4aa3c979b8
commit
e974821777
2 changed files with 20 additions and 1 deletions
|
|
@ -3199,7 +3199,7 @@ export class PositionController extends Controller {
|
|||
) {
|
||||
let typeCondition: any = {};
|
||||
let conditionA =
|
||||
"posType.posTypeId LIKE :posTypeName AND posLevel.posLevelName LIKE :posLevel AND positions.positionName LIKE :position";
|
||||
"posType.posTypeName LIKE :posType AND posLevel.posLevelName LIKE :posLevel AND positions.positionName LIKE :position";
|
||||
|
||||
let posType = await this.posTypeRepository.findOne({
|
||||
where: { id: String(body.posType) },
|
||||
|
|
|
|||
|
|
@ -2814,6 +2814,25 @@ export class ProfileController extends Controller {
|
|||
return new HttpSuccess(profile);
|
||||
}
|
||||
|
||||
/**
|
||||
* API รายละเอียดรายการทะเบียนประวัติ
|
||||
*
|
||||
* @summary ORG_065 - รายละเอียดรายการทะเบียนประวัติ (ADMIN) #70
|
||||
*
|
||||
* @param {string} id Id ทะเบียนประวัติ
|
||||
*/
|
||||
@Get("keycloak")
|
||||
async getProfileIdByKeycloak(@Request() request: RequestWithUser) {
|
||||
const profile = await this.profileRepo.findOne({
|
||||
where: { keycloak: request.user.sub },
|
||||
select:["id"]
|
||||
});
|
||||
|
||||
if (!profile) throw new HttpError(HttpStatus.NOT_FOUND, "ไม่พบข้อมูล");
|
||||
|
||||
return new HttpSuccess(profile.id);
|
||||
}
|
||||
|
||||
@Get("type")
|
||||
async checkRole(@Request() request: RequestWithUser) {
|
||||
let role: any;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue