| | |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.ruoyi.doublePrevention.vo.ResultVO; |
| | | import com.ruoyi.project.tr.riskList.domain.*; |
| | | |
| | | /** |
| | |
| | | RiskList getInfoByRiskListName(String riskListName); |
| | | |
| | | List<RiskList> getAllPlan(int riskType); |
| | | |
| | | ResultVO<List<RiskList>> listHazardSource(); |
| | | |
| | | RiskList getInfoByRiskListNum(String hazardCode); |
| | | } |
| | |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.ruoyi.doublePrevention.vo.ResultVO; |
| | | import com.ruoyi.project.tr.riskList.domain.*; |
| | | |
| | | /** |
| | |
| | | RiskList getInfoByRiskListName(String riskListName); |
| | | |
| | | List<RiskList> getAllPlan(); |
| | | |
| | | ResultVO<List<RiskList>> listHazardSource(); |
| | | |
| | | RiskList getInfoByRiskListNum(String hazardCode); |
| | | } |
| | |
| | | |
| | | import com.ruoyi.common.utils.DateUtils; |
| | | import com.ruoyi.common.utils.text.Convert; |
| | | import com.ruoyi.doublePrevention.vo.ResultVO; |
| | | import com.ruoyi.project.tr.riskCheckPoint.mapper.RiskCheckPointMapper; |
| | | import com.ruoyi.project.tr.riskEvaluationPlan.mapper.RiskEvaluationPlanMapper; |
| | | import com.ruoyi.project.tr.riskList.domain.*; |
| | |
| | | int riskType =5; |
| | | return riskListMapper.getAllPlan(riskType); |
| | | } |
| | | |
| | | @Override |
| | | public ResultVO<List<RiskList>> listHazardSource() { |
| | | return riskListMapper.listHazardSource(); |
| | | } |
| | | |
| | | @Override |
| | | public RiskList getInfoByRiskListNum(String hazardCode) { |
| | | return riskListMapper.getInfoByRiskListNum(hazardCode); |
| | | } |
| | | } |
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.Test;
|
| | |
|
| | | import com.alibaba.fastjson.JSON;
|
| | | import com.alibaba.fastjson.JSONArray;
|
| | | import com.alibaba.fastjson.JSONObject;
|
| | | import com.ruoyi.common.utils.BeanCopyUtils;
|
| | | import com.ruoyi.doublePrevention.entity.CJReport.CJdto.CJReportResultData;
|
| | | import com.ruoyi.doublePrevention.entity.CJReport.CJdto.Data;
|
| | | import com.ruoyi.doublePrevention.entity.CJReport.CJdto.ErrorMsgDetails;
|
| | | import com.ruoyi.doublePrevention.enums.CJReportEnum;
|
| | | import com.ruoyi.doublePrevention.enums.SyncEnum;
|
| | | import com.ruoyi.project.tr.riskList.service.IRiskListService;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.HandlerSpecialCheckReportParam;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.DTO.SpecialCheckItemDangerLogReportDTO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.DTO.SpecialCheckTaskLogReportDTO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog;
|
| | | import com.ruoyi.project.tr.specialCheck.mapper.*;
|
| | | import org.apache.commons.lang3.ObjectUtils;
|
| | | import org.bouncycastle.crypto.engines.AESFastEngine;
|
| | | import org.bouncycastle.crypto.modes.GCMBlockCipher;
|
| | | import org.bouncycastle.crypto.params.AEADParameters;
|
| | | import org.bouncycastle.crypto.params.KeyParameter;
|
| | | import org.slf4j.Logger;
|
| | | import org.slf4j.LoggerFactory;
|
| | | import org.springframework.beans.factory.annotation.Autowired;
|
| | | import org.springframework.scheduling.annotation.Scheduled;
|
| | | import org.springframework.stereotype.Component;
|
| | | import org.springframework.transaction.annotation.Transactional;
|
| | |
|
| | | import java.io.*;
|
| | | import java.net.HttpURLConnection;
|
| | | import java.net.URL;
|
| | | import java.nio.charset.StandardCharsets;
|
| | | import java.text.SimpleDateFormat;
|
| | | import java.time.LocalDateTime;
|
| | | import java.time.format.DateTimeFormatter;
|
| | | import java.util.*;
|
| | |
|
| | | @Component
|
| | | public class ItemDangerReportScheduleTest {
|
| | |
|
| | | private final Logger logger = LoggerFactory.getLogger(this.getClass());
|
| | |
|
| | | @Autowired
|
| | | private TbSpecialCheckItemDangerLogMapper itemDangerLogMapper;
|
| | |
|
| | | String token = "GT6gGJV7JV";
|
| | | String key = "Bv+NeBolwqg2Pbc1yVwrZA==";
|
| | | String iv = "4QC9V8eAiB7tdlgBkMsTAw==";
|
| | |
|
| | | public static final int MAC_BIT_SIZE = 128;
|
| | |
|
| | | public static String encrypt(String plainText, byte[] key, byte[] iv) {
|
| | | String sr;
|
| | | try {
|
| | | byte[] plainBytes = plainText.getBytes(StandardCharsets.UTF_8);
|
| | | GCMBlockCipher cipher = new GCMBlockCipher(new
|
| | | AESFastEngine());
|
| | | AEADParameters parameters =
|
| | | new AEADParameters(new KeyParameter(key),
|
| | | MAC_BIT_SIZE, iv, null);
|
| | | cipher.init(true, parameters);
|
| | | byte[] encryptedBytes = new
|
| | | byte[cipher.getOutputSize(plainBytes.length)];
|
| | | int retLen = cipher.processBytes(plainBytes, 0, plainBytes.length,
|
| | | encryptedBytes, 0);
|
| | | cipher.doFinal(encryptedBytes, retLen);
|
| | | sr = Base64.getEncoder().encodeToString(encryptedBytes);
|
| | | } catch (Exception ex) {
|
| | | throw new RuntimeException(ex.getMessage());
|
| | | }
|
| | | return sr;
|
| | | }
|
| | |
|
| | |
|
| | | @Transactional
|
| | | // @Scheduled(cron = "0 0 23 * * ?") //每天晚上23点执行一次0 0 22,23 * * ?
|
| | | // @Scheduled(cron = "0 0 22,23 * * ?") //每天晚上22、23点执行一次
|
| | | // @Scheduled(cron = "0 0/1 * * * ? ") // 分钟
|
| | | // @Scheduled(cron = "0 0/20 * * * ? ") // 分钟
|
| | | // @Scheduled(cron = "0/5 * * * * ?")
|
| | | public void execReportDateSchedule() throws UnsupportedEncodingException {
|
| | | logger.info("【####】上报数据开始...");
|
| | |
|
| | | HttpURLConnection con = null;
|
| | | BufferedReader buffer = null;
|
| | | int responseCode = 200;
|
| | |
|
| | | // SimpleDateFormat dateFormatCheckData= new SimpleDateFormat("yyyy-MM-dd");
|
| | | // SimpleDateFormat dateFormat= new SimpleDateFormat("yyyy-MM-dd HH:MM:ss");
|
| | | DateTimeFormatter dateFormatCheckData = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
| | | DateTimeFormatter dateFormat = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:MM:ss");
|
| | |
|
| | | Date date = new Date();
|
| | | //格式化时间,作为token的时间戳
|
| | | SimpleDateFormat tokenDate= new SimpleDateFormat("yyyyMMddHHmmssSSS");
|
| | | String formatDate = tokenDate.format(date);
|
| | |
|
| | | logger.info("【token时间】" + formatDate);
|
| | |
|
| | | /**
|
| | | * 1、检查项与隐患上报
|
| | | * */
|
| | | System.out.println("【2】检查项与隐患上报-处理数据...");
|
| | | // List<TbSpecialCheckTaskLog> CJRiskAnaUnits = .listReportUnitDate();
|
| | | List<TbSpecialCheckItemDangerLog> itemDangerLogLists = itemDangerLogMapper.listItemDangerReportTask();
|
| | | if (ObjectUtils.isNotEmpty(itemDangerLogLists)){
|
| | | //封装上报数据,时间格式化
|
| | | List<SpecialCheckItemDangerLogReportDTO> list = new ArrayList<>();
|
| | |
|
| | | for (TbSpecialCheckItemDangerLog itemDangerLog : itemDangerLogLists) {
|
| | | SpecialCheckItemDangerLogReportDTO specialCheckItemDangerLogReportDTO = BeanCopyUtils.copyBean(itemDangerLog, SpecialCheckItemDangerLogReportDTO.class);
|
| | | specialCheckItemDangerLogReportDTO.setCreateDate(dateFormat.format(itemDangerLog.getCreateDate()));
|
| | | specialCheckItemDangerLogReportDTO.setUpdateDate(dateFormat.format(itemDangerLog.getUpdateDate()));
|
| | | specialCheckItemDangerLogReportDTO.setCheckDate(dateFormatCheckData.format(itemDangerLog.getCheckDate()));
|
| | | specialCheckItemDangerLogReportDTO.setDeleted(itemDangerLog.getDeleted().toString());
|
| | | list.add(specialCheckItemDangerLogReportDTO);
|
| | | }
|
| | | // logger.info("【【原始数据】】" + JSONObject.toJSONString(list));
|
| | | System.out.println("【【原始数据】】" + JSONObject.toJSONString(list));
|
| | | String AESReportUnitDate = encrypt(JSONObject.toJSONString(list), key.getBytes(), iv.getBytes());
|
| | | // logger.info("【【AES加密结果】】"+ AESReportUnitDate);{0JRK`$6X.jpg)min/Desktop/所有桌面文件存放/9}AM56M10$6WX){0JRK`$6X.jpg)
|
| | | StringBuffer itemDangerResultBuffer = null;
|
| | |
|
| | |
|
| | | //上报数据
|
| | | try {
|
| | | URL url = new URL("http://120.71.182.198:9999/v1/data/receive/receiveCheckDangerList");
|
| | | //得到连接对象
|
| | | con = (HttpURLConnection) url.openConnection();
|
| | | //设置请求类型
|
| | | con.setRequestMethod("POST");
|
| | | //允许写出
|
| | | con.setDoOutput(true);
|
| | | //允许读入
|
| | | con.setDoInput(true);
|
| | | //不使用缓存
|
| | | con.setUseCaches(false);
|
| | | con.setInstanceFollowRedirects(true);
|
| | | //设置请求头
|
| | | con.setRequestProperty("X-Access-Token",token+formatDate.toString());
|
| | | //设置Content-Type,此处根据实际情况确定
|
| | | con.setRequestProperty("Content-Type", "application/json;charset=utf8");
|
| | |
|
| | | OutputStream os = con.getOutputStream();
|
| | | Map paraMap = new HashMap();
|
| | | paraMap.put("data", AESReportUnitDate); /**封装数据*/
|
| | | System.out.println("【【加密请求体】】" + JSONArray.toJSON(paraMap).toString());
|
| | | //组装入参,设置请求体
|
| | | os.write(JSON.toJSONString(paraMap).getBytes());
|
| | |
|
| | | //本段日志,测试成功后,可注释掉
|
| | | if (responseCode == HttpURLConnection.HTTP_OK) {
|
| | | //得到响应流
|
| | | InputStream inputStream = con.getInputStream();
|
| | | //将响应流转换成字符串
|
| | | itemDangerResultBuffer = new StringBuffer();
|
| | | String line;
|
| | | buffer = new BufferedReader(new InputStreamReader(inputStream, "UTF-8"));
|
| | | while ((line = buffer.readLine()) != null) {
|
| | | itemDangerResultBuffer.append(line);
|
| | | }
|
| | | // logger.info("result:" + unitResultBuffer.toString());
|
| | | System.out.println("result:" + itemDangerResultBuffer.toString());
|
| | | }
|
| | |
|
| | | } catch (Exception e) {
|
| | | e.printStackTrace();
|
| | | }
|
| | |
|
| | | //接收返回值,保存返回值
|
| | | CJReportResultData CJOverhaulLogResult = JSONObject.parseObject(itemDangerResultBuffer.toString(), CJReportResultData.class);
|
| | | //接收返回值,保存返回值
|
| | | List<String> errorIdList= new ArrayList<>();
|
| | | Data data = JSONObject.parseObject(CJOverhaulLogResult.getData(), Data.class);
|
| | | //保存失败结果
|
| | | if (ObjectUtils.isNotEmpty(data)){
|
| | | for (ErrorMsgDetails errorMsgDetail : data.getErrorMsgDetails()) {
|
| | | errorIdList.add(errorMsgDetail.getId());
|
| | | }
|
| | | }
|
| | | LocalDateTime nowDate = LocalDateTime.now();
|
| | | logger.info("【检查项与隐患】数据上报结果:" + CJOverhaulLogResult.getCode());
|
| | | //设置所有数据上报成功
|
| | | if (CJOverhaulLogResult.getCode().equals(CJReportEnum.SUCCESS.getCode()) || CJOverhaulLogResult.getCode().equals(CJReportEnum.SUCESS_AND_FAIL.getCode())){
|
| | | for (TbSpecialCheckItemDangerLog itemDangerLo : itemDangerLogLists) {
|
| | | HandlerSpecialCheckReportParam handlerCJReportParam = new HandlerSpecialCheckReportParam();
|
| | | //封装数据
|
| | | handlerCJReportParam.setId(itemDangerLo.getId());
|
| | | handlerCJReportParam.setReportStatus(SyncEnum.SYNC_EXEC_SUCCESS.getCode());
|
| | | handlerCJReportParam.setReportTime(nowDate);
|
| | | itemDangerLogMapper.updateItemDangerReportStatusById(handlerCJReportParam);
|
| | | }
|
| | | }
|
| | | //设置上报失败的数据,上报失败
|
| | | if (CJOverhaulLogResult.getCode().equals(CJReportEnum.FAIL.getCode()) || CJOverhaulLogResult.getCode().equals(CJReportEnum.SUCESS_AND_FAIL.getCode())){
|
| | | for (String failId : errorIdList) {
|
| | | //上报失败
|
| | | HandlerSpecialCheckReportParam handlerCJReportParam = new HandlerSpecialCheckReportParam();
|
| | | //封装数据
|
| | | handlerCJReportParam.setId(failId);
|
| | | handlerCJReportParam.setReportStatus(SyncEnum.SYNC_EXEC_FAIL.getCode());
|
| | | handlerCJReportParam.setReportTime(nowDate);
|
| | | itemDangerLogMapper.updateItemDangerReportStatusById(handlerCJReportParam);
|
| | | }
|
| | | }
|
| | |
|
| | |
|
| | |
|
| | |
|
| | | // logger.info("【1】安全风险分析单元-数据处理完成");
|
| | | System.out.println("【检查项与隐患】-数据处理完成");
|
| | | }else {
|
| | | // logger.info("【1】风险分析单元-无数据上报昌吉州");
|
| | | System.out.println("【检查项与隐患】-无数据上报昌吉州");
|
| | | }
|
| | |
|
| | |
|
| | |
|
| | | }
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.Test;
|
| | |
|
| | | import com.alibaba.fastjson.JSON;
|
| | | import com.alibaba.fastjson.JSONArray;
|
| | | import com.alibaba.fastjson.JSONObject;
|
| | | import com.ruoyi.common.utils.BeanCopyUtils;
|
| | | import com.ruoyi.doublePrevention.entity.CJReport.CJdto.CJReportResultData;
|
| | | import com.ruoyi.doublePrevention.entity.CJReport.CJdto.Data;
|
| | | import com.ruoyi.doublePrevention.entity.CJReport.CJdto.ErrorMsgDetails;
|
| | | import com.ruoyi.doublePrevention.entity.CJReport.CJdto.HandlerDO.*;
|
| | | import com.ruoyi.doublePrevention.entity.CJReport.*;
|
| | | import com.ruoyi.doublePrevention.entity.PreventReportConfig;
|
| | | import com.ruoyi.doublePrevention.enums.CJReportEnum;
|
| | | import com.ruoyi.doublePrevention.enums.SyncEnum;
|
| | | import com.ruoyi.doublePrevention.repository.param.HandlerCJReportParam;
|
| | | import com.ruoyi.doublePrevention.service.baseService.*;
|
| | | import com.ruoyi.project.tr.report.service.ReportService;
|
| | | import com.ruoyi.project.tr.riskList.service.IRiskListService;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.HandlerSpecialCheckReportParam;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.DTO.SpecialCheckTaskLogReportDTO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog;
|
| | | import com.ruoyi.project.tr.specialCheck.mapper.*;
|
| | | import org.apache.commons.lang3.ObjectUtils;
|
| | | import org.bouncycastle.crypto.engines.AESFastEngine;
|
| | | import org.bouncycastle.crypto.modes.GCMBlockCipher;
|
| | | import org.bouncycastle.crypto.params.AEADParameters;
|
| | | import org.bouncycastle.crypto.params.KeyParameter;
|
| | | import org.slf4j.Logger;
|
| | | import org.slf4j.LoggerFactory;
|
| | | import org.springframework.beans.factory.annotation.Autowired;
|
| | | import org.springframework.format.annotation.DateTimeFormat;
|
| | | import org.springframework.scheduling.annotation.Scheduled;
|
| | | import org.springframework.stereotype.Component;
|
| | | import org.springframework.transaction.annotation.Transactional;
|
| | |
|
| | | import java.io.*;
|
| | | import java.net.HttpURLConnection;
|
| | | import java.net.URL;
|
| | | import java.nio.charset.StandardCharsets;
|
| | | import java.text.SimpleDateFormat;
|
| | | import java.time.LocalDateTime;
|
| | | import java.time.format.DateTimeFormatter;
|
| | | import java.util.*;
|
| | |
|
| | | @Component
|
| | | public class TaskReportScheduleTest {
|
| | |
|
| | | private final Logger logger = LoggerFactory.getLogger(this.getClass());
|
| | |
|
| | | @Autowired
|
| | | private TbBaseCheckCompanyMapper companyTbRepository;
|
| | | @Autowired
|
| | | private TbBaseCheckItemMapper itemTbRepository;
|
| | | @Autowired
|
| | | private TbBaseCheckScoreMapper scoreTbRepository;
|
| | | @Autowired
|
| | | private TbBaseCheckTaskMapper taskTbRepository;
|
| | | @Autowired
|
| | | private TbSpecialCheckTaskLogMapper taskSpecialLogMapper;
|
| | | @Autowired
|
| | | private IRiskListService riskListService;
|
| | |
|
| | | String token = "GT6gGJV7JV";
|
| | | String key = "Bv+NeBolwqg2Pbc1yVwrZA==";
|
| | | String iv = "4QC9V8eAiB7tdlgBkMsTAw==";
|
| | |
|
| | | public static final int MAC_BIT_SIZE = 128;
|
| | |
|
| | | public static String encrypt(String plainText, byte[] key, byte[] iv) {
|
| | | String sr;
|
| | | try {
|
| | | byte[] plainBytes = plainText.getBytes(StandardCharsets.UTF_8);
|
| | | GCMBlockCipher cipher = new GCMBlockCipher(new
|
| | | AESFastEngine());
|
| | | AEADParameters parameters =
|
| | | new AEADParameters(new KeyParameter(key),
|
| | | MAC_BIT_SIZE, iv, null);
|
| | | cipher.init(true, parameters);
|
| | | byte[] encryptedBytes = new
|
| | | byte[cipher.getOutputSize(plainBytes.length)];
|
| | | int retLen = cipher.processBytes(plainBytes, 0, plainBytes.length,
|
| | | encryptedBytes, 0);
|
| | | cipher.doFinal(encryptedBytes, retLen);
|
| | | sr = Base64.getEncoder().encodeToString(encryptedBytes);
|
| | | } catch (Exception ex) {
|
| | | throw new RuntimeException(ex.getMessage());
|
| | | }
|
| | | return sr;
|
| | | }
|
| | |
|
| | |
|
| | | @Transactional
|
| | | // @Scheduled(cron = "0 0 23 * * ?") //每天晚上23点执行一次0 0 22,23 * * ?
|
| | | // @Scheduled(cron = "0 0 22,23 * * ?") //每天晚上22、23点执行一次
|
| | | // @Scheduled(cron = "0 0/1 * * * ? ") // 分钟
|
| | | // @Scheduled(cron = "0 0/20 * * * ? ") // 分钟
|
| | | // @Scheduled(cron = "0/5 * * * * ?")
|
| | | public void execReportDateSchedule() throws UnsupportedEncodingException {
|
| | | logger.info("【####】上报数据开始...");
|
| | |
|
| | | HttpURLConnection con = null;
|
| | | BufferedReader buffer = null;
|
| | | int responseCode = 200;
|
| | |
|
| | | // SimpleDateFormat dateFormatCheckData= new SimpleDateFormat("yyyy-MM-dd");
|
| | | // SimpleDateFormat dateFormat= new SimpleDateFormat("yyyy-MM-dd HH:MM:ss");
|
| | | DateTimeFormatter dateFormatCheckData = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
| | | DateTimeFormatter dateFormat = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:MM:ss");
|
| | |
|
| | | Date date = new Date();
|
| | | //格式化时间,作为token的时间戳
|
| | | SimpleDateFormat tokenDate= new SimpleDateFormat("yyyyMMddHHmmssSSS");
|
| | | String formatDate = tokenDate.format(date);
|
| | |
|
| | | logger.info("【token时间】" + formatDate);
|
| | |
|
| | | /**
|
| | | * 1、任务上报
|
| | | * */
|
| | | System.out.println("【1】任务上报-处理数据...");
|
| | | // List<TbSpecialCheckTaskLog> CJRiskAnaUnits = .listReportUnitDate();
|
| | | List<TbSpecialCheckTaskLog> taskLogLists = taskSpecialLogMapper.listTestReportTask();
|
| | | if (ObjectUtils.isNotEmpty(taskLogLists)){
|
| | | //封装上报数据,时间格式化
|
| | | List<SpecialCheckTaskLogReportDTO> list = new ArrayList<>();
|
| | |
|
| | | for (TbSpecialCheckTaskLog taskLog : taskLogLists) {
|
| | | SpecialCheckTaskLogReportDTO specialTaskLogReportDTO = BeanCopyUtils.copyBean(taskLog, SpecialCheckTaskLogReportDTO.class);
|
| | | specialTaskLogReportDTO.setCreateDate(dateFormat.format(taskLog.getCreateDate()));
|
| | | specialTaskLogReportDTO.setUpdateDate(dateFormat.format(taskLog.getUpdateDate()));
|
| | | specialTaskLogReportDTO.setCheckDate(dateFormatCheckData.format(taskLog.getCheckDate()));
|
| | | list.add(specialTaskLogReportDTO);
|
| | | }
|
| | | // logger.info("【【原始数据】】" + JSONObject.toJSONString(list));
|
| | | System.out.println("【【原始数据】】" + JSONObject.toJSONString(list));
|
| | | String AESReportUnitDate = encrypt(JSONObject.toJSONString(list), key.getBytes(), iv.getBytes());
|
| | | // logger.info("【【AES加密结果】】"+ AESReportUnitDate);{0JRK`$6X.jpg)min/Desktop/所有桌面文件存放/9}AM56M10$6WX){0JRK`$6X.jpg)
|
| | | StringBuffer checkTaskResultBuffer = null;
|
| | |
|
| | |
|
| | | //上报数据
|
| | | try {
|
| | | URL url = new URL("http://120.71.182.198:9999/v1/data/receive/receiveCheckRecordList");
|
| | | //得到连接对象
|
| | | con = (HttpURLConnection) url.openConnection();
|
| | | //设置请求类型
|
| | | con.setRequestMethod("POST");
|
| | | //允许写出
|
| | | con.setDoOutput(true);
|
| | | //允许读入
|
| | | con.setDoInput(true);
|
| | | //不使用缓存
|
| | | con.setUseCaches(false);
|
| | | con.setInstanceFollowRedirects(true);
|
| | | //设置请求头
|
| | | con.setRequestProperty("X-Access-Token",token+formatDate.toString());
|
| | | //设置Content-Type,此处根据实际情况确定
|
| | | con.setRequestProperty("Content-Type", "application/json;charset=utf8");
|
| | |
|
| | | OutputStream os = con.getOutputStream();
|
| | | Map paraMap = new HashMap();
|
| | | paraMap.put("data", AESReportUnitDate); /**封装数据*/
|
| | | System.out.println("【【加密请求体】】" + JSONArray.toJSON(paraMap).toString());
|
| | | //组装入参,设置请求体
|
| | | os.write(JSON.toJSONString(paraMap).getBytes());
|
| | |
|
| | | //本段日志,测试成功后,可注释掉
|
| | | if (responseCode == HttpURLConnection.HTTP_OK) {
|
| | | //得到响应流
|
| | | InputStream inputStream = con.getInputStream();
|
| | | //将响应流转换成字符串
|
| | | checkTaskResultBuffer = new StringBuffer();
|
| | | String line;
|
| | | buffer = new BufferedReader(new InputStreamReader(inputStream, "UTF-8"));
|
| | | while ((line = buffer.readLine()) != null) {
|
| | | checkTaskResultBuffer.append(line);
|
| | | }
|
| | | // logger.info("result:" + unitResultBuffer.toString());
|
| | | System.out.println("result:" + checkTaskResultBuffer.toString());
|
| | | }
|
| | |
|
| | | } catch (Exception e) {
|
| | | e.printStackTrace();
|
| | | }
|
| | |
|
| | |
|
| | | //接收返回值,保存返回值
|
| | | CJReportResultData CJOverhaulLogResult = JSONObject.parseObject(checkTaskResultBuffer.toString(), CJReportResultData.class);
|
| | | //接收返回值,保存返回值
|
| | | List<String> errorIdList= new ArrayList<>();
|
| | | Data data = JSONObject.parseObject(CJOverhaulLogResult.getData(), Data.class);
|
| | | //保存失败结果
|
| | | if (ObjectUtils.isNotEmpty(data)){
|
| | | for (ErrorMsgDetails errorMsgDetail : data.getErrorMsgDetails()) {
|
| | | errorIdList.add(errorMsgDetail.getId());
|
| | | }
|
| | | }
|
| | | LocalDateTime nowDate = LocalDateTime.now();
|
| | | logger.info("【任务】数据上报结果:" + CJOverhaulLogResult.getCode());
|
| | | //设置所有数据上报成功
|
| | | if (CJOverhaulLogResult.getCode().equals(CJReportEnum.SUCCESS.getCode()) || CJOverhaulLogResult.getCode().equals(CJReportEnum.SUCESS_AND_FAIL.getCode())){
|
| | | for (TbSpecialCheckTaskLog taskLog : taskLogLists) {
|
| | | HandlerSpecialCheckReportParam handlerCJReportParam = new HandlerSpecialCheckReportParam();
|
| | | //封装数据
|
| | | handlerCJReportParam.setId(taskLog.getId());
|
| | | handlerCJReportParam.setReportStatus(SyncEnum.SYNC_EXEC_SUCCESS.getCode());
|
| | | handlerCJReportParam.setReportTime(nowDate);
|
| | | taskSpecialLogMapper.updateCheckTaskReportStatusById(handlerCJReportParam);
|
| | | }
|
| | | }
|
| | | //设置上报失败的数据,上报失败
|
| | | if (CJOverhaulLogResult.getCode().equals(CJReportEnum.FAIL.getCode()) || CJOverhaulLogResult.getCode().equals(CJReportEnum.SUCESS_AND_FAIL.getCode())){
|
| | | for (String failId : errorIdList) {
|
| | | //上报失败
|
| | | HandlerSpecialCheckReportParam handlerCJReportParam = new HandlerSpecialCheckReportParam();
|
| | | //封装数据
|
| | | handlerCJReportParam.setId(failId);
|
| | | handlerCJReportParam.setReportStatus(SyncEnum.SYNC_EXEC_FAIL.getCode());
|
| | | handlerCJReportParam.setReportTime(nowDate);
|
| | | taskSpecialLogMapper.updateCheckTaskReportStatusById(handlerCJReportParam);
|
| | | }
|
| | | }
|
| | |
|
| | |
|
| | |
|
| | | // logger.info("【1】安全风险分析单元-数据处理完成");
|
| | | System.out.println("【任务】-数据处理完成");
|
| | | }else {
|
| | | // logger.info("【1】风险分析单元-无数据上报昌吉州");
|
| | | System.out.println("【任务】-无数据上报昌吉州");
|
| | | }
|
| | |
|
| | |
|
| | |
|
| | | }
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.controller; |
| | | |
| | | import com.ruoyi.doublePrevention.vo.ResultVO; |
| | | import com.ruoyi.framework.web.controller.BaseController; |
| | | import com.ruoyi.framework.web.page.TableDataInfo; |
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckItemBO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.DTO.TbBaseCheckItemDTO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckItem; |
| | | import com.ruoyi.project.tr.specialCheck.service.TbBaseCheckService; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.ui.ModelMap; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * 隐患列表Controller |
| | | * |
| | | * @date 2020-05-08 |
| | | */ |
| | | @Controller |
| | | @RequestMapping("/tr/tbBaseCheckItem") |
| | | public class TBBaseCheckItemController extends BaseController |
| | | { |
| | | private String prefix = "tr/selectTbBaseCheckItemPage"; |
| | | |
| | | @Autowired |
| | | private TbBaseCheckService tbBaseCheckService; |
| | | |
| | | |
| | | |
| | | @GetMapping() |
| | | public String selectTbBaseCheckTaskPage(ModelMap mmap) |
| | | { |
| | | return prefix + "/selectTbBaseCheckItemPage"; |
| | | } |
| | | |
| | | |
| | | |
| | | @PostMapping("/selectTbBaseCheckItemPage") |
| | | @ResponseBody |
| | | public TableDataInfo selectTbBaseCheckItemPage(@RequestBody TbBaseCheckItemBO tbBaseCheckItemBO) |
| | | { |
| | | |
| | | ResultVO<List<TbBaseCheckItem>> resultVO = tbBaseCheckService.selectTbBaseCheckItemPage(tbBaseCheckItemBO); |
| | | List<TbBaseCheckItemDTO> data = (List<TbBaseCheckItemDTO>) resultVO.getData(); |
| | | TableDataInfo dataTable = getDataTable(data); |
| | | dataTable.setTotal(resultVO.getCount()); |
| | | |
| | | return dataTable; |
| | | } |
| | | |
| | | } |
| | | |
| | | |
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.controller; |
| | | |
| | | import com.ruoyi.doublePrevention.vo.ResultVO; |
| | | import com.ruoyi.framework.web.controller.BaseController; |
| | | import com.ruoyi.framework.web.page.TableDataInfo; |
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckScoreBO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.DTO.TbBaseCheckScoreDTO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckScore; |
| | | import com.ruoyi.project.tr.specialCheck.service.TbBaseCheckService; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.ui.ModelMap; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * 隐患列表Controller |
| | | * |
| | | * @date 2020-05-08 |
| | | */ |
| | | @Controller |
| | | @RequestMapping("/tr/tbBaseCheckScore") |
| | | public class TBBaseCheckScoreController extends BaseController |
| | | { |
| | | private String prefix = "tr/selectTbBaseCheckScorePage"; |
| | | |
| | | @Autowired |
| | | private TbBaseCheckService tbBaseCheckService; |
| | | |
| | | |
| | | |
| | | @GetMapping() |
| | | public String selectTbBaseCheckTaskPage(ModelMap mmap) |
| | | { |
| | | return prefix + "/selectTbBaseCheckScorePage"; |
| | | } |
| | | |
| | | |
| | | |
| | | @PostMapping("/selectTbBaseCheckScorePage") |
| | | @ResponseBody |
| | | public TableDataInfo selectTbBaseCheckScorePage(@RequestBody TbBaseCheckScoreBO tbBaseCheckScoreBO) |
| | | { |
| | | |
| | | ResultVO<List<TbBaseCheckScore>> resultVO = tbBaseCheckService.selectTbBaseCheckScorePage(tbBaseCheckScoreBO); |
| | | List<TbBaseCheckScoreDTO> data = (List<TbBaseCheckScoreDTO>) resultVO.getData(); |
| | | TableDataInfo dataTable = getDataTable(data); |
| | | dataTable.setTotal(resultVO.getCount()); |
| | | |
| | | return dataTable; |
| | | } |
| | | |
| | | } |
| | | |
| | | |
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.controller; |
| | | |
| | | import com.ruoyi.doublePrevention.vo.ResultVO; |
| | | import com.ruoyi.framework.web.controller.BaseController; |
| | | import com.ruoyi.framework.web.page.TableDataInfo; |
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckTaskBO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.DTO.TbBaseCheckTaskDTO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckTask; |
| | | import com.ruoyi.project.tr.specialCheck.service.TbBaseCheckService; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.ui.ModelMap; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * 隐患列表Controller |
| | | * |
| | | * @date 2020-05-08 |
| | | */ |
| | | @Controller |
| | | @RequestMapping("/tr/tbBaseCheckTask") |
| | | public class TBBaseCheckTaskController extends BaseController |
| | | { |
| | | private String prefix = "tr/selectTbBaseCheckTaskPage"; |
| | | |
| | | @Autowired |
| | | private TbBaseCheckService tbBaseCheckService; |
| | | |
| | | |
| | | |
| | | @GetMapping() |
| | | public String selectTbBaseCheckTaskPage(ModelMap mmap) |
| | | { |
| | | return prefix + "/selectTbBaseCheckTaskPage"; |
| | | } |
| | | |
| | | |
| | | |
| | | @PostMapping("/selectTbBaseCheckTaskPage") |
| | | @ResponseBody |
| | | public TableDataInfo selectTbBaseCheckTaskPage(@RequestBody TbBaseCheckTaskBO tbBaseCheckTaskBO) |
| | | { |
| | | |
| | | ResultVO<List<TbBaseCheckTask>> resultVO = tbBaseCheckService.selectTbBaseCheckTaskPage(tbBaseCheckTaskBO); |
| | | List<TbBaseCheckTaskDTO> data = (List<TbBaseCheckTaskDTO>) resultVO.getData(); |
| | | TableDataInfo dataTable = getDataTable(data); |
| | | dataTable.setTotal(resultVO.getCount()); |
| | | |
| | | return dataTable; |
| | | } |
| | | |
| | | } |
| | | |
| | | |
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.controller; |
| | | |
| | | import com.ruoyi.doublePrevention.vo.ResultVO; |
| | | import com.ruoyi.framework.web.controller.BaseController; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.framework.web.page.TableDataInfo; |
| | | import com.ruoyi.project.tr.riskList.domain.RiskList; |
| | | import com.ruoyi.project.tr.riskList.service.IRiskListService; |
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.*; |
| | | import com.ruoyi.project.tr.specialCheck.domin.DTO.TbSpecialCheckItemDangerLogDTO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.DTO.TbSpecialCheckTaskLogDTO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckTask; |
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog; |
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog; |
| | | import com.ruoyi.project.tr.specialCheck.service.SpecialCheckItemDangerLogService; |
| | | import com.ruoyi.project.tr.specialCheck.service.SpecialCheckTaskService; |
| | | import com.ruoyi.project.tr.specialCheck.service.TbBaseCheckService; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.ui.ModelMap; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * 隐患列表Controller |
| | | * |
| | | * @date 2020-05-08 |
| | | */ |
| | | @Controller |
| | | @RequestMapping("/tr/specialCheckItemDangerLog") |
| | | public class TBSpecialCheckItemDangerLogController extends BaseController |
| | | { |
| | | private String prefix = "tr/specialCheckItemDangerLog"; |
| | | |
| | | @Autowired |
| | | private SpecialCheckItemDangerLogService itemDangerLogService; |
| | | |
| | | @Autowired |
| | | private IRiskListService riskListService; |
| | | |
| | | @Autowired |
| | | private TbBaseCheckService tbBaseCheckService; |
| | | |
| | | |
| | | |
| | | @GetMapping() |
| | | public String selectTbBaseCheckTaskPage(ModelMap mmap) |
| | | { |
| | | return prefix + "/specialCheckItemDangerLog"; |
| | | } |
| | | |
| | | |
| | | |
| | | @PostMapping("/list") |
| | | @ResponseBody |
| | | public TableDataInfo selectSpecialCheckItemDangerLogPage(@RequestBody TbSpecialCheckItemDangerLogBO itemDangerLogBO ) |
| | | { |
| | | |
| | | ResultVO<List<TbSpecialCheckItemDangerLog>> resultVO = itemDangerLogService.selectSpecialCheckItemDangerLogPage(itemDangerLogBO); |
| | | List<TbSpecialCheckItemDangerLogDTO> data = (List<TbSpecialCheckItemDangerLogDTO>) resultVO.getData(); |
| | | TableDataInfo dataTable = getDataTable(data); |
| | | dataTable.setTotal(resultVO.getCount()); |
| | | |
| | | return dataTable; |
| | | } |
| | | |
| | | /** |
| | | * 新增任务 |
| | | */ |
| | | @GetMapping("/add") |
| | | public String add(ModelMap mmap) |
| | | { |
| | | ResultVO<List<RiskList>> resultVO = riskListService.listHazardSource(); |
| | | Object data = resultVO.getData(); |
| | | mmap.put("hazardList", data); |
| | | return prefix + "/add"; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 新增任务保存 |
| | | */ |
| | | @PostMapping("/add") |
| | | @ResponseBody |
| | | public AjaxResult addSpecialItemDanger(@RequestBody TbSpecialCheckItemDangerLog itemDangerLog){ |
| | | |
| | | ResultVO<TbSpecialCheckItemDangerLog> resultVO = itemDangerLogService.addSpecialItemDanger(itemDangerLog); |
| | | String code = resultVO.getCode(); |
| | | if ("200".equals(code)){ |
| | | return toAjax(1); |
| | | }else { |
| | | return AjaxResult.error(resultVO.getMsg()); |
| | | } |
| | | } |
| | | |
| | | @GetMapping("/edit/{id}") |
| | | public String edit(@PathVariable("id") Long indexId, ModelMap mmap) |
| | | { |
| | | TbSpecialCheckItemDangerLog specialCheckItem = itemDangerLogService.getSpecialCheckItemDangerLogByIndexId(indexId); |
| | | mmap.put("specialCheckItem",specialCheckItem); |
| | | |
| | | // TbBaseCheckTaskBO tbBaseCheckTaskBO = new TbBaseCheckTaskBO(); |
| | | // ResultVO<List<TbBaseCheckTask>> listResultVO = tbBaseCheckService.selectTbBaseCheckTaskPage(tbBaseCheckTaskBO); |
| | | // Object data = listResultVO.getData(); |
| | | // mmap.put("tbBaseCheckTask", data); |
| | | return prefix + "/edit"; |
| | | } |
| | | |
| | | /** |
| | | * 修改保存 |
| | | */ |
| | | @PostMapping("/edit") |
| | | @ResponseBody |
| | | public AjaxResult editSave(@RequestBody TbSpecialCheckItemDangerLogUpdateBO updateBO) |
| | | { |
| | | ResultVO<TbSpecialCheckItemDangerLog> resultVO = itemDangerLogService.updateSpecialCheckItemDangerLog(updateBO); |
| | | String code = resultVO.getCode(); |
| | | if ("200".equals(code)){ |
| | | return toAjax(1); |
| | | }else { |
| | | return AjaxResult.error(resultVO.getMsg()); |
| | | } |
| | | } |
| | | |
| | | |
| | | @PostMapping("/remove") |
| | | @ResponseBody |
| | | public AjaxResult remove(@RequestBody TbSpecialCheckItemDangerLogUpdateBO updateBO){ |
| | | ResultVO<TbSpecialCheckItemDangerLog> resultVO = itemDangerLogService.deleteTbSpecialItemDangerTaskLog(updateBO); |
| | | String code = resultVO.getCode(); |
| | | if ("200".equals(code)){ |
| | | return toAjax(1); |
| | | }else { |
| | | return AjaxResult.error(resultVO.getMsg()); |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | |
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.controller; |
| | | |
| | | import com.ruoyi.doublePrevention.entity.PreventRiskControlMeasure; |
| | | import com.ruoyi.doublePrevention.entity.dto.req.PreventRiskControlMeasureDeleteReqDTO; |
| | | import com.ruoyi.doublePrevention.vo.ResultVO; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.controller.BaseController; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.framework.web.page.TableDataInfo; |
| | | import com.ruoyi.project.tr.riskList.domain.RiskList; |
| | | import com.ruoyi.project.tr.riskList.service.IRiskListService; |
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckTaskBO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckTaskLogBO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckTaskLogUpdateBO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.DTO.TbSpecialCheckTaskLogDTO; |
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckTask; |
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog; |
| | | import com.ruoyi.project.tr.specialCheck.service.SpecialCheckTaskService; |
| | | import com.ruoyi.project.tr.specialCheck.service.TbBaseCheckService; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.ui.ModelMap; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * 隐患列表Controller |
| | | * |
| | | * @date 2020-05-08 |
| | | */ |
| | | @Controller |
| | | @RequestMapping("/tr/specialCheckTaskLog") |
| | | public class TBSpecialCheckTaskLogController extends BaseController |
| | | { |
| | | private String prefix = "tr/specialCheckTaskLog"; |
| | | |
| | | @Autowired |
| | | private SpecialCheckTaskService specialCheckTaskService; |
| | | |
| | | @Autowired |
| | | private IRiskListService riskListService; |
| | | |
| | | @Autowired |
| | | private TbBaseCheckService tbBaseCheckService; |
| | | |
| | | |
| | | |
| | | @GetMapping() |
| | | public String selectTbBaseCheckTaskPage(ModelMap mmap) |
| | | { |
| | | return prefix + "/specialCheckTaskLog"; |
| | | } |
| | | |
| | | |
| | | |
| | | @PostMapping("/list") |
| | | @ResponseBody |
| | | public TableDataInfo selectSpecialCheckTaskLogPage(@RequestBody TbSpecialCheckTaskLogBO specialCheckTaskLogBO) |
| | | { |
| | | |
| | | ResultVO<List<TbSpecialCheckTaskLog>> resultVO = specialCheckTaskService.selectSpecialCheckTaskLogPage(specialCheckTaskLogBO); |
| | | List<TbSpecialCheckTaskLogDTO> data = (List<TbSpecialCheckTaskLogDTO>) resultVO.getData(); |
| | | TableDataInfo dataTable = getDataTable(data); |
| | | dataTable.setTotal(resultVO.getCount()); |
| | | |
| | | return dataTable; |
| | | } |
| | | |
| | | /** |
| | | * 新增任务 |
| | | */ |
| | | @GetMapping("/add") |
| | | public String add(ModelMap mmap) |
| | | { |
| | | ResultVO<List<RiskList>> resultVO = riskListService.listHazardSource(); |
| | | Object data = resultVO.getData(); |
| | | mmap.put("hazardList", data); |
| | | return prefix + "/add"; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 新增任务保存 |
| | | */ |
| | | @PostMapping("/add") |
| | | @ResponseBody |
| | | public AjaxResult addSpecialTask(@RequestBody TbSpecialCheckTaskLog tbSpecialCheckTaskLog){ |
| | | |
| | | ResultVO<TbSpecialCheckTaskLog> resultVO = specialCheckTaskService.addSpecialTask(tbSpecialCheckTaskLog); |
| | | String code = resultVO.getCode(); |
| | | if ("200".equals(code)){ |
| | | return toAjax(1); |
| | | }else { |
| | | return AjaxResult.error(resultVO.getMsg()); |
| | | } |
| | | } |
| | | |
| | | @GetMapping("/edit/{id}") |
| | | public String edit(@PathVariable("indexId") Long indexId, ModelMap mmap) |
| | | { |
| | | TbSpecialCheckTaskLog specialCheckTaskLogByIndexId = specialCheckTaskService.getSpecialCheckTaskLogByIndexId(indexId); |
| | | mmap.put("specialCheckTaskLog",specialCheckTaskLogByIndexId); |
| | | |
| | | TbBaseCheckTaskBO tbBaseCheckTaskBO = new TbBaseCheckTaskBO(); |
| | | ResultVO<List<TbBaseCheckTask>> listResultVO = tbBaseCheckService.selectTbBaseCheckTaskPage(tbBaseCheckTaskBO); |
| | | Object data = listResultVO.getData(); |
| | | mmap.put("tbBaseCheckTask", data); |
| | | return prefix + "/edit"; |
| | | } |
| | | |
| | | /** |
| | | * 修改保存 |
| | | */ |
| | | @PostMapping("/edit") |
| | | @ResponseBody |
| | | public AjaxResult editSave(@RequestBody TbSpecialCheckTaskLogUpdateBO updateBO) |
| | | { |
| | | ResultVO<TbSpecialCheckTaskLog> resultVO = specialCheckTaskService.updateSpecialCheckTaskLog(updateBO); |
| | | String code = resultVO.getCode(); |
| | | if ("200".equals(code)){ |
| | | return toAjax(1); |
| | | }else { |
| | | return AjaxResult.error(resultVO.getMsg()); |
| | | } |
| | | } |
| | | |
| | | |
| | | @PostMapping("/remove") |
| | | @ResponseBody |
| | | public AjaxResult remove(@RequestBody TbSpecialCheckTaskLogUpdateBO updateBO){ |
| | | ResultVO<TbSpecialCheckTaskLog> resultVO = specialCheckTaskService.deleteTbSpecialCheckTaskLog(updateBO); |
| | | String code = resultVO.getCode(); |
| | | if ("200".equals(code)){ |
| | | return toAjax(1); |
| | | }else { |
| | | return AjaxResult.error(resultVO.getMsg()); |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | |
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.BO;
|
| | |
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class HandlerSpecialCheckReportParam {
|
| | |
|
| | | /**
|
| | | * 主键
|
| | | */
|
| | | private String id;
|
| | | /**
|
| | | * 上报状态 1-待上报;2-已上报;3-不上报;4-变更需上传
|
| | | */
|
| | | private Byte reportStatus;
|
| | | /**
|
| | | * 上报时间
|
| | | */
|
| | | private LocalDateTime reportTime;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.BO;
|
| | |
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbBaseCheckItemBO {
|
| | |
|
| | | private Integer pageNum;
|
| | |
|
| | | private Integer pageSize;
|
| | |
|
| | |
|
| | | private String checkName;
|
| | |
|
| | | private String checkContent;
|
| | |
|
| | | private String checkWay;
|
| | |
|
| | | private String checkBasis;
|
| | |
|
| | | private String applicablePlace;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.BO;
|
| | |
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbBaseCheckScoreBO {
|
| | |
|
| | | private Integer pageNum;
|
| | |
|
| | | private Integer pageSize;
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String checkItemId;
|
| | |
|
| | | private String isReject;
|
| | |
|
| | | private String deductPoint;
|
| | |
|
| | | private String deductIllustrate;
|
| | |
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.BO;
|
| | |
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbBaseCheckTaskBO {
|
| | |
|
| | | private Integer pageNum;
|
| | |
|
| | | private Integer pageSize;
|
| | |
|
| | | private String taskName;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime taskStartTime;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime taskEndTime;
|
| | |
|
| | | private String taskTypeName;
|
| | |
|
| | | private String taskContent;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.BO;
|
| | |
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.math.BigDecimal;
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbSpecialCheckItemDangerLogBO {
|
| | |
|
| | | private Integer pageNum;
|
| | |
|
| | | private Integer pageSize;
|
| | |
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | | private String dangerId;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkType;
|
| | |
|
| | | private String checkItemId;
|
| | |
|
| | | private String checkScoreId;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime checkDate;
|
| | |
|
| | | private String checkPay;
|
| | |
|
| | | private String harmType;
|
| | |
|
| | | private String checkName;
|
| | |
|
| | | private String checkContent;
|
| | |
|
| | | private String checkWay;
|
| | |
|
| | | private String checkBasis;
|
| | |
|
| | | private String applicablePlace;
|
| | |
|
| | | private String isReject;
|
| | |
|
| | | private String deductPoint;
|
| | |
|
| | | private String deductIllustrate;
|
| | |
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime reportTime;
|
| | |
|
| | | private Byte reportStatus;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.BO;
|
| | |
|
| | | import com.baomidou.mybatisplus.annotation.IdType;
|
| | | import com.baomidou.mybatisplus.annotation.TableId;
|
| | | import com.baomidou.mybatisplus.annotation.TableName;
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.math.BigDecimal;
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbSpecialCheckItemDangerLogUpdateBO {
|
| | |
|
| | |
|
| | | private Long indexId;
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | |
|
| | |
|
| | | private String dangerId;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkType;
|
| | |
|
| | | private String checkItemId;
|
| | |
|
| | | private String checkScoreId;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime checkDate;
|
| | |
|
| | | private String checkPay;
|
| | |
|
| | | private String harmType;
|
| | |
|
| | | private String checkName;
|
| | |
|
| | | private String checkContent;
|
| | |
|
| | | private String checkWay;
|
| | |
|
| | | private String checkBasis;
|
| | |
|
| | | private String applicablePlace;
|
| | |
|
| | | private String isReject;
|
| | |
|
| | | private String deductPoint;
|
| | |
|
| | | private String deductIllustrate;
|
| | |
|
| | |
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime reportTime;
|
| | |
|
| | | private Byte reportStatus;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.BO;
|
| | |
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbSpecialCheckTaskLogBO {
|
| | |
|
| | | private Integer pageNum;
|
| | |
|
| | | private Integer pageSize;
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | | private String hazardCode;
|
| | |
|
| | | private String hazardSource;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkType;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime checkDate;
|
| | |
|
| | | private String resultStatus;
|
| | |
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime reportTime;
|
| | |
|
| | | private Byte reportStatus;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.BO;
|
| | |
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbSpecialCheckTaskLogUpdateBO {
|
| | |
|
| | | private Long indexId;
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | | private String hazardCode;
|
| | |
|
| | | private String hazardSource;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkType;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime checkDate;
|
| | |
|
| | | private String resultStatus;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime reportTime;
|
| | |
|
| | | private Byte reportStatus;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.DTO;
|
| | |
|
| | | import com.baomidou.mybatisplus.annotation.IdType;
|
| | | import com.baomidou.mybatisplus.annotation.TableId;
|
| | | import com.baomidou.mybatisplus.annotation.TableName;
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.math.BigDecimal;
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class SpecialCheckItemDangerLogReportDTO {
|
| | |
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | | private String dangerId;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkType;
|
| | |
|
| | | private String checkItemId;
|
| | |
|
| | | private String checkScoreId;
|
| | |
|
| | | private String checkDate;
|
| | |
|
| | | private String checkPay;
|
| | |
|
| | | private String harmType;
|
| | |
|
| | | private String deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | private String createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | private String updateDate;
|
| | |
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.DTO;
|
| | |
|
| | | import lombok.Data;
|
| | |
|
| | |
|
| | | @Data
|
| | | public class SpecialCheckTaskLogReportDTO {
|
| | |
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | | private String hazardCode;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkType;
|
| | |
|
| | | private String checkDate;
|
| | |
|
| | | private String resultStatus;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | private String createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | private String updateDate;
|
| | |
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.DTO;
|
| | |
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbBaseCheckItemDTO {
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkName;
|
| | |
|
| | | private String checkContent;
|
| | |
|
| | | private String checkWay;
|
| | |
|
| | | private String checkBasis;
|
| | |
|
| | | private String applicablePlace;
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | private LocalDateTime updateDate;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.DTO;
|
| | |
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbBaseCheckScoreDTO {
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String checkItemId;
|
| | |
|
| | | private String isReject;
|
| | |
|
| | | private String deductPoint;
|
| | |
|
| | | private String deductIllustrate;
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | private LocalDateTime updateDate;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.DTO;
|
| | |
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbBaseCheckTaskDTO {
|
| | |
|
| | | private Integer pageNum;
|
| | |
|
| | | private Integer pageSize;
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String taskName;
|
| | |
|
| | | private LocalDateTime taskStartTime;
|
| | |
|
| | | private LocalDateTime taskEndTime;
|
| | |
|
| | | private String taskTypeName;
|
| | |
|
| | | private String taskContent;
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.DTO;
|
| | |
|
| | | import com.baomidou.mybatisplus.annotation.IdType;
|
| | | import com.baomidou.mybatisplus.annotation.TableId;
|
| | | import com.baomidou.mybatisplus.annotation.TableName;
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.math.BigDecimal;
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbSpecialCheckItemDangerLogDTO {
|
| | |
|
| | |
|
| | | @TableId(type = IdType.AUTO)
|
| | | private Long indexId;
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | |
|
| | |
|
| | | private String dangerId;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkType;
|
| | |
|
| | | private String checkItemId;
|
| | |
|
| | | private String checkScoreId;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime checkDate;
|
| | |
|
| | | private String checkPay;
|
| | |
|
| | | private String harmType;
|
| | |
|
| | | private String checkName;
|
| | |
|
| | | private String checkContent;
|
| | |
|
| | | private String checkWay;
|
| | |
|
| | | private String checkBasis;
|
| | |
|
| | | private String applicablePlace;
|
| | |
|
| | | private String isReject;
|
| | |
|
| | | private String deductPoint;
|
| | |
|
| | | private String deductIllustrate;
|
| | |
|
| | |
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime reportTime;
|
| | |
|
| | | private Byte reportStatus;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin.DTO;
|
| | |
|
| | | import com.baomidou.mybatisplus.annotation.IdType;
|
| | | import com.baomidou.mybatisplus.annotation.TableId;
|
| | | import com.baomidou.mybatisplus.annotation.TableName;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | public class TbSpecialCheckTaskLogDTO {
|
| | |
|
| | |
|
| | | private Long indexId;
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | | private String hazardCode;
|
| | | private String hazardSource;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkType;
|
| | |
|
| | | private LocalDateTime checkDate;
|
| | |
|
| | | private String resultStatus;
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | private LocalDateTime reportTime;
|
| | |
|
| | | private Byte reportStatus;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin;
|
| | |
|
| | | import com.baomidou.mybatisplus.annotation.TableName;
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | @TableName("tb_base_check_company")
|
| | | public class TbBaseCheckCompany {
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | private String bjxfbm;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin;
|
| | |
|
| | | import com.baomidou.mybatisplus.annotation.TableName;
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | @TableName("tb_base_check_item")
|
| | | public class TbBaseCheckItem {
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkName;
|
| | |
|
| | | private String checkContent;
|
| | |
|
| | | private String checkWay;
|
| | |
|
| | | private String checkBasis;
|
| | |
|
| | | private String applicablePlace;
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin;
|
| | |
|
| | | import com.baomidou.mybatisplus.annotation.TableName;
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | @TableName("tb_base_check_score")
|
| | | public class TbBaseCheckScore {
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String checkItemId;
|
| | |
|
| | | private String isReject;
|
| | |
|
| | | private String deductPoint;
|
| | |
|
| | | private String deductIllustrate;
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin;
|
| | |
|
| | | import com.baomidou.mybatisplus.annotation.TableName;
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | @TableName("tb_base_check_task")
|
| | | public class TbBaseCheckTask {
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String taskName;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime taskStartTime;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime taskEndTime;
|
| | |
|
| | | private String taskTypeName;
|
| | |
|
| | | private String taskContent;
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin;
|
| | |
|
| | | import com.baomidou.mybatisplus.annotation.IdType;
|
| | | import com.baomidou.mybatisplus.annotation.TableId;
|
| | | import com.baomidou.mybatisplus.annotation.TableName;
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.math.BigDecimal;
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | @TableName("tb_special_check_item_danger_log")
|
| | | public class TbSpecialCheckItemDangerLog {
|
| | |
|
| | |
|
| | | @TableId(type = IdType.AUTO)
|
| | | private Long indexId;
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | |
|
| | |
|
| | | private String dangerId;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkType;
|
| | |
|
| | | private String checkItemId;
|
| | |
|
| | | private String checkScoreId;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime checkDate;
|
| | |
|
| | | private String checkPay;
|
| | |
|
| | | private String harmType;
|
| | |
|
| | | private String checkName;
|
| | |
|
| | | private String checkContent;
|
| | |
|
| | | private String checkWay;
|
| | |
|
| | | private String checkBasis;
|
| | |
|
| | | private String applicablePlace;
|
| | |
|
| | | private String isReject;
|
| | |
|
| | | private String deductPoint;
|
| | |
|
| | | private String deductIllustrate;
|
| | |
|
| | |
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime reportTime;
|
| | |
|
| | | private Byte reportStatus;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.domin;
|
| | |
|
| | | import com.baomidou.mybatisplus.annotation.IdType;
|
| | | import com.baomidou.mybatisplus.annotation.TableId;
|
| | | import com.baomidou.mybatisplus.annotation.TableName;
|
| | | import com.fasterxml.jackson.annotation.JsonFormat;
|
| | | import lombok.Data;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | |
|
| | | @Data
|
| | | @TableName("tb_special_check_task_log")
|
| | | public class TbSpecialCheckTaskLog {
|
| | |
|
| | |
|
| | | @TableId(type = IdType.AUTO)
|
| | | private Long indexId;
|
| | |
|
| | | private String id;
|
| | |
|
| | | private String companyCode;
|
| | |
|
| | | private String hazardCode;
|
| | |
|
| | | private String hazardSource;
|
| | |
|
| | | private String taskId;
|
| | |
|
| | | private String checkType;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime checkDate;
|
| | |
|
| | | private String resultStatus;
|
| | |
|
| | | private Byte deleted;
|
| | |
|
| | | private String createBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime createDate;
|
| | |
|
| | | private String updateBy;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime updateDate;
|
| | |
|
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
| | | private LocalDateTime reportTime;
|
| | |
|
| | | private Byte reportStatus;
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.mapper;
|
| | |
|
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckCompany;
|
| | | import org.springframework.stereotype.Repository;
|
| | |
|
| | | @Repository
|
| | | public interface TbBaseCheckCompanyMapper extends BaseMapper<TbBaseCheckCompany> {
|
| | |
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.mapper;
|
| | |
|
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckItemBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckScoreBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckItem;
|
| | | import org.springframework.stereotype.Repository;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | | @Repository
|
| | | public interface TbBaseCheckItemMapper extends BaseMapper<TbBaseCheckItem> {
|
| | |
|
| | | List<TbBaseCheckItem> selectTbBaseCheckItemPage(TbBaseCheckItemBO tbBaseCheckItemBO);
|
| | |
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.mapper;
|
| | |
|
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckScoreBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckScore;
|
| | | import org.springframework.stereotype.Repository;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | | @Repository
|
| | | public interface TbBaseCheckScoreMapper extends BaseMapper<TbBaseCheckScore> {
|
| | |
|
| | | List<TbBaseCheckScore> selectTbBaseCheckScorePage(TbBaseCheckScoreBO tbBaseCheckScoreBO);
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.mapper;
|
| | |
|
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckTaskBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckTask;
|
| | | import org.springframework.stereotype.Repository;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | | @Repository
|
| | | public interface TbBaseCheckTaskMapper extends BaseMapper<TbBaseCheckTask> {
|
| | |
|
| | | List<TbBaseCheckTaskMapper> selectTbBaseCheckTaskPage(TbBaseCheckTaskBO tbBaseCheckTaskBO);
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.mapper;
|
| | |
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.HandlerSpecialCheckReportParam;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckItemDangerLogBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckItemDangerLogUpdateBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog;
|
| | | import org.springframework.stereotype.Repository;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | | @Repository
|
| | | public interface TbSpecialCheckItemDangerLogMapper {
|
| | |
|
| | | List<TbSpecialCheckItemDangerLog> selectSpecialCheckItemDangerLogPage(TbSpecialCheckItemDangerLogBO itemDangerLogBO);
|
| | |
|
| | | int save(TbSpecialCheckItemDangerLog itemDangerLog);
|
| | |
|
| | | TbSpecialCheckItemDangerLog getSpecialCheckItemDangerLogByIndexId(Long indexId);
|
| | |
|
| | | int updateSpecialCheckItemDangerLogById(TbSpecialCheckItemDangerLogUpdateBO updateBO);
|
| | |
|
| | | int deleteTbSpecialCheckItemDangerLog(TbSpecialCheckItemDangerLog tbSpecialCheckItemDangerLog);
|
| | |
|
| | | List<TbSpecialCheckItemDangerLog> listItemDangerReportTask();
|
| | |
|
| | | void updateItemDangerReportStatusById(HandlerSpecialCheckReportParam handlerCJReportParam);
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.mapper;
|
| | |
|
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
| | | import com.ruoyi.doublePrevention.repository.param.HandlerCJReportParam;
|
| | | import com.ruoyi.doublePrevention.vo.ResultVO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.HandlerSpecialCheckReportParam;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckTaskLogBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckTaskLogUpdateBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog;
|
| | | import org.springframework.stereotype.Repository;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | |
|
| | | @Repository
|
| | | public interface TbSpecialCheckTaskLogMapper extends BaseMapper<TbSpecialCheckTaskLog> {
|
| | |
|
| | | List<TbSpecialCheckTaskLog> selectSpecialCheckTaskLogPage(TbSpecialCheckTaskLogBO specialCheckTaskLogBO);
|
| | |
|
| | | int save(TbSpecialCheckTaskLog tbSpecialCheckTaskLog);
|
| | |
|
| | | TbSpecialCheckTaskLog getSpecialCheckTaskLogByIndexId(Long indexId);
|
| | |
|
| | | int updateSpecialCheckTaskLogById(TbSpecialCheckTaskLogUpdateBO updateBO);
|
| | |
|
| | | int deleteTbSpecialCheckTaskLog(TbSpecialCheckTaskLog tbSpecialCheckTaskLog);
|
| | |
|
| | | List<TbSpecialCheckTaskLog> listTestReportTask();
|
| | |
|
| | | void updateCheckTaskReportStatusById(HandlerSpecialCheckReportParam handlerCJReportParam);
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.service;
|
| | |
|
| | |
|
| | | import com.ruoyi.doublePrevention.vo.ResultVO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckItemDangerLogBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckItemDangerLogUpdateBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | | public interface SpecialCheckItemDangerLogService {
|
| | |
|
| | |
|
| | | ResultVO<List<TbSpecialCheckItemDangerLog>> selectSpecialCheckItemDangerLogPage(TbSpecialCheckItemDangerLogBO itemDangerLogBO);
|
| | |
|
| | | ResultVO<TbSpecialCheckItemDangerLog> addSpecialItemDanger(TbSpecialCheckItemDangerLog itemDangerLog);
|
| | |
|
| | | TbSpecialCheckItemDangerLog getSpecialCheckItemDangerLogByIndexId(Long indexId);
|
| | |
|
| | | ResultVO<TbSpecialCheckItemDangerLog> updateSpecialCheckItemDangerLog(TbSpecialCheckItemDangerLogUpdateBO updateBO);
|
| | |
|
| | | ResultVO<TbSpecialCheckItemDangerLog> deleteTbSpecialItemDangerTaskLog(TbSpecialCheckItemDangerLogUpdateBO updateBO);
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.service;
|
| | |
|
| | |
|
| | | import com.ruoyi.doublePrevention.vo.ResultVO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckTaskLogBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckTaskLogUpdateBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | | public interface SpecialCheckTaskService {
|
| | |
|
| | | ResultVO<List<TbSpecialCheckTaskLog>> selectSpecialCheckTaskLogPage(TbSpecialCheckTaskLogBO specialCheckTaskLogBO);
|
| | |
|
| | | ResultVO<TbSpecialCheckTaskLog> addSpecialTask(TbSpecialCheckTaskLog tbSpecialCheckTaskLog);
|
| | |
|
| | | TbSpecialCheckTaskLog getSpecialCheckTaskLogByIndexId(Long id);
|
| | |
|
| | | ResultVO<TbSpecialCheckTaskLog> updateSpecialCheckTaskLog(TbSpecialCheckTaskLogUpdateBO updateBO);
|
| | |
|
| | | ResultVO<TbSpecialCheckTaskLog> deleteTbSpecialCheckTaskLog(TbSpecialCheckTaskLogUpdateBO updateBO);
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.service;
|
| | |
|
| | | import com.ruoyi.doublePrevention.vo.ResultVO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckItemBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckScoreBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckTaskBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckTaskLogBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckItem;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckScore;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckTask;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | | public interface TbBaseCheckService {
|
| | |
|
| | | ResultVO<List<TbBaseCheckTask>> selectTbBaseCheckTaskPage(TbBaseCheckTaskBO tbBaseCheckTaskBO);
|
| | |
|
| | | ResultVO<List<TbBaseCheckItem>> selectTbBaseCheckItemPage(TbBaseCheckItemBO tbBaseCheckItemBO);
|
| | |
|
| | | ResultVO<List<TbBaseCheckScore>> selectTbBaseCheckScorePage(TbBaseCheckScoreBO tbBaseCheckScoreBO);
|
| | |
|
| | |
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.service.impl;
|
| | |
|
| | | import com.github.pagehelper.Page;
|
| | | import com.github.pagehelper.PageHelper;
|
| | | import com.ruoyi.doublePrevention.enums.ErrorCodes;
|
| | | import com.ruoyi.doublePrevention.enums.ResultCodes;
|
| | | import com.ruoyi.doublePrevention.vo.ResultVO;
|
| | | import com.ruoyi.project.system.user.domain.User;
|
| | | import com.ruoyi.project.tr.riskList.domain.RiskList;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckItemDangerLogBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckItemDangerLogUpdateBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog;
|
| | | import com.ruoyi.project.tr.specialCheck.mapper.TbSpecialCheckItemDangerLogMapper;
|
| | | import com.ruoyi.project.tr.specialCheck.service.SpecialCheckItemDangerLogService;
|
| | | import org.springframework.beans.factory.annotation.Autowired;
|
| | | import org.springframework.stereotype.Service;
|
| | | import org.springframework.util.ObjectUtils;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | | import java.util.List;
|
| | | import java.util.UUID;
|
| | |
|
| | | import static com.ruoyi.common.utils.security.ShiroUtils.getSysUser;
|
| | |
|
| | | @Service
|
| | | public class SpecialCheckItemDangerLogServiceImpl implements SpecialCheckItemDangerLogService {
|
| | |
|
| | | @Autowired
|
| | | private TbSpecialCheckItemDangerLogMapper itemDangerLogMapper;
|
| | |
|
| | |
|
| | | @Override
|
| | | public ResultVO<List<TbSpecialCheckItemDangerLog>> selectSpecialCheckItemDangerLogPage(TbSpecialCheckItemDangerLogBO itemDangerLogBO) {
|
| | | Integer pageIndex = itemDangerLogBO.getPageNum();
|
| | | Integer pageSize = itemDangerLogBO.getPageSize();
|
| | | if (pageIndex == 0 || pageSize == 0){
|
| | | return new ResultVO<>(ErrorCodes.REQUEST_PARAM_ERROR.getCode(),"当前页码或当前页显示数不能为0");
|
| | | }
|
| | |
|
| | | Page<TbSpecialCheckItemDangerLog> page = PageHelper.startPage(pageIndex, pageSize);
|
| | | itemDangerLogMapper.selectSpecialCheckItemDangerLogPage(itemDangerLogBO);
|
| | |
|
| | | Long total = page.getTotal();
|
| | | int count = total.intValue();
|
| | | List<TbSpecialCheckItemDangerLog> pageResult = null;
|
| | |
|
| | | ResultVO<List<TbSpecialCheckItemDangerLog>> resultVO = new ResultVO<>(ResultCodes.OK,pageResult);
|
| | |
|
| | | resultVO.setData(page.getResult());
|
| | | resultVO.setCount(count);
|
| | | resultVO.setCount((int) page.getTotal());
|
| | | resultVO.setPageNum(page.getPageNum());
|
| | | resultVO.setPageSize(page.getPageSize());
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | @Override
|
| | | public ResultVO<TbSpecialCheckItemDangerLog> addSpecialItemDanger(TbSpecialCheckItemDangerLog itemDangerLog) {
|
| | | User sysUser = getSysUser();
|
| | | ResultVO resultVO = new ResultVO<>();
|
| | | resultVO.setCode(ErrorCodes.REQUEST_PARAM_ERROR.getCode());
|
| | |
|
| | | // 四类id,挨个查询,判断是否存在
|
| | | if (itemDangerLog.getCheckItemId() == null){
|
| | | resultVO.setMsg("检查项不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (itemDangerLog.getTaskId() == null){
|
| | | resultVO.setMsg("任务不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (itemDangerLog.getCheckScoreId() == null){
|
| | | resultVO.setMsg("评分不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (itemDangerLog.getDangerId() == null){
|
| | | resultVO.setMsg("关联隐患不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (itemDangerLog.getCheckDate() == null){
|
| | | resultVO.setMsg("检查时间不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (itemDangerLog.getCheckType() == null){
|
| | | resultVO.setMsg("检查类型不能为空");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | LocalDateTime dateTime = LocalDateTime.now();
|
| | | String uuid = UUID.randomUUID().toString();
|
| | |
|
| | | itemDangerLog.setId(uuid);
|
| | | itemDangerLog.setCompanyCode("652310082");
|
| | | itemDangerLog.setCreateDate(dateTime);
|
| | | itemDangerLog.setUpdateDate(dateTime);
|
| | | itemDangerLog.setCreateBy(sysUser.getUserName());
|
| | | itemDangerLog.setUpdateBy(sysUser.getUserName());
|
| | | itemDangerLog.setReportStatus((byte) 1);
|
| | | itemDangerLog.setReportTime(null);
|
| | | itemDangerLog.setDeleted((byte) 0);
|
| | |
|
| | | int saveResult = itemDangerLogMapper.save(itemDangerLog);
|
| | | if (saveResult == 0){
|
| | | resultVO.setCode(ResultCodes.SERVER_ADD_ERROR.getCode());
|
| | | resultVO.setMsg(ResultCodes.SERVER_ADD_ERROR.getDesc());
|
| | | return resultVO;
|
| | | }
|
| | | resultVO.setCode(ResultCodes.OK.getCode());
|
| | | resultVO.setMsg("新增检查成功");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | @Override
|
| | | public TbSpecialCheckItemDangerLog getSpecialCheckItemDangerLogByIndexId(Long indexId) {
|
| | | return itemDangerLogMapper.getSpecialCheckItemDangerLogByIndexId(indexId);
|
| | | }
|
| | |
|
| | | @Override
|
| | | public ResultVO<TbSpecialCheckItemDangerLog> updateSpecialCheckItemDangerLog(TbSpecialCheckItemDangerLogUpdateBO updateBO) {
|
| | | User sysUser = getSysUser();
|
| | | ResultVO resultVO = new ResultVO<>();
|
| | | resultVO.setCode(ErrorCodes.REQUEST_PARAM_ERROR.getCode());
|
| | |
|
| | | // 四类id,挨个查询,判断是否存在
|
| | | if (updateBO.getCheckItemId() == null){
|
| | | resultVO.setMsg("检查项不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getTaskId() == null){
|
| | | resultVO.setMsg("任务不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getCheckScoreId() == null){
|
| | | resultVO.setMsg("评分不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getDangerId() == null){
|
| | | resultVO.setMsg("关联隐患不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getCheckDate() == null){
|
| | | resultVO.setMsg("检查时间不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getCheckType() == null){
|
| | | resultVO.setMsg("检查类型不能为空");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | LocalDateTime dateTime = LocalDateTime.now();
|
| | |
|
| | | updateBO.setCompanyCode("652310082");
|
| | | updateBO.setCreateDate(dateTime);
|
| | | updateBO.setUpdateDate(dateTime);
|
| | | updateBO.setCreateBy(sysUser.getUserName());
|
| | | updateBO.setUpdateBy(sysUser.getUserName());
|
| | | updateBO.setReportStatus((byte) 1);
|
| | | updateBO.setReportTime(null);
|
| | | updateBO.setDeleted((byte) 0);
|
| | |
|
| | | int updateResult = itemDangerLogMapper.updateSpecialCheckItemDangerLogById(updateBO);
|
| | | if (updateResult == 0){
|
| | | resultVO.setCode(ResultCodes.SERVER_UPDATE_ERROR.getCode());
|
| | | resultVO.setMsg(ResultCodes.SERVER_UPDATE_ERROR.getDesc());
|
| | | return resultVO;
|
| | | }
|
| | | resultVO.setCode(ResultCodes.OK.getCode());
|
| | | resultVO.setMsg("更新成功");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | @Override
|
| | | public ResultVO<TbSpecialCheckItemDangerLog> deleteTbSpecialItemDangerTaskLog(TbSpecialCheckItemDangerLogUpdateBO updateBO) {
|
| | | User sysUser = getSysUser();
|
| | | ResultVO resultVO = new ResultVO<>();
|
| | | resultVO.setCode(ErrorCodes.REQUEST_PARAM_ERROR.getCode());
|
| | |
|
| | | if (updateBO.getIndexId() == null){
|
| | | resultVO.setMsg("检查项为空");
|
| | | return resultVO;
|
| | | }
|
| | | TbSpecialCheckItemDangerLog specialCheckItemDangerLogByIndexId = itemDangerLogMapper.getSpecialCheckItemDangerLogByIndexId(updateBO.getIndexId());
|
| | | if (ObjectUtils.isEmpty(specialCheckItemDangerLogByIndexId)){
|
| | | resultVO.setMsg("检查项不存在,删除失败");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | // 四类id,挨个查询,判断是否存在
|
| | | if (updateBO.getCheckItemId() == null){
|
| | | resultVO.setMsg("检查项不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getTaskId() == null){
|
| | | resultVO.setMsg("任务不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getCheckScoreId() == null){
|
| | | resultVO.setMsg("评分不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getDangerId() == null){
|
| | | resultVO.setMsg("关联隐患不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getCheckDate() == null){
|
| | | resultVO.setMsg("检查时间不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getCheckType() == null){
|
| | | resultVO.setMsg("检查类型不能为空");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | TbSpecialCheckItemDangerLog tbSpecialCheckItemDangerLog = new TbSpecialCheckItemDangerLog();
|
| | | LocalDateTime dateTime = LocalDateTime.now();
|
| | |
|
| | | tbSpecialCheckItemDangerLog.setIndexId(updateBO.getIndexId());
|
| | | tbSpecialCheckItemDangerLog.setUpdateDate(dateTime);
|
| | | tbSpecialCheckItemDangerLog.setUpdateBy(sysUser.getUserName());
|
| | | tbSpecialCheckItemDangerLog.setReportStatus((byte) 1);
|
| | | tbSpecialCheckItemDangerLog.setDeleted((byte) 1);
|
| | |
|
| | | int deleteResult = itemDangerLogMapper.deleteTbSpecialCheckItemDangerLog(tbSpecialCheckItemDangerLog);
|
| | | if (deleteResult == 0){
|
| | | resultVO.setCode(ResultCodes.SERVER_DEL_ERROR.getCode());
|
| | | resultVO.setMsg(ResultCodes.SERVER_DEL_ERROR.getDesc());
|
| | | return resultVO;
|
| | | }
|
| | | resultVO.setCode(ResultCodes.OK.getCode());
|
| | | resultVO.setMsg("删除成功");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | |
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.service.impl;
|
| | |
|
| | | import com.github.pagehelper.Page;
|
| | | import com.github.pagehelper.PageHelper;
|
| | | import com.ruoyi.doublePrevention.entity.PreventRiskControlMeasure;
|
| | | import com.ruoyi.doublePrevention.enums.ErrorCodes;
|
| | | import com.ruoyi.doublePrevention.enums.ResultCodes;
|
| | | import com.ruoyi.doublePrevention.vo.ResultVO;
|
| | | import com.ruoyi.project.system.user.domain.User;
|
| | | import com.ruoyi.project.tr.riskList.domain.RiskList;
|
| | | import com.ruoyi.project.tr.riskList.service.IRiskListService;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.*;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog;
|
| | | import com.ruoyi.project.tr.specialCheck.mapper.*;
|
| | | import com.ruoyi.project.tr.specialCheck.service.SpecialCheckTaskService;
|
| | | import org.springframework.beans.factory.annotation.Autowired;
|
| | | import org.springframework.stereotype.Service;
|
| | | import org.springframework.util.ObjectUtils;
|
| | |
|
| | | import java.time.LocalDateTime;
|
| | | import java.util.Date;
|
| | | import java.util.List;
|
| | | import java.util.UUID;
|
| | |
|
| | | import static com.ruoyi.common.utils.security.ShiroUtils.getSysUser;
|
| | |
|
| | | @Service
|
| | | public class SpecialCheckTaskServiceImpl implements SpecialCheckTaskService {
|
| | |
|
| | | @Autowired
|
| | | private TbBaseCheckCompanyMapper companyTbRepository;
|
| | | @Autowired
|
| | | private TbBaseCheckItemMapper itemTbRepository;
|
| | | @Autowired
|
| | | private TbBaseCheckScoreMapper scoreTbRepository;
|
| | | @Autowired
|
| | | private TbBaseCheckTaskMapper taskTbRepository;
|
| | | @Autowired
|
| | | private TbSpecialCheckTaskLogMapper taskSpecialLogMapper;
|
| | | @Autowired
|
| | | private IRiskListService riskListService;
|
| | |
|
| | | @Override
|
| | | public ResultVO<List<TbSpecialCheckTaskLog>> selectSpecialCheckTaskLogPage(TbSpecialCheckTaskLogBO specialCheckTaskLogBO) {
|
| | | Integer pageIndex = specialCheckTaskLogBO.getPageNum();
|
| | | Integer pageSize = specialCheckTaskLogBO.getPageSize();
|
| | | if (pageIndex == 0 || pageSize == 0){
|
| | | return new ResultVO<>(ErrorCodes.REQUEST_PARAM_ERROR.getCode(),"当前页码或当前页显示数不能为0");
|
| | | }
|
| | |
|
| | | Page<TbSpecialCheckTaskLog> page = PageHelper.startPage(pageIndex, pageSize);
|
| | | taskSpecialLogMapper.selectSpecialCheckTaskLogPage(specialCheckTaskLogBO);
|
| | |
|
| | | Long total = page.getTotal();
|
| | | int count = total.intValue();
|
| | | List<TbSpecialCheckTaskLog> pageResult = null;
|
| | |
|
| | | ResultVO<List<TbSpecialCheckTaskLog>> resultVO = new ResultVO<>(ResultCodes.OK,pageResult);
|
| | |
|
| | | resultVO.setData(page.getResult());
|
| | | resultVO.setCount(count);
|
| | | resultVO.setCount((int) page.getTotal());
|
| | | resultVO.setPageNum(page.getPageNum());
|
| | | resultVO.setPageSize(page.getPageSize());
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | @Override
|
| | | public ResultVO<TbSpecialCheckTaskLog> addSpecialTask(TbSpecialCheckTaskLog tbSpecialCheckTaskLog) {
|
| | | User sysUser = getSysUser();
|
| | | ResultVO resultVO = new ResultVO<>();
|
| | | resultVO.setCode(ErrorCodes.REQUEST_PARAM_ERROR.getCode());
|
| | | if (tbSpecialCheckTaskLog.getHazardCode() == null){
|
| | | resultVO.setMsg("重大风险源不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | RiskList infoByRiskListNum = riskListService.getInfoByRiskListNum(tbSpecialCheckTaskLog.getHazardCode());
|
| | | if (ObjectUtils.isEmpty(infoByRiskListNum)){
|
| | | resultVO.setMsg("请检查重大风险源是否存在");
|
| | | return resultVO;
|
| | | }
|
| | | if (tbSpecialCheckTaskLog.getTaskId() == null){
|
| | | resultVO.setMsg("专项任务不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (tbSpecialCheckTaskLog.getCheckType() == null){
|
| | | resultVO.setMsg("检查类型不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (tbSpecialCheckTaskLog.getResultStatus() == null){
|
| | | resultVO.setMsg("结果不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (tbSpecialCheckTaskLog.getCheckDate() == null){
|
| | | resultVO.setMsg("检查日期不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | LocalDateTime dateTime = LocalDateTime.now();
|
| | | String uuid = UUID.randomUUID().toString();
|
| | |
|
| | | tbSpecialCheckTaskLog.setId(uuid);
|
| | | tbSpecialCheckTaskLog.setHazardSource(infoByRiskListNum.getRiskListName());
|
| | | tbSpecialCheckTaskLog.setCompanyCode("652310082");
|
| | | tbSpecialCheckTaskLog.setCreateDate(dateTime);
|
| | | tbSpecialCheckTaskLog.setUpdateDate(dateTime);
|
| | | tbSpecialCheckTaskLog.setCreateBy(sysUser.getUserName());
|
| | | tbSpecialCheckTaskLog.setUpdateBy(sysUser.getUserName());
|
| | | tbSpecialCheckTaskLog.setReportStatus((byte) 1);
|
| | | tbSpecialCheckTaskLog.setReportTime(null);
|
| | | tbSpecialCheckTaskLog.setDeleted((byte) 0);
|
| | |
|
| | | int saveResult = taskSpecialLogMapper.save(tbSpecialCheckTaskLog);
|
| | | if (saveResult == 0){
|
| | | resultVO.setCode(ResultCodes.SERVER_ADD_ERROR.getCode());
|
| | | resultVO.setMsg(ResultCodes.SERVER_ADD_ERROR.getDesc());
|
| | | return resultVO;
|
| | | }
|
| | | resultVO.setCode(ResultCodes.OK.getCode());
|
| | | resultVO.setMsg("新增任务成功");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | @Override
|
| | | public TbSpecialCheckTaskLog getSpecialCheckTaskLogByIndexId(Long id) {
|
| | | return taskSpecialLogMapper.getSpecialCheckTaskLogByIndexId(id);
|
| | | }
|
| | |
|
| | | @Override
|
| | | public ResultVO<TbSpecialCheckTaskLog> updateSpecialCheckTaskLog(TbSpecialCheckTaskLogUpdateBO updateBO) {
|
| | | User sysUser = getSysUser();
|
| | | ResultVO resultVO = new ResultVO<>();
|
| | | resultVO.setCode(ErrorCodes.REQUEST_PARAM_ERROR.getCode());
|
| | | if (updateBO.getIndexId() == null){
|
| | | resultVO.setMsg("任务不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | TbSpecialCheckTaskLog specialCheckTaskLogByIndexId = taskSpecialLogMapper.getSpecialCheckTaskLogByIndexId(updateBO.getIndexId());
|
| | | if (ObjectUtils.isEmpty(specialCheckTaskLogByIndexId)){
|
| | | resultVO.setMsg("任务不存在");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getHazardCode() == null){
|
| | | resultVO.setMsg("重大风险源不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | RiskList infoByRiskListNum = riskListService.getInfoByRiskListNum(updateBO.getHazardCode());
|
| | | if (ObjectUtils.isEmpty(infoByRiskListNum)){
|
| | | resultVO.setMsg("请检查重大风险源是否存在");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getTaskId() == null){
|
| | | resultVO.setMsg("专项任务不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getCheckType() == null){
|
| | | resultVO.setMsg("检查类型不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getResultStatus() == null){
|
| | | resultVO.setMsg("结果不能为空");
|
| | | return resultVO;
|
| | | }
|
| | | if (updateBO.getCheckDate() == null){
|
| | | resultVO.setMsg("检查日期不能为空");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | LocalDateTime dateTime = LocalDateTime.now();
|
| | | updateBO.setHazardSource(infoByRiskListNum.getRiskListName());
|
| | | updateBO.setUpdateDate(dateTime);
|
| | | updateBO.setUpdateBy(sysUser.getUserName());
|
| | | updateBO.setReportStatus((byte) 1);
|
| | |
|
| | | int updateResult = taskSpecialLogMapper.updateSpecialCheckTaskLogById(updateBO);
|
| | | if (updateResult == 0){
|
| | | resultVO.setCode(ResultCodes.SERVER_UPDATE_ERROR.getCode());
|
| | | resultVO.setMsg(ResultCodes.SERVER_UPDATE_ERROR.getDesc());
|
| | | return resultVO;
|
| | | }
|
| | | resultVO.setCode(ResultCodes.OK.getCode());
|
| | | resultVO.setMsg("更新任务成功");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | @Override
|
| | | public ResultVO<TbSpecialCheckTaskLog> deleteTbSpecialCheckTaskLog(TbSpecialCheckTaskLogUpdateBO updateBO) {
|
| | | User sysUser = getSysUser();
|
| | | ResultVO resultVO = new ResultVO<>();
|
| | | resultVO.setCode(ErrorCodes.REQUEST_PARAM_ERROR.getCode());
|
| | |
|
| | | if (updateBO.getIndexId() == null){
|
| | | resultVO.setMsg("任务为空,删除失败");
|
| | | return resultVO;
|
| | | }
|
| | | TbSpecialCheckTaskLog specialCheckTaskLogByIndexId = taskSpecialLogMapper.getSpecialCheckTaskLogByIndexId(updateBO.getIndexId());
|
| | | if (ObjectUtils.isEmpty(specialCheckTaskLogByIndexId)){
|
| | | resultVO.setMsg("任务不存在,删除失败");
|
| | | return resultVO;
|
| | | }
|
| | | TbSpecialCheckTaskLog tbSpecialCheckTaskLog = new TbSpecialCheckTaskLog();
|
| | | LocalDateTime dateTime = LocalDateTime.now();
|
| | |
|
| | | tbSpecialCheckTaskLog.setIndexId(updateBO.getIndexId());
|
| | | tbSpecialCheckTaskLog.setUpdateDate(dateTime);
|
| | | tbSpecialCheckTaskLog.setUpdateBy(sysUser.getUserName());
|
| | | tbSpecialCheckTaskLog.setReportStatus((byte) 1);
|
| | | tbSpecialCheckTaskLog.setDeleted((byte) 1);
|
| | |
|
| | | int deleteResult = taskSpecialLogMapper.deleteTbSpecialCheckTaskLog(tbSpecialCheckTaskLog);
|
| | | if (deleteResult == 0){
|
| | | resultVO.setCode(ResultCodes.SERVER_DEL_ERROR.getCode());
|
| | | resultVO.setMsg(ResultCodes.SERVER_DEL_ERROR.getDesc());
|
| | | return resultVO;
|
| | | }
|
| | | resultVO.setCode(ResultCodes.OK.getCode());
|
| | | resultVO.setMsg("删除成功");
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | |
|
| | | }
|
对比新文件 |
| | |
| | | package com.ruoyi.project.tr.specialCheck.service.impl;
|
| | |
|
| | | import com.github.pagehelper.Page;
|
| | | import com.github.pagehelper.PageHelper;
|
| | | import com.ruoyi.doublePrevention.enums.ErrorCodes;
|
| | | import com.ruoyi.doublePrevention.enums.ResultCodes;
|
| | | import com.ruoyi.doublePrevention.vo.ResultVO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckItemBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckScoreBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbBaseCheckTaskBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.BO.TbSpecialCheckTaskLogBO;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckItem;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckScore;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckTask;
|
| | | import com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog;
|
| | | import com.ruoyi.project.tr.specialCheck.mapper.*;
|
| | | import com.ruoyi.project.tr.specialCheck.service.TbBaseCheckService;
|
| | | import org.springframework.beans.factory.annotation.Autowired;
|
| | | import org.springframework.stereotype.Service;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | | @Service
|
| | | public class TbBaseCheckServiceImpl implements TbBaseCheckService {
|
| | |
|
| | | @Autowired
|
| | | private TbBaseCheckCompanyMapper companyTbRepository;
|
| | | @Autowired
|
| | | private TbBaseCheckItemMapper itemTbRepository;
|
| | | @Autowired
|
| | | private TbBaseCheckScoreMapper scoreTbRepository;
|
| | | @Autowired
|
| | | private TbBaseCheckTaskMapper taskTbRepository;
|
| | | @Autowired
|
| | | private TbSpecialCheckTaskLogMapper taskSpecialLogMapper;
|
| | |
|
| | | @Override
|
| | | public ResultVO<List<TbBaseCheckTask>> selectTbBaseCheckTaskPage(TbBaseCheckTaskBO tbBaseCheckTaskBO) {
|
| | |
|
| | | Integer pageIndex = tbBaseCheckTaskBO.getPageNum();
|
| | | Integer pageSize = tbBaseCheckTaskBO.getPageSize();
|
| | | if (pageIndex == 0 || pageSize == 0){
|
| | | return new ResultVO<>(ErrorCodes.REQUEST_PARAM_ERROR.getCode(),"当前页码或当前页显示数不能为0");
|
| | | }
|
| | |
|
| | | Page<TbBaseCheckTask> page = PageHelper.startPage(pageIndex, pageSize);
|
| | | taskTbRepository.selectTbBaseCheckTaskPage(tbBaseCheckTaskBO);
|
| | |
|
| | | Long total = page.getTotal();
|
| | | int count = total.intValue();
|
| | | List<TbBaseCheckTask> pageResult = null;
|
| | |
|
| | | ResultVO<List<TbBaseCheckTask>> resultVO = new ResultVO<>(ResultCodes.OK,pageResult);
|
| | |
|
| | | resultVO.setData(page.getResult());
|
| | | resultVO.setCount(count);
|
| | | resultVO.setCount((int) page.getTotal());
|
| | | resultVO.setPageNum(page.getPageNum());
|
| | | resultVO.setPageSize(page.getPageSize());
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | @Override
|
| | | public ResultVO<List<TbBaseCheckItem>> selectTbBaseCheckItemPage(TbBaseCheckItemBO tbBaseCheckItemBO) {
|
| | |
|
| | | Integer pageIndex = tbBaseCheckItemBO.getPageNum();
|
| | | Integer pageSize = tbBaseCheckItemBO.getPageSize();
|
| | | if (pageIndex == 0 || pageSize == 0){
|
| | | return new ResultVO<>(ErrorCodes.REQUEST_PARAM_ERROR.getCode(),"当前页码或当前页显示数不能为0");
|
| | | }
|
| | |
|
| | | Page<TbBaseCheckItem> page = PageHelper.startPage(pageIndex, pageSize);
|
| | | itemTbRepository.selectTbBaseCheckItemPage(tbBaseCheckItemBO);
|
| | |
|
| | | Long total = page.getTotal();
|
| | | int count = total.intValue();
|
| | | List<TbBaseCheckItem> pageResult = null;
|
| | |
|
| | | ResultVO<List<TbBaseCheckItem>> resultVO = new ResultVO<>(ResultCodes.OK,pageResult);
|
| | |
|
| | | resultVO.setData(page.getResult());
|
| | | resultVO.setCount(count);
|
| | | resultVO.setCount((int) page.getTotal());
|
| | | resultVO.setPageNum(page.getPageNum());
|
| | | resultVO.setPageSize(page.getPageSize());
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | | @Override
|
| | | public ResultVO<List<TbBaseCheckScore>> selectTbBaseCheckScorePage(TbBaseCheckScoreBO tbBaseCheckScoreBO) {
|
| | | Integer pageIndex = tbBaseCheckScoreBO.getPageNum();
|
| | | Integer pageSize = tbBaseCheckScoreBO.getPageSize();
|
| | | if (pageIndex == 0 || pageSize == 0){
|
| | | return new ResultVO<>(ErrorCodes.REQUEST_PARAM_ERROR.getCode(),"当前页码或当前页显示数不能为0");
|
| | | }
|
| | |
|
| | | Page<TbBaseCheckScore> page = PageHelper.startPage(pageIndex, pageSize);
|
| | | scoreTbRepository.selectTbBaseCheckScorePage(tbBaseCheckScoreBO);
|
| | |
|
| | | Long total = page.getTotal();
|
| | | int count = total.intValue();
|
| | | List<TbBaseCheckScore> pageResult = null;
|
| | |
|
| | | ResultVO<List<TbBaseCheckScore>> resultVO = new ResultVO<>(ResultCodes.OK,pageResult);
|
| | |
|
| | | resultVO.setData(page.getResult());
|
| | | resultVO.setCount(count);
|
| | | resultVO.setCount((int) page.getTotal());
|
| | | resultVO.setPageNum(page.getPageNum());
|
| | | resultVO.setPageSize(page.getPageSize());
|
| | | return resultVO;
|
| | | }
|
| | |
|
| | |
|
| | |
|
| | |
|
| | | }
|
| | |
| | | left join tr_risk_check_point c on c.plan_id = b.plan_id |
| | | where a.risk_type = 5 |
| | | </select> |
| | | |
| | | <!-- ResultVO<List<RiskList>> listHazardSource();--> |
| | | <select id="listHazardSource" resultMap="RiskListResult"> |
| | | SELECT * FROM tr_risk_list |
| | | where risk_list_num is not null |
| | | </select> |
| | | <!-- RiskList getInfoByRiskListNum(String hazardCode);--> |
| | | <select id="getInfoByRiskListNum" resultMap="RiskListResult"> |
| | | SELECT * FROM tr_risk_list |
| | | where risk_list_num = #{hazardCode} |
| | | </select> |
| | | </mapper> |
| | | |
对比新文件 |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper |
| | | PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.project.tr.specialCheck.mapper.TbBaseCheckCompanyMapper"> |
| | | |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckCompany"> |
| | | <id property="id" column="id"/> |
| | | |
| | | <result property="taskId" column="task_id"/> |
| | | <result property="companyCode" column="company_code"/> |
| | | <result property="bjxfbm" column="bjxfbm"/> |
| | | |
| | | <result property="deleted" column="deleted"/> |
| | | <result property="createBy" column="create_by"/> |
| | | <result property="createDate" column="create_date"/> |
| | | <result property="updateBy" column="update_by"/> |
| | | <result property="updateDate" column="update_date"/> |
| | | </resultMap> |
| | | |
| | | |
| | | </mapper> |
对比新文件 |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper |
| | | PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.project.tr.specialCheck.mapper.TbBaseCheckItemMapper"> |
| | | |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckItem"> |
| | | <id property="id" column="id"/> |
| | | |
| | | <result property="taskId" column="task_id"/> |
| | | <result property="checkName" column="check_name"/> |
| | | <result property="checkContent" column="check_content"/> |
| | | <result property="checkWay" column="check_way"/> |
| | | <result property="checkBasis" column="check_basis"/> |
| | | <result property="applicablePlace" column="applicable_place"/> |
| | | |
| | | <result property="deleted" column="deleted"/> |
| | | <result property="createBy" column="create_by"/> |
| | | <result property="createDate" column="create_date"/> |
| | | <result property="updateBy" column="update_by"/> |
| | | <result property="updateDate" column="update_date"/> |
| | | </resultMap> |
| | | |
| | | <!-- List<TbBaseCheckItem> selectTbBaseCheckItemPage(TbBaseCheckItemBO tbBaseCheckItemBO);--> |
| | | <select id="selectTbBaseCheckItemPage" resultMap="BaseResultMap"> |
| | | select * from tb_base_check_item |
| | | <where> |
| | | deleted = 0 |
| | | <if test="checkName != null"> |
| | | and task_name check_name concat('%',#{checkName},'%') |
| | | </if> |
| | | <if test="checkContent != null"> |
| | | and check_content like concat('%',#{checkContent},'%') |
| | | </if> |
| | | <if test="checkWay != null"> |
| | | and check_way like concat('%',#{checkWay},'%') |
| | | </if> |
| | | order by create_date desc |
| | | </where> |
| | | </select> |
| | | |
| | | </mapper> |
对比新文件 |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper |
| | | PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.project.tr.specialCheck.mapper.TbBaseCheckScoreMapper"> |
| | | |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckScore"> |
| | | <id property="id" column="id"/> |
| | | |
| | | <result property="checkItemId" column="check_item_id"/> |
| | | <result property="isReject" column="is_reject"/> |
| | | <result property="deductPoint" column="deduct_point"/> |
| | | <result property="deductIllustrate" column="deduct_illustrate"/> |
| | | |
| | | <result property="deleted" column="deleted"/> |
| | | <result property="createBy" column="create_by"/> |
| | | <result property="createDate" column="create_date"/> |
| | | <result property="updateBy" column="update_by"/> |
| | | <result property="updateDate" column="update_date"/> |
| | | </resultMap> |
| | | |
| | | <!-- List<TbBaseCheckScore> selectTbBaseCheckScorePage(TbBaseCheckScoreBO tbBaseCheckScoreBO);--> |
| | | <select id="selectTbBaseCheckScorePage" resultMap="BaseResultMap"> |
| | | select * from tb_base_check_score |
| | | <where> |
| | | deleted = 0 |
| | | <if test="isReject != null"> |
| | | and is_reject = #{isReject} |
| | | </if> |
| | | order by create_date desc |
| | | </where> |
| | | </select> |
| | | |
| | | </mapper> |
对比新文件 |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper |
| | | PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.project.tr.specialCheck.mapper.TbBaseCheckTaskMapper"> |
| | | |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.project.tr.specialCheck.domin.TbBaseCheckTask"> |
| | | <id property="id" column="id"/> |
| | | <result property="taskName" column="task_name"/> |
| | | <result property="taskStartTime" column="task_start_time"/> |
| | | <result property="taskEndTime" column="task_end_time"/> |
| | | <result property="taskTypeName" column="task_type_name"/> |
| | | <result property="taskContent" column="task_content"/> |
| | | <result property="deleted" column="deleted"/> |
| | | <result property="createBy" column="create_by"/> |
| | | <result property="createDate" column="create_date"/> |
| | | <result property="updateBy" column="update_by"/> |
| | | <result property="updateDate" column="update_date"/> |
| | | </resultMap> |
| | | |
| | | <!-- List<TbBaseCheckTaskMapper> selectTbBaseCheckTaskPage(TbBaseCheckTaskDTO tbBaseCheckTaskDTO);--> |
| | | <select id="selectTbBaseCheckTaskPage" resultMap="BaseResultMap"> |
| | | select * from tb_base_check_task |
| | | <where> |
| | | deleted = 0 |
| | | <if test="taskName != null"> |
| | | and task_name like concat('%',#{taskName},'%') |
| | | </if> |
| | | <if test="taskTypeName != null"> |
| | | and task_type_name like concat('%',#{taskTypeName},'%') |
| | | </if> |
| | | <if test="taskContent != null"> |
| | | and task_content like concat('%',#{taskContent},'%') |
| | | </if> |
| | | order by create_date desc |
| | | </where> |
| | | </select> |
| | | |
| | | |
| | | |
| | | </mapper> |
对比新文件 |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper |
| | | PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.project.tr.specialCheck.mapper.TbSpecialCheckItemDangerLogMapper"> |
| | | |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog"> |
| | | <id property="indexId" column="index_id"/> |
| | | <result property="id" column="id"/> |
| | | <result property="companyCode" column="company_code"/> |
| | | |
| | | <result property="dangerId" column="danger_id"/> |
| | | <result property="taskId" column="task_id"/> |
| | | <result property="checkType" column="check_type"/> |
| | | <result property="checkItemId" column="check_item_id"/> |
| | | <result property="checkScoreId" column="check_score_id"/> |
| | | <result property="checkDate" column="check_date"/> |
| | | <result property="checkPay" column="check_pay"/> |
| | | <result property="harmType" column="harm_type"/> |
| | | <result property="checkName" column="check_name"/> |
| | | <result property="checkContent" column="check_content"/> |
| | | <result property="checkWay" column="check_way"/> |
| | | <result property="checkBasis" column="check_basis"/> |
| | | <result property="applicablePlace" column="applicable_place"/> |
| | | <result property="isReject" column="is_reject"/> |
| | | <result property="deductPoint" column="deduct_point"/> |
| | | <result property="deductIllustrate" column="deduct_illustrate"/> |
| | | |
| | | <result property="deleted" column="deleted"/> |
| | | <result property="createBy" column="create_by"/> |
| | | <result property="createDate" column="create_date"/> |
| | | <result property="updateBy" column="update_by"/> |
| | | <result property="updateDate" column="update_date"/> |
| | | <result property="reportTime" column="report_time"/> |
| | | <result property="reportStatus" column="report_status"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <!-- List<TbSpecialCheckItemDangerLog> selectSpecialCheckItemDangerLogPage(TbSpecialCheckItemDangerLogBO itemDangerLogBO);--> |
| | | <select id="selectSpecialCheckItemDangerLogPage" resultMap="BaseResultMap"> |
| | | select * from tb_special_check_item_danger_log |
| | | <where> |
| | | deleted = 0 |
| | | <if test="checkWay != null"> |
| | | and check_way like concat('%',#{checkWay},'%') |
| | | </if> |
| | | <if test="reportStatus != null"> |
| | | and report_status = #{reportStatus} |
| | | </if> |
| | | order by create_date desc |
| | | </where> |
| | | </select> |
| | | <!-- TbSpecialCheckItemDangerLog getSpecialCheckItemDangerLogByIndexId(Long indexId);;--> |
| | | <select id="getSpecialCheckItemDangerLogByIndexId" resultMap="BaseResultMap"> |
| | | select * from tb_special_check_item_danger_log |
| | | where deleted = 0 and index_id = #{indexId} |
| | | </select> |
| | | |
| | | <!-- TbSpecialCheckTaskLog save(TbSpecialCheckTaskLog tbSpecialCheckTaskLog);--> |
| | | <insert id="save" parameterType="com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog"> |
| | | insert into tb_special_check_item_danger_log |
| | | <!-- (index_id,company_code)values(null,#{companyCode},#{hazardCode})--> |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | index_id, |
| | | <if test="id != null ">id,</if> |
| | | <if test="companyCode != null ">company_code,</if> |
| | | |
| | | <if test="dangerId != null ">danger_id,</if> |
| | | <if test="taskId != null ">task_id,</if> |
| | | <if test="checkType != null ">check_type,</if> |
| | | <if test="checkItemId != null ">check_item_id,</if> |
| | | <if test="checkScoreId != null ">check_score_id,</if> |
| | | <if test="checkDate != null ">check_date,</if> |
| | | |
| | | <if test="checkPay != null ">check_pay,</if> |
| | | <if test="harmType != null ">harm_type,</if> |
| | | <if test="checkName != null ">check_name,</if> |
| | | <if test="checkContent != null ">check_content,</if> |
| | | <if test="checkWay != null ">check_way,</if> |
| | | <if test="checkBasis != null ">check_basis,</if> |
| | | <if test="applicablePlace != null ">applicable_place,</if> |
| | | <if test="isReject != null ">is_reject,</if> |
| | | <if test="deductPoint != null ">deduct_point,</if> |
| | | <if test="deductIllustrate != null ">deduct_illustrate,</if> |
| | | |
| | | <if test="deleted != null">deleted,</if> |
| | | <if test="createBy != null">create_by,</if> |
| | | <if test="createDate != null">create_date,</if> |
| | | <if test="updateBy != null ">update_by,</if> |
| | | <if test="updateDate != null ">update_date,</if> |
| | | report_time, |
| | | <if test="reportStatus != null ">report_status,</if> |
| | | </trim> |
| | | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| | | null, |
| | | <if test="id != null ">#{id},</if> |
| | | <if test="companyCode != null ">#{companyCode},</if> |
| | | |
| | | <if test="dangerId != null ">#{dangerId},</if> |
| | | <if test="taskId != null ">#{taskId},</if> |
| | | <if test="checkType != null ">#{checkType},</if> |
| | | <if test="checkItemId != null ">#{checkItemId},</if> |
| | | <if test="checkScoreId != null ">#{checkScoreId},</if> |
| | | <if test="checkDate != null">#{checkDate},</if> |
| | | |
| | | <if test="checkPay != null ">#{checkPay},</if> |
| | | <if test="harmType != null ">#{harmType},</if> |
| | | <if test="checkName != null ">#{checkName},</if> |
| | | <if test="checkContent != null ">#{checkContent},</if> |
| | | <if test="checkWay != null ">#{checkWay},</if> |
| | | <if test="checkBasis != null">#{checkBasis},</if> |
| | | <if test="applicablePlace != null ">#{applicablePlace},</if> |
| | | <if test="isReject != null ">#{isReject},</if> |
| | | <if test="deductPoint != null ">#{deductPoint},</if> |
| | | <if test="deductIllustrate != null ">#{deductIllustrate},</if> |
| | | |
| | | |
| | | <if test="deleted != null ">#{deleted},</if> |
| | | <if test="createBy != null">#{createBy},</if> |
| | | <if test="createDate != null">#{createDate},</if> |
| | | <if test="updateBy != null ">#{updateBy},</if> |
| | | <if test="updateDate != null ">#{updateDate},</if> |
| | | null, |
| | | <if test="reportStatus != null ">#{reportStatus},</if> |
| | | </trim> |
| | | </insert> |
| | | |
| | | <!-- int updateSpecialCheckItemDangerLogById(TbSpecialCheckItemDangerLogUpdateBO updateBO);--> |
| | | <update id="updateSpecialCheckItemDangerLogById" parameterType="com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog"> |
| | | update tb_special_check_item_danger_log |
| | | <set> |
| | | <if test="dangerId != null "> |
| | | danger_id = #{dangerId}, |
| | | </if> |
| | | <if test="taskId != null"> |
| | | task_id = #{taskId}, |
| | | </if> |
| | | <if test="checkType != null"> |
| | | check_type = #{checkType}, |
| | | </if> |
| | | <if test="checkItemId != null"> |
| | | check_item_id = #{checkItemId}, |
| | | </if> |
| | | <if test="checkScoreId != null"> |
| | | check_score_id = #{checkScoreId}, |
| | | </if> |
| | | <if test="checkPay != null"> |
| | | check_pay = #{checkPay}, |
| | | </if> |
| | | <if test="harmType != null"> |
| | | harm_type = #{harmType}, |
| | | </if> |
| | | <if test="checkName != null"> |
| | | check_name = #{checkName}, |
| | | </if> |
| | | <if test="checkContent != null"> |
| | | check_content = #{checkContent}, |
| | | </if> |
| | | <if test="checkWay != null"> |
| | | check_way = #{checkWay}, |
| | | </if> |
| | | <if test="checkBasis != null"> |
| | | check_basis = #{checkBasis}, |
| | | </if> |
| | | <if test="applicablePlace != null"> |
| | | applicable_place = #{applicablePlace}, |
| | | </if> |
| | | <if test="isReject != null"> |
| | | is_reject = #{isReject}, |
| | | </if> |
| | | <if test="deductPoint != null"> |
| | | deduct_point = #{deductPoint}, |
| | | </if> |
| | | <if test="deductIllustrate != null"> |
| | | deduct_illustrate = #{deductIllustrate}, |
| | | </if> |
| | | |
| | | <if test="checkDate != null"> |
| | | check_date = #{checkDate}, |
| | | </if> |
| | | <if test="resultStatus != null"> |
| | | result_status = #{resultStatus}, |
| | | </if> |
| | | <if test="reportStatus != null"> |
| | | report_status = #{reportStatus}, |
| | | </if> |
| | | <if test="updateBy != null"> |
| | | update_by = #{updateBy}, |
| | | </if> |
| | | <if test="updateDate != null"> |
| | | update_date = #{updateDate}, |
| | | </if> |
| | | </set> |
| | | where index_id = #{indexId} and deleted = 0 |
| | | </update> |
| | | |
| | | <!-- int deleteTbSpecialCheckItemDangerLog(TbSpecialCheckItemDangerLog tbSpecialCheckItemDangerLog);--> |
| | | <update id="deleteTbSpecialCheckItemDangerLog" parameterType="com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog"> |
| | | update tb_special_check_item_danger_log |
| | | <set> |
| | | <if test="deleted != null "> |
| | | deleted = #{deleted}, |
| | | </if> |
| | | <if test="reportStatus != null"> |
| | | report_status = #{reportStatus}, |
| | | </if> |
| | | <if test="updateBy != null"> |
| | | update_by = #{updateBy}, |
| | | </if> |
| | | <if test="updateDate != null"> |
| | | update_date = #{updateDate}, |
| | | </if> |
| | | </set> |
| | | where index_id = #{indexId} and deleted = 0 |
| | | </update> |
| | | <!-- List<TbSpecialCheckItemDangerLog> listItemDangerReportTask();--> |
| | | <select id="listItemDangerReportTask" resultMap="BaseResultMap"> |
| | | select * from tb_special_check_item_danger_log |
| | | where deleted = 0 and report_status = 1 |
| | | </select> |
| | | <!-- void updateItemDangerReportStatusById(HandlerSpecialCheckReportParam handlerCJReportParam);--> |
| | | <update id="updateCheckTaskReportStatusById" parameterType="com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckItemDangerLog"> |
| | | update tb_special_check_item_danger_log |
| | | report_status = #{reportStatus}, |
| | | report_time = #{reportTime} |
| | | where id = #{indexId} and deleted = 0 |
| | | </update> |
| | | </mapper> |
对比新文件 |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper |
| | | PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.project.tr.specialCheck.mapper.TbSpecialCheckTaskLogMapper"> |
| | | |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog"> |
| | | <id property="indexId" column="index_id"/> |
| | | <result property="id" column="id"/> |
| | | <result property="companyCode" column="company_code"/> |
| | | <result property="hazardCode" column="hazard_code"/> |
| | | <result property="hazardSource" column="hazard_source"/> |
| | | <result property="taskId" column="task_id"/> |
| | | <result property="checkType" column="check_type"/> |
| | | <result property="checkDate" column="check_date"/> |
| | | <result property="resultStatus" column="result_status"/> |
| | | |
| | | <result property="deleted" column="deleted"/> |
| | | <result property="createBy" column="create_by"/> |
| | | <result property="createDate" column="create_date"/> |
| | | <result property="updateBy" column="update_by"/> |
| | | <result property="updateDate" column="update_date"/> |
| | | <result property="reportTime" column="report_time"/> |
| | | <result property="reportStatus" column="report_status"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <!-- List<TbSpecialCheckTaskLog> selectSpecialCheckTaskLogPage(TbSpecialCheckTaskLogBO specialCheckTaskLogBO);--> |
| | | <select id="selectSpecialCheckTaskLogPage" resultMap="BaseResultMap"> |
| | | select * from tb_special_check_task_log |
| | | <where> |
| | | deleted = 0 |
| | | <if test="hazardSource != null"> |
| | | and hazard_source like concat('%',#{hazardSource},'%') |
| | | </if> |
| | | <if test="reportStatus != null"> |
| | | and report_status = #{reportStatus} |
| | | </if> |
| | | order by create_date desc |
| | | </where> |
| | | </select> |
| | | <!-- ResultVO<TbSpecialCheckTaskLog> getSpecialCheckTaskLogByIndexId(Long id);--> |
| | | <select id="getSpecialCheckTaskLogByIndexId" resultMap="BaseResultMap"> |
| | | select * from tb_special_check_task_log |
| | | where deleted = 0 and index_id = #{indexId} |
| | | </select> |
| | | |
| | | <!-- TbSpecialCheckTaskLog save(TbSpecialCheckTaskLog tbSpecialCheckTaskLog);--> |
| | | <insert id="save" parameterType="com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog"> |
| | | insert into tb_special_check_task_log |
| | | <!-- (index_id,company_code)values(null,#{companyCode},#{hazardCode})--> |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | index_id, |
| | | <if test="id != null ">id,</if> |
| | | <if test="companyCode != null ">company_code,</if> |
| | | <if test="hazardCode != null ">hazard_code,</if> |
| | | <if test="hazardSource != null ">hazard_source,</if> |
| | | <if test="taskId != null ">task_id,</if> |
| | | <if test="checkType != null ">check_type,</if> |
| | | <if test="checkDate != null ">check_date,</if> |
| | | <if test="resultStatus != null ">result_status,</if> |
| | | <if test="deleted != null">deleted,</if> |
| | | <if test="createBy != null">create_by,</if> |
| | | <if test="createDate != null">create_date,</if> |
| | | <if test="updateBy != null ">update_by,</if> |
| | | <if test="updateDate != null ">update_date,</if> |
| | | report_time, |
| | | <if test="reportStatus != null ">report_status,</if> |
| | | </trim> |
| | | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| | | null, |
| | | <if test="id != null ">#{id},</if> |
| | | <if test="companyCode != null ">#{companyCode},</if> |
| | | <if test="hazardCode != null ">#{hazardCode},</if> |
| | | <if test="hazardSource != null ">#{hazardSource},</if> |
| | | <if test="taskId != null ">#{taskId},</if> |
| | | <if test="checkType != null ">#{checkType},</if> |
| | | <if test="checkDate != null ">#{checkDate},</if> |
| | | <if test="resultStatus != null">#{resultStatus},</if> |
| | | <if test="deleted != null ">#{deleted},</if> |
| | | <if test="createBy != null">#{createBy},</if> |
| | | <if test="createDate != null">#{createDate},</if> |
| | | <if test="updateBy != null ">#{updateBy},</if> |
| | | <if test="updateDate != null ">#{updateDate},</if> |
| | | null, |
| | | <if test="reportStatus != null ">#{reportStatus},</if> |
| | | </trim> |
| | | </insert> |
| | | |
| | | <!-- int updateSpecialCheckTaskLogById(TbSpecialCheckTaskLogUpdateBO updateBO);--> |
| | | <update id="updateSpecialCheckTaskLogById" parameterType="com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog"> |
| | | update tb_special_check_task_log |
| | | <set> |
| | | <if test="hazardCode != null "> |
| | | hazard_code = #{hazardCode}, |
| | | </if> |
| | | <if test="hazardSource != null"> |
| | | hazard_source = #{hazardSource}, |
| | | </if> |
| | | <if test="taskId != null"> |
| | | task_id = #{taskId}, |
| | | </if> |
| | | <if test="checkType != null"> |
| | | check_type = #{checkType}, |
| | | </if> |
| | | <if test="checkDate != null"> |
| | | check_date = #{checkDate}, |
| | | </if> |
| | | <if test="resultStatus != null"> |
| | | result_status = #{resultStatus}, |
| | | </if> |
| | | <if test="reportStatus != null"> |
| | | report_status = #{reportStatus}, |
| | | </if> |
| | | <if test="updateBy != null"> |
| | | update_by = #{updateBy}, |
| | | </if> |
| | | <if test="updateDate != null"> |
| | | update_date = #{updateDate}, |
| | | </if> |
| | | </set> |
| | | where index_id = #{indexId} and deleted = 0 |
| | | </update> |
| | | <!-- int deleteTbSpecialCheckTaskLog(TbSpecialCheckTaskLog tbSpecialCheckTaskLog);--> |
| | | <update id="deleteTbSpecialCheckTaskLog" parameterType="com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog"> |
| | | update tb_special_check_task_log |
| | | <set> |
| | | <if test="deleted != null "> |
| | | deleted = #{deleted}, |
| | | </if> |
| | | <if test="reportStatus != null"> |
| | | report_status = #{reportStatus}, |
| | | </if> |
| | | <if test="updateBy != null"> |
| | | update_by = #{updateBy}, |
| | | </if> |
| | | <if test="updateDate != null"> |
| | | update_date = #{updateDate}, |
| | | </if> |
| | | </set> |
| | | where index_id = #{indexId} and deleted = 0 |
| | | </update> |
| | | |
| | | <!-- List<TbSpecialCheckTaskLog> listTestRportTask();--> |
| | | <select id="listTestReportTask" resultMap="BaseResultMap"> |
| | | select * from tb_special_check_task_log |
| | | where deleted = 0 and report_status = 1 |
| | | </select> |
| | | <!-- void updateCheckTaskReportStatusById(HandlerCJReportParam handlerCJReportParam);--> |
| | | <update id="updateCheckTaskReportStatusById" parameterType="com.ruoyi.project.tr.specialCheck.domin.TbSpecialCheckTaskLog"> |
| | | update tb_special_check_task_log |
| | | report_status = #{reportStatus}, |
| | | report_time = #{reportTime} |
| | | where id = #{indexId} and deleted = 0 |
| | | </update> |
| | | </mapper> |