Started work on giving Gitalist a distinct look.
[catagits/Gitalist.git] / root / _shortlog.tt2
1 <table class='shortlog'>
2  <thead>
3   <tr>
4    <th>sha1</th>
5    <th>time</th>
6    <th>author</th>
7    <th>message</th>
8    <th>actions</th>
9   </tr>
10  </thead>
11
12  <tfoot>
13   <tr>
14    <td>sha1</td>
15    <td>time</td>
16    <td>author</td>
17    <td>message</td>
18    <td>actions</td>
19   </tr>
20  </tfoot>
21
22  <tbody>
23  [% FOREACH line IN log_lines %]
24   <tr>
25    <td>[% line.sha1.substr(0, 6) %]</td>
26    <td>[% time_since(line.authored_time) %]</td>
27    <td>[% line.author.name | html %]</td>
28    <td>
29     [% # XXX This needs to be moved into a Template::Plugin or some such.
30        cmt = line.comment.split("\n").0;
31        (cmt.length > 80 ? cmt.substr(0, 80) _ '...' : cmt) | html %]
32     <span class='refs'>
33      [% FOREACH ref IN refs.${line.sha1} %]
34      <span class='[% ref.search('^remotes/') ? 'remote' : 'head' %]'>
35       <a href='[% c.uri_for("shortlog", {h='refs/' _ ref}) %]'>[% ref.replace('^(remote|head)s/', '') %]</a>
36      </span>
37      [% END %]
38     </span>
39    </td>
40    <td class='action-list'>
41      <a href="[% c.uri_for("commit", {h=line.sha1}) %]">commit</a>
42      <a href="[% c.uri_for("commitdiff", {h=line.sha1}) %]">commitdiff</a>
43      <a href="[% c.uri_for("tree", {h=line.sha1, hb=line.tree_sha1}) %]">tree</a>
44    </td>
45   </tr>
46  [% END %]
47  </tbody>
48 </table>