Merge branch 'develop' into adiDev

This commit is contained in:
AdisakKanthawilang 2024-02-20 15:23:05 +07:00
commit 4b1df34f5b

View file

@ -623,8 +623,8 @@ export class PositionController extends Controller {
} else {
const dataDup: any = await this.posMasterRepository.findOne({
where: {
orgChild3Id: orgChild3.id,
orgChild4Id: IsNull() || "",
id: Not(posMaster.id),
orgChild4Id: orgChild4.id,
posMasterNoPrefix: requestBody.posMasterNoPrefix,
posMasterNo: requestBody.posMasterNo,
posMasterNoSuffix: requestBody.posMasterNoSuffix,
@ -645,8 +645,8 @@ export class PositionController extends Controller {
} else {
const dataDup: any = await this.posMasterRepository.findOne({
where: {
orgChild2Id: orgChild2.id,
orgChild3Id: IsNull() || "",
id: Not(posMaster.id),
orgChild3Id: orgChild3.id,
orgChild4Id: IsNull() || "",
posMasterNoPrefix: requestBody.posMasterNoPrefix,
posMasterNo: requestBody.posMasterNo,
@ -667,8 +667,8 @@ export class PositionController extends Controller {
} else {
const dataDup: any = await this.posMasterRepository.findOne({
where: {
orgChild1Id: orgChild1.id,
orgChild2Id: IsNull() || "",
id: Not(posMaster.id),
orgChild2Id: orgChild2.id,
orgChild3Id: IsNull() || "",
orgChild4Id: IsNull() || "",
posMasterNoPrefix: requestBody.posMasterNoPrefix,
@ -689,8 +689,8 @@ export class PositionController extends Controller {
} else {
const dataDup: any = await this.posMasterRepository.findOne({
where: {
orgRootId: orgRoot.id,
orgChild1Id: IsNull() || "",
id: Not(posMaster.id),
orgChild1Id: orgChild1.id,
orgChild2Id: IsNull() || "",
orgChild3Id: IsNull() || "",
orgChild4Id: IsNull() || "",
@ -711,6 +711,7 @@ export class PositionController extends Controller {
} else {
const dataDup: any = await this.posMasterRepository.findOne({
where: {
id: Not(posMaster.id),
orgRootId: orgRoot.id,
orgChild1Id: IsNull() || "",
orgChild2Id: IsNull() || "",