mirror of
https://github.com/correl/codereview.git
synced 2024-12-18 03:00:08 +00:00
Moved branch selection to the navigation template
This commit is contained in:
parent
00f020d24a
commit
223cc9aee6
2 changed files with 13 additions and 6 deletions
|
@ -8,12 +8,6 @@
|
|||
|
||||
{% block content %}
|
||||
<h2>Commit Log</h2>
|
||||
Branches:
|
||||
<ul>
|
||||
{% for branch, commit in repo.branches.items %}
|
||||
<li><a href="{% url codereview.browser.views.log repository=repository.name %}?c={{branch}}">{{ branch }}</a> ({{commit.id}})</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
<table class="vcs-log">
|
||||
<tr>
|
||||
<th>Commit Date</th>
|
||||
|
|
|
@ -1,5 +1,18 @@
|
|||
{% load vcs %}
|
||||
<h2><a href="{% url codereview.browser.views.log repository=repository.name %}?c={{ ref }}">{{ repository.name }}</a></h2>
|
||||
<h3>Branches</h3>
|
||||
<ul>
|
||||
{% for branch, commit in repo.branches.items %}
|
||||
<li>
|
||||
{% if ref == branch or ref == commit.id %}
|
||||
<strong>{{ branch }}</strong>
|
||||
{% else %}
|
||||
<a href="{% url codereview.browser.views.log repository=repository.name %}?c={{branch}}">{{ branch }}</a>
|
||||
{% endif %}
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
<h3>Browse</h3>
|
||||
{% if path|dirname %}
|
||||
<strong>{{ path|dirname }}/</strong><br />
|
||||
<a href="{% url codereview.browser.views.log repository=repository.name path=path|dirname %}?c={{ ref }}">Up one</a>
|
||||
|
|
Loading…
Reference in a new issue