* In the last succeeded / job status queries, use the Builds.isCurrent

column instead of Jobs.active.
This commit is contained in:
Eelco Dolstra
2009-10-07 15:45:17 +00:00
parent 48d8871dbc
commit 16f2d003b2
7 changed files with 16 additions and 21 deletions

View File

@ -15,7 +15,6 @@ sub job : Chained('/') PathPart('job') CaptureArgs(3) {
or notFound($c, "Job $projectName:$jobsetName:$jobName doesn't exist.");
$c->stash->{project} = $c->stash->{job}->project;
$c->stash->{jobset} = $c->stash->{job}->jobset;
$c->stash->{showInactiveJobs} = 1;
}

View File

@ -28,7 +28,7 @@ sub index : Chained('jobset') PathPart('') Args(0) {
getBuildStats($c, scalar $c->stash->{jobset}->builds);
$c->stash->{activeJobs} = [$c->stash->{jobset}->jobs->search({active => 1})];
$c->stash->{activeJobs} = [$c->stash->{jobset}->builds->search({isCurrent => 1}, {select => ["job"], distinct => 1})];
$c->stash->{inactiveJobs} = [$c->stash->{jobset}->jobs->search({active => 0})];
}