| | |
| | | private IEamRepairOrderService iEamRepairOrderService; |
| | | @Autowired |
| | | private ISysBusinessCodeRuleService businessCodeRuleService; |
| | | @Autowired |
| | | private IEamReportThreeNoSpareService eamReportThreeNoSpareService; |
| | | /** |
| | | * 分页列表 |
| | | * |
| | |
| | | EamReportProductHazards eamReportProductHazards=new EamReportProductHazards(); |
| | | eamReportProductHazards.setEquipmentId(eamReportRepair.getEquipmentId()); |
| | | eamReportProductHazards.setReportId(eamReportRepair.getId()); |
| | | eamReportProductHazards.setDelFlag(Integer.valueOf(CommonConstant.DEFAULT_0)); |
| | | eamReportProductHazards.setConfirmStatus(EamReportProductHazardsEnum.PENDING_SUBMIT.name()); |
| | | iEamReportProductHazardsService.save(eamReportProductHazards); |
| | | } |
| | | if (StrUtil.isNotEmpty(eamReportRepair.getIsAccidentsRegister())&&("1").equals(eamReportRepair.getIsAccidentsRegister())) { |
| | | //添加设备事故登记表 |
| | | EamReportAccidentsRegister eamReportAccidentsRegister = new EamReportAccidentsRegister(); |
| | | BeanUtils.copyProperties(eamReportRepairRequest, eamReportAccidentsRegister); |
| | | eamReportAccidentsRegister.setId(null); |
| | | eamReportAccidentsRegister.setReportId(eamReportRepair.getId()); |
| | | eamReportAccidentsRegister.setDelFlag(Integer.valueOf(CommonConstant.DEFAULT_0)); |
| | | eamReportAccidentsRegister.setRegisterStatus(EamReportAccidentsRegisterEnum.PENDING_SUBMIT.name()); |
| | | iEamReportAccidentsRegisterService.save(eamReportAccidentsRegister); |
| | | //生成三不原则 |
| | | EamReportThreeNoSpare eamReportThreeNoSpare = new EamReportThreeNoSpare(); |
| | | BeanUtils.copyProperties(eamReportRepairRequest, eamReportThreeNoSpare); |
| | | eamReportThreeNoSpare.setId(null); |
| | | eamReportThreeNoSpare.setReportId(eamReportRepair.getId()); |
| | | eamReportThreeNoSpare.setPreventionMeasures(eamReportAccidentsRegister.getTakeSteps()); |
| | | eamReportThreeNoSpare.setSubmitStatus(EamReportThreeNoSpareEnum.PENDING_SUBMIT.name()); |
| | | eamReportThreeNoSpare.setDelFlag(Integer.valueOf(CommonConstant.DEFAULT_0)); |
| | | eamReportThreeNoSpareService.save(eamReportThreeNoSpare); |
| | | } |
| | | //生成维修工单,可能会有领取操作 |
| | | //生成维修工单 |
| | | EamRepairOrder eamRepairOrder=new EamRepairOrder(); |
| | | BeanUtils.copyProperties(eamReportRepairRequest, eamRepairOrder); |
| | | String codeSeq = businessCodeRuleService.generateBusinessCodeSeq(BusinessCodeConst.REPAIR_ORDER_CODE_RULE); |