diff --git a/src/controllers/WorkflowController.ts b/src/controllers/WorkflowController.ts index 909da84c..236fdcac 100644 --- a/src/controllers/WorkflowController.ts +++ b/src/controllers/WorkflowController.ts @@ -740,10 +740,8 @@ export class WorkflowController extends Controller { throw new HttpError(HttpStatus.NOT_FOUND, "ไม่พบตำแหน่งผู้ใช้งาน"); let condition: any = { - where: { - isDirector: true, - orgRootId: posMasterUser.orgRootId, - }, + isDirector: true, + orgRootId: posMasterUser.orgRootId, }; if (type.trim().toLowerCase() == "OPERATE") { @@ -759,14 +757,12 @@ export class WorkflowController extends Controller { posMasterUser.current_holder.posLevel.posLevelName == "ชำนาญการ") ) { condition = { - where: { - isDirector: true, - orgRootId: posMasterUser.orgRootId, - orgChild1Id: IsNull(), - orgChild2Id: IsNull(), - orgChild3Id: IsNull(), - orgChild4Id: IsNull(), - }, + isDirector: true, + orgRootId: posMasterUser.orgRootId, + orgChild1Id: IsNull(), + orgChild2Id: IsNull(), + orgChild3Id: IsNull(), + orgChild4Id: IsNull(), }; } else if ( (posMasterUser.current_holder.posType.posTypeName == "ทั่วไป" && @@ -777,14 +773,12 @@ export class WorkflowController extends Controller { posMasterUser.current_holder.posLevel.posLevelName == "ต้น") ) { condition = { - where: { - isDirector: true, - isDeputy: true, - orgChild1Id: IsNull(), - orgChild2Id: IsNull(), - orgChild3Id: IsNull(), - orgChild4Id: IsNull(), - }, + isDirector: true, + isDeputy: true, + orgChild1Id: IsNull(), + orgChild2Id: IsNull(), + orgChild3Id: IsNull(), + orgChild4Id: IsNull(), }; } else { }