Fix uris in search results
[catagits/Gitalist.git] / root / repository / search.tt2
index 4d79196..9c003ce 100644 (file)
@@ -3,7 +3,7 @@
   [%# XXX Nabbed the HTML below from gitweb's log action. %]
   [% FOREACH result IN results %]
   <div class="header">
-   <a class="title" href="[% c.uri_for('commit', {h=result.sha1}) %]">
+   <a class="title" href="[% c.uri_for_action('/commit/commit', [ Repository.name, result.sha1 ]) %]">
     <span class="age">[% result.authored_time %]</span>
     [% short_cmt(result.comment) | html %]
    </a>
@@ -11,9 +11,9 @@
 
   <div class="title_text">
    <div class="log_link">
-     <a href="[% c.uri_for("", {h=result.sha1}) %]">commit</a>
-   | <a href="[% c.uri_for("", {h=result.sha1}) %]">commitdiff</a>
-   | <a href="[% c.uri_for("", {h=result.tree_sha1, hb=line.sha1}) %]">tree</a>
+     <a href="[% c.uri_for_action('/commit/commit', [Repository.name, result.sha1]) %]">commit</a>
+   | <a href="[% c.uri_for_action('/commit/diff_fancy', [Repository.name, result.sha1]) %]">commitdiff</a>
+   | <a href="[% c.uri_for_action('/commit/tree', [Repository.name, result.tree_sha1]); %][%# hb=line.sha1 %]">tree</a>
    </div>
    <i>[% result.author.name | html %] [% line.authored_time %]</i>
   </div>