forked from lix-project/hydra
* Urgh. `-' had special significance in HTML form parameters...
This commit is contained in:
parent
af1e60a043
commit
163f3de2fa
|
@ -151,8 +151,8 @@ sub updateProject {
|
||||||
, nixexprinput => $nixExprInput
|
, nixexprinput => $nixExprInput
|
||||||
});
|
});
|
||||||
} else { # it's an existing jobset
|
} else { # it's an existing jobset
|
||||||
$jobset = ($project->jobsets->search({name => $baseName}))[0];
|
my $oldName = trim $c->request->params->{"jobset-$baseName-oldName"};
|
||||||
die unless defined $jobset;
|
$jobset = ($project->jobsets->search({name => $oldName}))[0] or die;
|
||||||
$jobset->update(
|
$jobset->update(
|
||||||
{ name => $jobsetName, description => $description
|
{ name => $jobsetName, description => $description
|
||||||
, nixexprpath => $nixExprPath, nixexprinput => $nixExprInput });
|
, nixexprpath => $nixExprPath, nixexprinput => $nixExprInput });
|
||||||
|
|
|
@ -67,6 +67,8 @@
|
||||||
|
|
||||||
<div class="jobset[% IF edit %] jobset-edit[% END %]" id="[% "jobset-$baseName" %]">
|
<div class="jobset[% IF edit %] jobset-edit[% END %]" id="[% "jobset-$baseName" %]">
|
||||||
|
|
||||||
|
<input type="hidden" [% HTML.attributes(name => "jobset-$baseName-oldName", value => jobset.name) %] />
|
||||||
|
|
||||||
<h3>
|
<h3>
|
||||||
[% IF edit %]<button type="button" onclick='$(this).parents(".jobset").remove()'><img src="/static/images/failure.gif" alt="Delete value" /></button>[% END %]
|
[% IF edit %]<button type="button" onclick='$(this).parents(".jobset").remove()'><img src="/static/images/failure.gif" alt="Delete value" /></button>[% END %]
|
||||||
[% IF jobset %]Jobset <tt>[% jobset.name %]</tt>[% ELSE %]New jobset[% END %]
|
[% IF jobset %]Jobset <tt>[% jobset.name %]</tt>[% ELSE %]New jobset[% END %]
|
||||||
|
@ -250,8 +252,8 @@
|
||||||
</script>
|
</script>
|
||||||
[% END %]
|
[% END %]
|
||||||
|
|
||||||
[% FOREACH jobset IN project.jobsets -%]
|
[% n = 0; FOREACH jobset IN project.jobsets -%]
|
||||||
[% INCLUDE renderJobset jobset=jobset baseName=jobset.name %]
|
[% INCLUDE renderJobset jobset=jobset baseName="e$n"; n = n + 1 %]
|
||||||
[% END -%]
|
[% END -%]
|
||||||
|
|
||||||
[% ELSE %]
|
[% ELSE %]
|
||||||
|
|
Loading…
Reference in a new issue