isAncestorDNA to ancestorDNA

This commit is contained in:
Kittapath 2024-02-01 13:29:15 +07:00
parent 22b80868d4
commit 2832ab2268
9 changed files with 143 additions and 80 deletions

View file

@ -507,9 +507,9 @@ export class PositionController extends Controller {
}
/**
* API
* API
*
* @summary ORG_033 - (ADMIN) #35
* @summary ORG_034 - (ADMIN) #37
*
*/
@Put("master/{id}")
@ -737,38 +737,38 @@ export class PositionController extends Controller {
typeCondition = {
orgRootId: body.id,
};
if (!body.isAll) {
checkChildConditions = {
orgChild1Id: IsNull(),
};
}
if (!body.isAll) {
checkChildConditions = {
orgChild1Id: IsNull(),
};
}
} else if (body.type === 1) {
typeCondition = {
orgChild1Id: body.id,
};
if (!body.isAll) {
checkChildConditions = {
orgChild2Id: IsNull(),
};
}
if (!body.isAll) {
checkChildConditions = {
orgChild2Id: IsNull(),
};
}
} else if (body.type === 2) {
typeCondition = {
orgChild2Id: body.id,
};
if (!body.isAll) {
checkChildConditions = {
orgChild3Id: IsNull(),
};
}
if (!body.isAll) {
checkChildConditions = {
orgChild3Id: IsNull(),
};
}
} else if (body.type === 3) {
typeCondition = {
orgChild3Id: body.id,
};
if (!body.isAll) {
checkChildConditions = {
orgChild4Id: IsNull(),
};
}
if (!body.isAll) {
checkChildConditions = {
orgChild4Id: IsNull(),
};
}
} else if (body.type === 4) {
typeCondition = {
orgChild4Id: body.id,