Skip to content

Commit

Permalink
#673 fix the bug
Browse files Browse the repository at this point in the history
  • Loading branch information
cmzdandan committed Feb 10, 2020
1 parent 3b807e5 commit 61e7e1c
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -150,12 +150,12 @@ private JobOverviewVo getJobOverviewByStatusAndPage(String namespace, JobStatus
}

Pageable pageable = PageableUtil.generatePageble(page, size);

List<JobConfig> targetJobs = getJobSubListByPage(unSystemJobs, pageable);
// 当 jobStatus 为null时,底层取数据已经做了分页,此处无需再次分页
List<JobConfig> targetJobs = jobStatus == null ? unSystemJobs : getJobSubListByPage(unSystemJobs, pageable);
List<JobOverviewJobVo> jobOverviewList = updateJobOverviewDetail(namespace, targetJobs, jobStatus);

jobOverviewVo.setJobs(jobOverviewList);
jobOverviewVo.setTotalNumber(unSystemJobs.size());
jobOverviewVo.setTotalNumber(jobService.countUnSystemJobsWithCondition(namespace, condition));
} catch (SaturnJobConsoleException e) {
throw e;
} catch (Exception e) {
Expand Down

0 comments on commit 61e7e1c

Please sign in to comment.