เพิ่มsearch avatar
This commit is contained in:
parent
62166c430e
commit
feb8da3947
1 changed files with 19 additions and 12 deletions
|
|
@ -196,7 +196,10 @@ export class ProfileController extends Controller {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (body.citizenId.length !== 13) {
|
if (body.citizenId.length !== 13) {
|
||||||
throw new HttpError(HttpStatus.NOT_FOUND, "กรุณากรอกข้อมูลรหัสบัตรประจำตัวประชาชนให้ครบ 13 หลัก");
|
throw new HttpError(
|
||||||
|
HttpStatus.NOT_FOUND,
|
||||||
|
"กรุณากรอกข้อมูลรหัสบัตรประจำตัวประชาชนให้ครบ 13 หลัก",
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (body.citizenId) {
|
if (body.citizenId) {
|
||||||
|
|
@ -245,7 +248,6 @@ export class ProfileController extends Controller {
|
||||||
// profile.dateRetireLaw = calculateRetireDate(profile.birthDate);
|
// profile.dateRetireLaw = calculateRetireDate(profile.birthDate);
|
||||||
await this.profileRepo.save(profile);
|
await this.profileRepo.save(profile);
|
||||||
|
|
||||||
|
|
||||||
return new HttpSuccess();
|
return new HttpSuccess();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -333,7 +335,10 @@ export class ProfileController extends Controller {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (body.citizenId && body.citizenId.length !== 13) {
|
if (body.citizenId && body.citizenId.length !== 13) {
|
||||||
throw new HttpError(HttpStatus.NOT_FOUND, "กรุณากรอกข้อมูลรหัสบัตรประจำตัวประชาชนให้ครบ 13 หลัก");
|
throw new HttpError(
|
||||||
|
HttpStatus.NOT_FOUND,
|
||||||
|
"กรุณากรอกข้อมูลรหัสบัตรประจำตัวประชาชนให้ครบ 13 หลัก",
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (body.citizenId) {
|
if (body.citizenId) {
|
||||||
|
|
@ -652,6 +657,8 @@ export class ProfileController extends Controller {
|
||||||
|
|
||||||
return {
|
return {
|
||||||
id: _data.id,
|
id: _data.id,
|
||||||
|
avatar: _data.avatar,
|
||||||
|
avatarName: _data.avatarName,
|
||||||
prefix: _data.prefix,
|
prefix: _data.prefix,
|
||||||
rank: _data.rank,
|
rank: _data.rank,
|
||||||
firstName: _data.firstName,
|
firstName: _data.firstName,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue