แก้ชื่อ tag
This commit is contained in:
parent
4b4f2423fa
commit
f509e10f8c
9 changed files with 151 additions and 107 deletions
|
|
@ -95,6 +95,14 @@ export class OrgChild3Controller {
|
|||
throw new HttpError(HttpStatusCode.NOT_FOUND, "not found. Child2Id");
|
||||
}
|
||||
|
||||
const validOrgChild3Ranks = ["OFFICE", "DIVISION", "SECTION"];
|
||||
if (
|
||||
requestBody.orgChild3Rank == null ||
|
||||
!validOrgChild3Ranks.includes(requestBody.orgChild3Rank.toUpperCase())
|
||||
) {
|
||||
throw new HttpError(HttpStatusCode.NOT_FOUND, "not found. orgChild2Rank");
|
||||
}
|
||||
|
||||
const child3 = await this.child3Repository.findOne({ where: { id } });
|
||||
if (!child3) {
|
||||
throw new HttpError(HttpStatusCode.NOT_FOUND, "not found.");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue