##// END OF EJS Templates
diff_block: fix link to file revisions...
diff_block: fix link to file revisions Pull requests would link to file revisions in the wrong repo. That was obviously only visible when merging between different repos - but then it would link to a non-existing revision. diff_block is apparently used pull-request-style with the 'b' revision of the diff shown first. It thus also has to point at the 'other' repo which is where the other revision can be found.

File last commit:

r3506:9f9e7c93 beta
r3517:f8daaaf1 beta
Show More
compare_cs.html
36 lines | 1.5 KiB | text/html | HtmlLexer
## Changesets table !
<div class="container">
%if not c.cs_ranges:
<span class="empty_data">${_('No changesets')}</span>
%else:
<table class="compare_view_commits noborder">
%for cnt, cs in enumerate(c.cs_ranges):
<tr>
<td><div class="gravatar"><img alt="gravatar" src="${h.gravatar_url(h.email_or_none(cs.author),14)}"/></div></td>
<td>
%if cs.raw_id in c.statuses:
<div title="${c.statuses[cs.raw_id][1]}" class="changeset-status-ico"><img src="${h.url('/images/icons/flag_status_%s.png' % c.statuses[cs.raw_id][0])}" /></div>
%endif
</td>
<td>${h.link_to('r%s:%s' % (cs.revision,h.short_id(cs.raw_id)),h.url('changeset_home',repo_name=c.other_repo.repo_name,revision=cs.raw_id))}
%if c.as_form:
${h.hidden('revisions',cs.raw_id)}
%endif
</td>
<td><div class="author">${h.person(cs.author)}</div></td>
<td><span class="tooltip" title="${h.tooltip(h.age(cs.date))}">${cs.date}</span></td>
<td><div class="message tooltip" title="${h.tooltip(cs.message)}" style="white-space:normal">${h.urlify_commit(h.shorter(cs.message, 60),c.repo_name)}</div></td>
</tr>
%endfor
</table>
%if c.ancestor:
<span class="ancestor">${_('Ancestor')}:
${h.link_to(h.short_id(c.ancestor),h.url('changeset_home',repo_name=c.repo_name,revision=c.ancestor))}
</span>
%endif
%if c.as_form:
${h.hidden('ancestor_rev',c.ancestor)}
${h.hidden('merge_rev',c.cs_ranges[-1].raw_id)}
%endif
%endif
</div>