fix 用户id翻译成名称时id取错得bug

pull/2/head
xiex@fjhrt.com 2022-03-22 17:34:14 +08:00
parent 6dbb1248a8
commit 5614a8495f
1 changed files with 1 additions and 1 deletions

View File

@ -30,7 +30,7 @@ public interface OperateLogConvert {
default List<OperateLogExcelVO> convertList(List<OperateLogDO> list, Map<Long, AdminUserDO> userMap) { default List<OperateLogExcelVO> convertList(List<OperateLogDO> list, Map<Long, AdminUserDO> userMap) {
return list.stream().map(operateLog -> { return list.stream().map(operateLog -> {
OperateLogExcelVO excelVO = convert02(operateLog); OperateLogExcelVO excelVO = convert02(operateLog);
MapUtils.findAndThen(userMap, operateLog.getId(), user -> excelVO.setUserNickname(user.getNickname())); MapUtils.findAndThen(userMap, operateLog.getUserId(), user -> excelVO.setUserNickname(user.getNickname()));
excelVO.setSuccessStr(SUCCESS.getCode().equals(operateLog.getResultCode()) ? "成功" : "失败"); excelVO.setSuccessStr(SUCCESS.getCode().equals(operateLog.getResultCode()) ? "成功" : "失败");
return excelVO; return excelVO;
}).collect(Collectors.toList()); }).collect(Collectors.toList());