user request data

This commit is contained in:
kittapath 2024-09-30 17:56:49 +07:00
parent 939ed6ddfd
commit d899039b9d
9 changed files with 688 additions and 6 deletions

View file

@ -154,7 +154,7 @@ export class ProfileController extends Controller {
},
});
ImgUrl = response_.data.downloadUrl;
} catch { }
} catch {}
}
const province = await this.provinceRepository.findOneBy({
id: profile.registrationProvinceId,
@ -319,7 +319,7 @@ export class ProfileController extends Controller {
},
});
ImgUrl = response_.data.downloadUrl;
} catch { }
} catch {}
}
const profileOc = await this.profileRepo.findOne({
relations: [
@ -2679,7 +2679,7 @@ export class ProfileController extends Controller {
@Get("admin/{id}")
async getProfileAdmin(@Path() id: string) {
const profile = await this.profileRepo.findOne({
const profile: any = await this.profileRepo.findOne({
relations: {
posLevel: true,
posType: true,
@ -2688,7 +2688,7 @@ export class ProfileController extends Controller {
});
if (!profile) throw new HttpError(HttpStatus.NOT_FOUND, "ไม่พบข้อมูล");
profile.profileType = "OFFICER";
return new HttpSuccess(profile);
}