fix word
This commit is contained in:
parent
2590054f9e
commit
830de8493b
4 changed files with 12 additions and 12 deletions
|
|
@ -79,7 +79,7 @@ export class PosLevelController extends Controller {
|
|||
if (chkPosLevelName) {
|
||||
throw new HttpError(
|
||||
HttpStatusCode.NOT_FOUND,
|
||||
"ชื่อระดับตำแหน่ง: " + requestBody.posLevelName + " มีอยู่ในระบบแล้ว",
|
||||
"ชื่อระดับตำแหน่งนี้มีอยู่ในระบบแล้ว",
|
||||
);
|
||||
}
|
||||
|
||||
|
|
@ -143,7 +143,7 @@ export class PosLevelController extends Controller {
|
|||
if (chkPosLevelName) {
|
||||
throw new HttpError(
|
||||
HttpStatusCode.NOT_FOUND,
|
||||
"ชื่อระดับตำแหน่ง: " + requestBody.posLevelName + " มีอยู่ในระบบแล้ว",
|
||||
"ชื่อระดับตำแหน่งนี้มีอยู่ในระบบแล้ว",
|
||||
);
|
||||
}
|
||||
const validPosLevelAuthority = ["HEAD", "DEPUTY", "GOVERNOR"];
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ export class PosTypeController extends Controller {
|
|||
if (chkPosTypeName) {
|
||||
throw new HttpError(
|
||||
HttpStatusCode.NOT_FOUND,
|
||||
"ชื่อประเภทตำแหน่ง: " + requestBody.posTypeName + " มีอยู่ในระบบแล้ว",
|
||||
"ชื่อประเภทตำแหน่งนี้มีอยู่ในระบบแล้ว",
|
||||
);
|
||||
}
|
||||
posType.createdUserId = request.user.sub;
|
||||
|
|
@ -105,7 +105,7 @@ export class PosTypeController extends Controller {
|
|||
if (chkPosTypeName) {
|
||||
throw new HttpError(
|
||||
HttpStatusCode.NOT_FOUND,
|
||||
"ชื่อประเภทตำแหน่ง: " + requestBody.posTypeName + " มีอยู่ในระบบแล้ว",
|
||||
"ชื่อประเภทตำแหน่งนี้มีอยู่ในระบบแล้ว",
|
||||
);
|
||||
}
|
||||
posType.lastUpdateUserId = request.user.sub;
|
||||
|
|
@ -172,7 +172,7 @@ export class PosTypeController extends Controller {
|
|||
where: { id: id },
|
||||
});
|
||||
if (!getPosType) {
|
||||
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไไม่พบข้อมูลประเภทตำแหน่งนี้");
|
||||
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่พบข้อมูลประเภทตำแหน่งนี้");
|
||||
}
|
||||
|
||||
const mapGetPosType = {
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ export class ProfileController extends Controller {
|
|||
where: { citizenId: requestBody.citizenId },
|
||||
});
|
||||
if (_profile) {
|
||||
throw new HttpError(HttpStatusCode.INTERNAL_SERVER_ERROR, "เลขบัตรนี้มีอยู่ในระบบแล้ว");
|
||||
throw new HttpError(HttpStatusCode.INTERNAL_SERVER_ERROR, "เลขประจำตัวประชาชนนี้มีอยู่ในระบบแล้ว");
|
||||
}
|
||||
if (requestBody.posLevelId == "") {
|
||||
requestBody.posLevelId = null;
|
||||
|
|
@ -90,7 +90,7 @@ export class ProfileController extends Controller {
|
|||
if (checkCitizenId) {
|
||||
throw new HttpError(
|
||||
HttpStatusCode.NOT_FOUND,
|
||||
"มีรหัสประจำตัวประชาชนนี้แล้วในระบบ (citizenId)",
|
||||
"เลขประจำตัวประชาชนนี้มีอยู่ในระบบแล้ว",
|
||||
);
|
||||
}
|
||||
|
||||
|
|
@ -126,7 +126,7 @@ export class ProfileController extends Controller {
|
|||
where: { id: Not(id), citizenId: requestBody.citizenId },
|
||||
});
|
||||
if (_profile) {
|
||||
throw new HttpError(HttpStatusCode.INTERNAL_SERVER_ERROR, "เลขบัตรนี้มีอยู่ในระบบแล้ว");
|
||||
throw new HttpError(HttpStatusCode.INTERNAL_SERVER_ERROR, "เลขประจำตัวประชาชนนี้มีอยู่ในระบบแล้ว");
|
||||
}
|
||||
|
||||
if (requestBody.posLevelId == "") {
|
||||
|
|
@ -163,7 +163,7 @@ export class ProfileController extends Controller {
|
|||
if (checkCitizenId) {
|
||||
throw new HttpError(
|
||||
HttpStatusCode.NOT_FOUND,
|
||||
"มีรหัสประจำตัวประชาชนนี้แล้วในระบบ (citizenId)",
|
||||
"เลขประจำตัวประชาชนนี้มีอยู่ในระบบแล้ว",
|
||||
);
|
||||
}
|
||||
|
||||
|
|
@ -781,7 +781,7 @@ export class ProfileController extends Controller {
|
|||
where: { id: Not(id), citizenId: requestBody.citizenId },
|
||||
});
|
||||
if (profile) {
|
||||
throw new HttpError(HttpStatusCode.INTERNAL_SERVER_ERROR, "เลขบัตรนี้มีอยู่ในระบบแล้ว");
|
||||
throw new HttpError(HttpStatusCode.INTERNAL_SERVER_ERROR, "เลขประจำตัวประชาชนนี้มีอยู่ในระบบแล้ว");
|
||||
}
|
||||
return new HttpSuccess();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ export class RankController extends Controller {
|
|||
) {
|
||||
const rank = await this.rankRepository.findOne({ where: { id: id } });
|
||||
if (!rank) {
|
||||
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่พบข้อมูลยศนี้");
|
||||
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่พบข้อมูลตำแหน่งนี้");
|
||||
}
|
||||
|
||||
const checkName = await this.rankRepository.findOne({
|
||||
|
|
@ -106,7 +106,7 @@ export class RankController extends Controller {
|
|||
where: { id },
|
||||
});
|
||||
if (!delRank) {
|
||||
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่พบข้อมูลยศนี้");
|
||||
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่พบข้อมูลตำแหน่งนี้");
|
||||
}
|
||||
await this.rankRepository.delete({ id: id });
|
||||
return new HttpSuccess();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue