| | |
| | | import com.dy.pmsGlobal.daoOth.OthFileMapper; |
| | | import com.dy.pmsGlobal.daoPlt.PltStationMapper; |
| | | import com.dy.pmsGlobal.daoPr.PrAssemblyPlanMapper; |
| | | import com.dy.pmsGlobal.daoPr.PrProductionNodeMapper; |
| | | import com.dy.pmsGlobal.daoPr.PrProductionProcessMapper; |
| | | import com.dy.pmsGlobal.daoPr.PrWorkingInstructionMapper; |
| | | import com.dy.pmsGlobal.daoSta.StaAssemblyWorkLastMapper; |
| | | import com.dy.pmsGlobal.dyFile.FileOperate; |
| | | import com.dy.pmsGlobal.dyFile.FileRestVo; |
| | | import com.dy.pmsGlobal.pojoBa.BaUser; |
| | | import com.dy.pmsGlobal.pojoOth.OthFile; |
| | | import com.dy.pmsGlobal.pojoPlt.PltProductionLine; |
| | | import com.dy.pmsGlobal.pojoPlt.PltStation; |
| | | import com.dy.pmsGlobal.pojoPr.PrAssemblyPlan; |
| | | import com.dy.pmsGlobal.pojoPr.PrProductionNode; |
| | | import com.dy.pmsGlobal.pojoPr.PrWorkingInstruction; |
| | | import com.dy.pmsGlobal.pojoSta.StaAssemblyWorkLast; |
| | | import lombok.extern.slf4j.Slf4j; |
| | |
| | | |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | import java.util.concurrent.atomic.AtomicLong; |
| | | import java.util.stream.Collectors; |
| | | |
| | | @Slf4j |
| | |
| | | BeanUtils.copyProperties(userStationList.get(0),result); |
| | | } |
| | | }else{ |
| | | result.setUserId(userInfo.getId()); |
| | | result.setUserName(userInfo.getName()); |
| | | result.setStationId(stationInfo.getId()); |
| | | result.setStationName(stationInfo.getName()); |
| | | result.setLineId(stationInfo.getLineId()); |
| | |
| | | params.setId(last.getPlanId()); |
| | | params.setProcessId(last.getProcessId()); |
| | | List<PrAssemblyPlan> planList = selectAssyPlanList(params); |
| | | planList.stream().forEach(process -> { |
| | | process.nodes.stream().filter(node -> node.id == last.getNodeId()); |
| | | }); |
| | | boolean hasNodeId= planList.stream() |
| | | .flatMap(process -> process.nodes.stream()) |
| | | .anyMatch(node -> node.id.equals(last.getNodeId())); |
| | | if(!hasNodeId){ |
| | | throw new RuntimeException("节点信息有误或被其他人员修改,请重新选择节点信息"); |
| | | } |
| | | last.setLineId(checkResult.getLineId()); |
| | | StaAssemblyWorkLast staLast = new StaAssemblyWorkLast(); |
| | | BeanUtils.copyProperties(last,staLast); |