| | |
| | | duWorktype.setDuSolutionId(duSolution.getId()); |
| | | duWorktype.setStatus(Constants.ZERO); |
| | | duWorktype.setSortnum(j); |
| | | duWorktype.setDispatchUnitId(dispatchUnit.getId()); |
| | | duWorktype.setWorkTypeId(saveDuWorkTypeDTO.getWorkTypeId()); |
| | | duWorktype.setVideoUrl(saveDuWorkTypeDTO.getVideoUrl()); |
| | | duWorktype.setStatus2(Constants.ZERO); |
| | |
| | | duWorktype.setDuSolutionId(duSolution.getId()); |
| | | duWorktype.setStatus(Constants.ZERO); |
| | | duWorktype.setSortnum(duWorkTypeNum + j); |
| | | duWorktype.setDispatchUnitId(saveDispatchUnitDTO.getId()); |
| | | duWorktype.setWorkTypeId(saveDuWorkTypeDTO.getWorkTypeId()); |
| | | duWorktype.setVideoUrl(saveDuWorkTypeDTO.getVideoUrl()); |
| | | duWorktype.setStatus2(Constants.ZERO); |
| | |
| | | @Override |
| | | public List<DispatchUnit> findByDTO(DispatchUnitQueryDTO dispatchUnitQueryDTO) { |
| | | LoginUserInfo loginUserInfo = (LoginUserInfo) SecurityUtils.getSubject().getPrincipal(); |
| | | // List<DispatchUnit> dispatchUnitList = dispatchUnitMapper.selectList(new QueryWrapper<DispatchUnit>().lambda() |
| | | // .eq(DispatchUnit::getIsdeleted,Constants.ZERO) |
| | | // .eq(loginUserInfo.getType().equals(Constants.ONE),DispatchUnit::getCompanyId,loginUserInfo.getCompanyId()) |
| | | // .eq(DispatchUnit::getStatus,Constants.ZERO) |
| | | // .eq(DispatchUnit::getDataType,dispatchUnitQueryDTO.getDataType()) |
| | | // .apply(!Objects.isNull(dispatchUnitQueryDTO.getSolutionId()), " id in ( select d.dispatch_unit_id from du_solution d where d.solution_id = "+dispatchUnitQueryDTO.getSolutionId()+" ) " ) |
| | | // .exists(!Objects.isNull(dispatchUnitQueryDTO.getApplyId()), |
| | | // " select 1 from apply_detail ad where ad.isdeleted = 0 and ad.apply_id = "+dispatchUnitQueryDTO.getApplyId()+" " + |
| | | // " ad.du_id = t.id ") |
| | | // .orderByAsc(DispatchUnit::getSortnum) |
| | | // ); |
| | | |
| | | |
| | | List<DispatchUnit> dispatchUnitList = dispatchUnitJoinMapper.selectJoinList(DispatchUnit.class, |
| | | new MPJLambdaWrapper<DispatchUnit>().selectAll(DispatchUnit.class) |
| | | .selectAs(DuSolution::getId,DispatchUnit::getDuSolutionId) |
| | |
| | | .eq(!Objects.isNull(dispatchUnitQueryDTO.getSolutionId()),DuSolution::getSolutionId,dispatchUnitQueryDTO.getSolutionId()) |
| | | .exists(!Objects.isNull(dispatchUnitQueryDTO.getApplyId()), |
| | | " select 1 from apply_detail ad where ad.isdeleted = 0 and ad.apply_id = "+dispatchUnitQueryDTO.getApplyId()+" " + |
| | | " ad.du_id = t.id ") |
| | | " and ad.du_id = t.id ") |
| | | ); |
| | | |
| | | |
| | | |
| | | return dispatchUnitList; |
| | | } |