Fix Changes section on build page. Now shows the changes of the first evaluation a build was part of compared to the previous one. Also separated previous builds from the changes section, as that was confusing sometimes.

This commit is contained in:
Rob Vermaas
2014-11-18 11:00:15 +01:00
parent a1b5020562
commit fd36d79581
2 changed files with 11 additions and 7 deletions

View File

@ -107,6 +107,11 @@ sub build_GET {
entity => $build
);
my ($eval2) = $c->stash->{eval}->jobset->jobsetevals->search(
{ hasnewbuilds => 1, id => { '<', $c->stash->{eval}->id } },
{ order_by => "id DESC", rows => 1 });
$c->stash->{otherEval} = $eval2 if defined $eval2;
# If this is an aggregate build, get its constituents.
$c->stash->{constituents} = [$c->stash->{build}->constituents_->search({}, {order_by => ["job"]})];
}