diff --git a/src/lib/Hydra/Controller/Project.pm b/src/lib/Hydra/Controller/Project.pm index 36556054..8cdd912b 100644 --- a/src/lib/Hydra/Controller/Project.pm +++ b/src/lib/Hydra/Controller/Project.pm @@ -34,7 +34,7 @@ sub edit : Chained('project') PathPart Args(0) { requireProjectOwner($c, $c->stash->{project}); - $c->stash->{template} = 'project.tt'; + $c->stash->{template} = 'edit-project.tt'; $c->stash->{edit} = 1; } @@ -99,7 +99,7 @@ sub create : Path('/create-project') { requireMayCreateProjects($c); - $c->stash->{template} = 'project.tt'; + $c->stash->{template} = 'edit-project.tt'; $c->stash->{create} = 1; $c->stash->{edit} = 1; } diff --git a/src/root/common.tt b/src/root/common.tt index 542a03c3..1e60cd01 100644 --- a/src/root/common.tt +++ b/src/root/common.tt @@ -236,6 +236,15 @@ BLOCK maybeEditString; END; +BLOCK editString; + IF edit %] + param, name => param, value => value) %] /> + [% ELSE; + HTML.escape(value); + END; +END; + + BLOCK renderFullBuildLink; INCLUDE renderFullJobNameOfBuild build=build %] build [% build.id %][% END; diff --git a/src/root/edit-project.tt b/src/root/edit-project.tt new file mode 100644 index 00000000..d87cd457 --- /dev/null +++ b/src/root/edit-project.tt @@ -0,0 +1,57 @@ +[% WRAPPER layout.tt title=(create ? "New Project" : "Editing project $project.name") %] +[% PROCESS common.tt %] + +
+ +[% END %] diff --git a/src/root/jobset.tt b/src/root/jobset.tt index 7662f9b9..d7ff8118 100644 --- a/src/root/jobset.tt +++ b/src/root/jobset.tt @@ -22,7 +22,7 @@