This commit is contained in:
杜建超 2020-12-11 09:15:51 +08:00
parent 6716964d5b
commit 8be3f01815

View File

@ -19,6 +19,8 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
import java.util.Optional;
import java.util.function.Consumer;
import java.util.function.Function;
import java.util.stream.Collectors;
@ -114,8 +116,11 @@ public class TaskProcessRecordServiceImpl extends ServiceImpl<TaskProcessRecordM
StaffEntity staffEntity = staffService.selectStaffById(resultDetail.getStaffId());
List<TaskProcessRecordDto> dtos = list;
for(TaskProcessRecordDto dto:dtos){
dto.setAvatar(staffEntity.getAvatar());
dto.setStaffName(staffEntity.getName());
Optional.ofNullable(staffEntity).ifPresent(staffEntity1 -> {
dto.setAvatar(staffEntity1.getAvatar());
dto.setStaffName(staffEntity1.getName());
});
}
}
return pageUtils;