|
@ -1,16 +1,13 @@ |
|
|
package com.zc.business.service.impl; |
|
|
package com.zc.business.service.impl; |
|
|
|
|
|
|
|
|
import com.alibaba.fastjson.JSON; |
|
|
import com.alibaba.fastjson.JSON; |
|
|
import com.alibaba.fastjson.JSONObject; |
|
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|
|
import com.ruoyi.common.core.domain.AjaxResult; |
|
|
import com.ruoyi.common.core.domain.AjaxResult; |
|
|
import com.ruoyi.common.utils.DateUtils; |
|
|
import com.ruoyi.common.utils.DateUtils; |
|
|
import com.ruoyi.common.utils.SecurityUtils; |
|
|
import com.ruoyi.common.utils.SecurityUtils; |
|
|
import com.ruoyi.common.utils.StringUtils; |
|
|
|
|
|
import com.ruoyi.common.utils.uuid.IdUtils; |
|
|
import com.ruoyi.common.utils.uuid.IdUtils; |
|
|
import com.ruoyi.system.service.ISysDeptService; |
|
|
import com.ruoyi.system.service.ISysDeptService; |
|
|
import com.sun.xml.bind.v2.TODO; |
|
|
|
|
|
import com.zc.business.domain.*; |
|
|
import com.zc.business.domain.*; |
|
|
import com.zc.business.enums.EventSubclassEnum; |
|
|
import com.zc.business.enums.EventSubclassEnum; |
|
|
import com.zc.business.enums.ValueConverter; |
|
|
import com.zc.business.enums.ValueConverter; |
|
@ -21,8 +18,6 @@ import com.zc.business.service.IMiddleDatabaseService; |
|
|
import com.zc.business.utils.diff.Diff; |
|
|
import com.zc.business.utils.diff.Diff; |
|
|
import com.zc.business.utils.diff.model.Result; |
|
|
import com.zc.business.utils.diff.model.Result; |
|
|
import com.zc.common.core.websocket.WebSocketService; |
|
|
import com.zc.common.core.websocket.WebSocketService; |
|
|
import org.junit.Test; |
|
|
|
|
|
import org.apache.poi.ss.formula.functions.T; |
|
|
|
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
import org.springframework.stereotype.Service; |
|
|
import org.springframework.stereotype.Service; |
|
|
import org.springframework.transaction.annotation.Transactional; |
|
|
import org.springframework.transaction.annotation.Transactional; |
|
@ -85,6 +80,7 @@ public class DcEventServiceImpl extends ServiceImpl<DcEventMapper, DcEvent> impl |
|
|
private final String HAPPEN = "发生"; |
|
|
private final String HAPPEN = "发生"; |
|
|
private final String EVENT = "事件"; |
|
|
private final String EVENT = "事件"; |
|
|
private final String SUBEVENT = "0"; |
|
|
private final String SUBEVENT = "0"; |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 查询事件信息 |
|
|
* 查询事件信息 |
|
|
* |
|
|
* |
|
@ -141,7 +137,6 @@ public class DcEventServiceImpl extends ServiceImpl<DcEventMapper, DcEvent> impl |
|
|
String dcEventId = dcEvent.getId(); |
|
|
String dcEventId = dcEvent.getId(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//获取事件类型
|
|
|
//获取事件类型
|
|
|
int eventType = Math.toIntExact(dcEvent.getEventType()); |
|
|
int eventType = Math.toIntExact(dcEvent.getEventType()); |
|
|
|
|
|
|
|
@ -411,6 +406,7 @@ public class DcEventServiceImpl extends ServiceImpl<DcEventMapper, DcEvent> impl |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 推送 事件信息 |
|
|
* 推送 事件信息 |
|
|
|
|
|
* |
|
|
* @param dcEvent |
|
|
* @param dcEvent |
|
|
*/ |
|
|
*/ |
|
|
private void extracted(DcEvent dcEvent) { |
|
|
private void extracted(DcEvent dcEvent) { |
|
@ -547,12 +543,11 @@ public class DcEventServiceImpl extends ServiceImpl<DcEventMapper, DcEvent> impl |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
|
|
|
* @param dcEventList |
|
|
|
|
|
* @return int |
|
|
* @Description 批量添加事件 |
|
|
* @Description 批量添加事件 |
|
|
* |
|
|
|
|
|
* @author liuwenge |
|
|
* @author liuwenge |
|
|
* @date 2024/3/18 8:42 |
|
|
* @date 2024/3/18 8:42 |
|
|
* @param dcEventList |
|
|
|
|
|
* @return int |
|
|
|
|
|
*/ |
|
|
*/ |
|
|
@Override |
|
|
@Override |
|
|
public boolean batchInsertDcEventWarning(List<DcEvent> dcEventList) { |
|
|
public boolean batchInsertDcEventWarning(List<DcEvent> dcEventList) { |
|
@ -739,7 +734,6 @@ public class DcEventServiceImpl extends ServiceImpl<DcEventMapper, DcEvent> impl |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 批量删除事件信息 |
|
|
* 批量删除事件信息 |
|
|
* |
|
|
* |
|
@ -958,7 +952,6 @@ public class DcEventServiceImpl extends ServiceImpl<DcEventMapper, DcEvent> impl |
|
|
@Override |
|
|
@Override |
|
|
public int updateDcEventState(String id, int state) { |
|
|
public int updateDcEventState(String id, int state) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
int i = dcEventMapper.updateDcEventState(id, state); |
|
|
int i = dcEventMapper.updateDcEventState(id, state); |
|
|
if (i > 0) { |
|
|
if (i > 0) { |
|
|
DcEvent dcEvent = dcEventMapper.selectDcEventMainById(id); |
|
|
DcEvent dcEvent = dcEventMapper.selectDcEventMainById(id); |
|
@ -998,13 +991,12 @@ public class DcEventServiceImpl extends ServiceImpl<DcEventMapper, DcEvent> impl |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* @Description 事件信息比对 |
|
|
|
|
|
* |
|
|
|
|
|
* @author liuwenge |
|
|
|
|
|
* @date 2024/4/10 16:24 |
|
|
|
|
|
* @param oldEvent 旧数据 |
|
|
* @param oldEvent 旧数据 |
|
|
* @param newEvent 新数据 |
|
|
* @param newEvent 新数据 |
|
|
* @return java.lang.String |
|
|
* @return java.lang.String |
|
|
|
|
|
* @Description 事件信息比对 |
|
|
|
|
|
* @author liuwenge |
|
|
|
|
|
* @date 2024/4/10 16:24 |
|
|
*/ |
|
|
*/ |
|
|
public String comparisonInfo(DcEvent oldEvent, DcEvent newEvent) { |
|
|
public String comparisonInfo(DcEvent oldEvent, DcEvent newEvent) { |
|
|
String context = ""; |
|
|
String context = ""; |
|
@ -1361,12 +1353,11 @@ public class DcEventServiceImpl extends ServiceImpl<DcEventMapper, DcEvent> impl |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
|
|
|
* @param eventId 事件id |
|
|
|
|
|
* @return com.ruoyi.common.core.domain.AjaxResult |
|
|
* @Description 查询事件流程状态 |
|
|
* @Description 查询事件流程状态 |
|
|
* |
|
|
|
|
|
* @author liuwenge |
|
|
* @author liuwenge |
|
|
* @date 2024/4/11 11:19 |
|
|
* @date 2024/4/11 11:19 |
|
|
* @param eventId 事件id |
|
|
|
|
|
* @return com.ruoyi.common.core.domain.AjaxResult |
|
|
|
|
|
*/ |
|
|
*/ |
|
|
@Override |
|
|
@Override |
|
|
public AjaxResult getProcessNode(String eventId) { |
|
|
public AjaxResult getProcessNode(String eventId) { |
|
@ -1375,12 +1366,11 @@ public class DcEventServiceImpl extends ServiceImpl<DcEventMapper, DcEvent> impl |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
|
|
|
* @param eventId |
|
|
|
|
|
* @return com.ruoyi.common.core.domain.AjaxResult |
|
|
* @Description 解除事件 |
|
|
* @Description 解除事件 |
|
|
* |
|
|
|
|
|
* @author liuwenge |
|
|
* @author liuwenge |
|
|
* @date 2024/4/11 14:13 |
|
|
* @date 2024/4/11 14:13 |
|
|
* @param eventId |
|
|
|
|
|
* @return com.ruoyi.common.core.domain.AjaxResult |
|
|
|
|
|
*/ |
|
|
*/ |
|
|
@Override |
|
|
@Override |
|
|
public AjaxResult completeEvent(String eventId) { |
|
|
public AjaxResult completeEvent(String eventId) { |
|
@ -1415,12 +1405,11 @@ public class DcEventServiceImpl extends ServiceImpl<DcEventMapper, DcEvent> impl |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
|
|
|
* @param eventId |
|
|
|
|
|
* @return com.ruoyi.common.core.domain.AjaxResult |
|
|
* @Description 无需清障 |
|
|
* @Description 无需清障 |
|
|
* |
|
|
|
|
|
* @author liuwenge |
|
|
* @author liuwenge |
|
|
* @date 2024/4/11 14:13 |
|
|
* @date 2024/4/11 14:13 |
|
|
* @param eventId |
|
|
|
|
|
* @return com.ruoyi.common.core.domain.AjaxResult |
|
|
|
|
|
*/ |
|
|
*/ |
|
|
@Override |
|
|
@Override |
|
|
public AjaxResult skipClear(String eventId) { |
|
|
public AjaxResult skipClear(String eventId) { |
|
|