Straightened up the model test and corresponding code.
[catagits/Gitalist.git] / templates / commit-nav.tt2
index 5a73ebd..24f38bb 100644 (file)
@@ -1,7 +1,8 @@
-[% FOR act IN ['summary', 'shortlog', 'log', 'commit', 'commitdiff', 'tree'];
-  ' | ' UNLESS loop.first;
-  IF act == action;
-    act;
-  ELSE; -%]
-  <a href="/[% act %]">[% act %]</a>
-[% END %]
+<div id='commit-nav'>
+    <a href="/summary?p=[% project %]">summary</a> |
+    <a href="/shortlog?p=[% project %];h=[% object.sha1 %]">shortlog</a> |
+    <a href="/log?p=[% project %];h=[% object.sha1 %]">log</a> |
+    <a href="/commit?p=[% project %];h=[% object.sha1 %]">commit</a> |
+    <a href="/commitdiff?p=[% project %];h=[% object.sha1 %]">commitdiff</a> |
+    <a href="/tree?p=[% project %];h=[% object.tree_sha1 %];hb=[% object.sha1 %]">tree</a>
+</div>