Browse Source

Merge remote-tracking branch 'origin/prod-20240506' into prod-20240506

zhongwei
yang_shj 6 months ago
parent
commit
5b0cb49670
  1. 2
      hzims-service/hzims-alarm/src/main/java/com/hnac/hzims/alarm/show/mapper/AlarmHandleMapper.xml
  2. 11
      hzims-service/hzims-alarm/src/main/java/com/hnac/hzims/alarm/show/wrapper/HandleWrapper.java

2
hzims-service/hzims-alarm/src/main/java/com/hnac/hzims/alarm/show/mapper/AlarmHandleMapper.xml

@ -4,7 +4,7 @@
<select id="selectHandlePage" resultType="com.hnac.hzims.alarm.config.vo.AlarmHandleVo">
SELECT H.*,S.NAME AS STATION_NAME,F.PROCESS_INSTANCE_ID
SELECT H.*,S.NAME AS STATION_NAME,F.PROCESS_INSTANCE_ID,F.HANDLE_USER_NAME as userName
FROM HZIMS_ALARM_HANDLE H
LEFT JOIN HZIMS_OPERATION.HZIMS_STATION S ON H.STATION_CODE = S.CODE
LEFT JOIN HZIMS_ALARM_HANDLE_FLOW F ON H.ALARM_ID = F.ALARM_ID

11
hzims-service/hzims-alarm/src/main/java/com/hnac/hzims/alarm/show/wrapper/HandleWrapper.java

@ -1,6 +1,7 @@
package com.hnac.hzims.alarm.show.wrapper;
import com.hnac.hzims.alarm.config.vo.AlarmHandleVo;
import com.hnac.hzims.common.logs.utils.StringUtils;
import org.springblade.core.mp.support.BaseEntityWrapper;
import org.springblade.core.tool.utils.ObjectUtil;
import org.springblade.system.user.cache.UserCache;
@ -17,11 +18,13 @@ public class HandleWrapper extends BaseEntityWrapper<AlarmHandleVo,AlarmHandleVo
@Override
public AlarmHandleVo entityVO(AlarmHandleVo entity) {
User createUser = UserCache.getUser(entity.getCreateUser());
if(ObjectUtil.isEmpty(createUser)){
return entity;
if (1==entity.getHandleWay()|| StringUtils.isNotEmpty(entity.getUserName())) {
User createUser = UserCache.getUser(entity.getCreateUser());
if (ObjectUtil.isEmpty(createUser)) {
return entity;
}
entity.setUserName(createUser.getRealName());
}
entity.setUserName(createUser.getRealName());
return entity;
}
}

Loading…
Cancel
Save