fix
This commit is contained in:
parent
2784054e2f
commit
fc90dff9ee
1 changed files with 15 additions and 14 deletions
|
|
@ -701,13 +701,13 @@ export class PositionController extends Controller {
|
|||
);
|
||||
}
|
||||
|
||||
let fullPosMasterNo = String((requestBody.posMasterNoPrefix).trim() + (requestBody.posMasterNo) + (requestBody.posMasterNoSuffix).trim());
|
||||
if (fullPosMasterNo === String(requestBody.posMasterNo)) {
|
||||
throw new HttpError(
|
||||
HttpStatusCode.INTERNAL_SERVER_ERROR,
|
||||
"ไม่สามารถใส่ข้อมูลซ้ำกันได้",
|
||||
);
|
||||
}
|
||||
// let fullPosMasterNo = String((requestBody.posMasterNoPrefix).trim() + (requestBody.posMasterNo) + (requestBody.posMasterNoSuffix).trim());
|
||||
// if (fullPosMasterNo === String(requestBody.posMasterNo)) {
|
||||
// throw new HttpError(
|
||||
// HttpStatusCode.INTERNAL_SERVER_ERROR,
|
||||
// "ไม่สามารถใส่ข้อมูลซ้ำกันได้",
|
||||
// );
|
||||
// }
|
||||
|
||||
|
||||
posMaster.createdUserId = request.user.sub;
|
||||
|
|
@ -929,13 +929,14 @@ export class PositionController extends Controller {
|
|||
}
|
||||
}
|
||||
|
||||
let fullPosMasterNo = String((requestBody.posMasterNoPrefix).trim() + (requestBody.posMasterNo) + (requestBody.posMasterNoSuffix).trim());
|
||||
if (fullPosMasterNo === String(requestBody.posMasterNo)) {
|
||||
throw new HttpError(
|
||||
HttpStatusCode.INTERNAL_SERVER_ERROR,
|
||||
"ไม่สามารถเพิ่มข้อมูลชื่อตำแหน่งซ้ำกันได้",
|
||||
);
|
||||
}
|
||||
// let fullPosMasterNo = String((requestBody.posMasterNoPrefix).trim() + (requestBody.posMasterNo) + (requestBody.posMasterNoSuffix).trim());
|
||||
// if (fullPosMasterNo === String(requestBody.posMasterNo)) {
|
||||
// throw new HttpError(
|
||||
// HttpStatusCode.INTERNAL_SERVER_ERROR,
|
||||
// "ไม่สามารถเพิ่มข้อมูลชื่อตำแหน่งซ้ำกันได้",
|
||||
// );
|
||||
// }
|
||||
|
||||
// const chk_SName0 = await this.posMasterRepository.findOne({
|
||||
// where: {
|
||||
// orgRevisionId: posMaster.orgRevisionId,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue