| | |
| | | import com.ruoyi.common.utils.DateUtils; |
| | | import com.ruoyi.common.utils.StringUtils; |
| | | import com.ruoyi.common.utils.security.ShiroUtils; |
| | | import com.ruoyi.doublePrevention.entity.PreventRiskDangerInfo; |
| | | import com.ruoyi.doublePrevention.service.RiskService; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | |
| | | import com.ruoyi.project.tr.hiddenDangerCheckPoint.service.IHiddenDangerCheckPointService; |
| | | import com.ruoyi.project.tr.hiddenTroubleType.domain.HiddenTroubleType; |
| | | import com.ruoyi.project.tr.hiddenTroubleType.service.IHiddenTroubleTypeService; |
| | | import org.apache.commons.lang3.ObjectUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | |
| | | hiddenDangerCheckPoint.setJudgeQueryByUserIdList(userIdList);//隐患整改人ID 为登陆账号companyId下的userId的 |
| | | startPage(); |
| | | List<HiddenDangerCheckPoint> list = hiddenDangerCheckPointService.selectHiddenDangerCheckPointList(hiddenDangerCheckPoint); |
| | | |
| | | return getDataTable(list); |
| | | } |
| | | |
| | |
| | | // 第二:1.隐患上报创建人(register_user_id) 或者 2.(判定人(judge_user_id),report_status 不为null )------为本登录帐号userId的 |
| | | hiddenDangerCheckPoint.setJudgeQueryByUserId(getSysUser().getUserId()); |
| | | List<HiddenDangerCheckPoint> list = hiddenDangerCheckPointService.selectHiddenDangerCheckPointList(hiddenDangerCheckPoint); |
| | | return getDataTable(list); |
| | | List<HiddenDangerCheckPoint> resultList = new ArrayList<>(); |
| | | |
| | | for (HiddenDangerCheckPoint dangerCheckPoint : list) { |
| | | // todo-2022 修改前查询 |
| | | PreventRiskDangerInfo dangerInfo = riskService.getDangerInfoById(dangerCheckPoint.getId()); |
| | | if (ObjectUtils.isNotEmpty(dangerInfo)){ |
| | | dangerCheckPoint.setHazardCode(dangerInfo.getHazardCode()); |
| | | dangerCheckPoint.setDangerSrc(dangerInfo.getDangerSrc()); |
| | | dangerCheckPoint.setDangerReason(dangerInfo.getDangerReason()); |
| | | dangerCheckPoint.setHazardDangerType(dangerInfo.getHazardDangerType()); |
| | | dangerCheckPoint.setDangerResult(dangerInfo.getDangerResult()); |
| | | } |
| | | |
| | | resultList.add(dangerCheckPoint); |
| | | } |
| | | return getDataTable(resultList); |
| | | } |
| | | |
| | | /** |
| | |
| | | @GetMapping("/editDangerReport/{id}") |
| | | public String editDangerReport(@PathVariable("id") Long id, ModelMap mmap) { |
| | | HiddenDangerCheckPoint hdcp = hiddenDangerCheckPointService.selectHiddenDangerCheckPointById(id); |
| | | // todo-2022 修改前查询 |
| | | PreventRiskDangerInfo dangerInfo = riskService.getDangerInfoById(hdcp.getId()); |
| | | |
| | | hdcp.setHazardCode(dangerInfo.getHazardCode()); |
| | | hdcp.setDangerSrc(dangerInfo.getDangerSrc()); |
| | | hdcp.setDangerReason(dangerInfo.getDangerReason()); |
| | | hdcp.setHazardDangerType(dangerInfo.getHazardDangerType()); |
| | | hdcp.setDangerResult(dangerInfo.getDangerResult()); |
| | | |
| | | mmap.put("hiddenDangerCheckPoint", hdcp); |
| | | |
| | | //获取所在公司人员信息 |