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