[PATCH 4 of 6] templates/changeset: display successor changesets

Andrew Shadura andrew at shadura.me
Tue Jul 28 11:02:40 UTC 2015


# HG changeset patch
# User Sean Farley <sean.michael.farley at gmail.com>
# Date 1406668550 18000
#      Tue Jul 29 16:15:50 2014 -0500
# Node ID 28e4930d9bc2593c6e2b43629dc8b1f9122a7a5e
# Parent  b08991c9389cbc64e5145b71629079fa7059fa6c
templates/changeset: display successor changesets

diff --git a/kallithea/templates/changeset/changeset.html b/kallithea/templates/changeset/changeset.html
--- a/kallithea/templates/changeset/changeset.html
+++ b/kallithea/templates/changeset/changeset.html
@@ -129,6 +129,21 @@
                        ${_('Transplanted from:')} ${h.link_to(h.short_id(rev),h.url('changeset_home',repo_name=c.repo_name,revision=rev))}
                      </div>
                      %endif
+
+                     % if hasattr(c.changeset, 'successors') and c.changeset.successors:
+                     <div class='successors'>
+                       <span class='successors_header'>${_('Replaced by:')} </span>
+                       % for i, s in enumerate(c.changeset.successors):
+                           <%
+                           comma = ""
+                           if i != len(c.changeset.successors)-1:
+                             comma = ", "
+                           %>
+                         <a class='successors_hash' href="${h.url('changeset_home',repo_name=c.repo_name, revision=s)}">${s}</a>${comma}
+                       % endfor
+                     </div>
+                     % endif
+
                      <div class="message">${h.urlify_commit(c.changeset.message, c.repo_name)}</div>
                 </div>
             </div>


More information about the kallithea-general mailing list