Fleshed out the /tree action and fixed paging.
[catagits/Gitalist.git] / templates / _diff_tree.tt2
CommitLineData
9dc3b9a5 1<table class='diff-tree'>
2 <thead>
3 <tr>
4 <td>file</td>
b4b4d0fd 5 <td>status</td>
9dc3b9a5 6 <td>actions</td>
7 </tr>
8 </thead>
9 <tbody>
b4b4d0fd 10 [% FOREACH line IN diff_tree -%]
9dc3b9a5 11 <tr>
b4b4d0fd 12 <td class='filename'>
13 [% line.file %]
14 </td>
15 <td class='status'>
16 [%
17 SWITCH line.status;
18 CASE 'R';
19 '[moved from ' _ line.src _ ' with ' _ line.sim _ '% similarity]';
20 CASE 'A';
21 '[new file with mode: ' _ line.modedst _ ']';
22 CASE 'D';
23 '[deleted file]';
24 END;
25 %]
26 </td>
9dc3b9a5 27 <td class='action-list'>
c73cd2ac 28 [% IF !line.is_new %]<a href="/blobdiff?p=[% project %];f=[% line.file %];h=[% commit.sha1 %];hp=[% commit.parent_sha1 %]">diff</a>[% END %]
9dc3b9a5 29 <a href="/blob?p=[% project %];f=[% line.file %];h=[% line.sha1 %];hb=[% commit.sha1 %]">blob</a>
63e220b9 30 [% IF !line.is_new %]<a href="/shortlog?p=[% project %];f=[% line.file %];hb=[% commit.sha1 %]">history</a>[% END %]
9dc3b9a5 31 </td>
32 </tr>
33 [% END %]
34 </tbody>
35 <tfoot>
36 <tr>
37 <td>file</td>
b4b4d0fd 38 <td>status</td>
9dc3b9a5 39 <td>actions</td>
40 </tr>
41 </tfoot>
42</table>