Commit eb21b9d2 by benjaoming

bootstrap 3 compat on attachments plugin

parent 826b082d
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
<table class="table table-bordered table-striped"> <table class="table table-bordered table-striped">
<tr> <tr>
<th colspan="4"> <th colspan="4">
<h4> <h4 style="margin-top:0;">
<a href="{% url 'wiki:attachments_download' path=urlpath.path article_id=article.id attachment_id=attachment.id %}">{{ attachment.current_revision.get_filename }}</a> <a href="{% url 'wiki:attachments_download' path=urlpath.path article_id=article.id attachment_id=attachment.id %}">{{ attachment.current_revision.get_filename }}</a>
<span class="badge">{{ attachment.current_revision.created|naturaltime }}</span> <span class="badge">{{ attachment.current_revision.created|naturaltime }}</span>
{% if attachment.current_revision.deleted %} {% if attachment.current_revision.deleted %}
...@@ -31,17 +31,17 @@ ...@@ -31,17 +31,17 @@
<td style="width: 25%; text-align: right; white-space: nowrap;" rowspan="2"> <td style="width: 25%; text-align: right; white-space: nowrap;" rowspan="2">
{% if attachment|can_write:user %} {% if attachment|can_write:user %}
{% if not attachment.current_revision.deleted %} {% if not attachment.current_revision.deleted %}
<a href="{% url 'wiki:attachments_replace' path=urlpath.path article_id=article.id attachment_id=attachment.id %}" class="btn btn-default">{% trans "Replace" %}</a> <a href="{% url 'wiki:attachments_replace' path=urlpath.path article_id=article.id attachment_id=attachment.id %}" class="btn btn-default btn-small">{% trans "Replace" %}</a>
{% if attachment.article = article %} {% if attachment.article = article %}
<a href="{% url 'wiki:attachments_delete' path=urlpath.path article_id=article.id attachment_id=attachment.id %}" class="btn btn-default">{% trans "Delete" %}</a> <a href="{% url 'wiki:attachments_delete' path=urlpath.path article_id=article.id attachment_id=attachment.id %}" class="btn btn-default btn-small">{% trans "Delete" %}</a>
{% else %} {% else %}
<a href="{% url 'wiki:attachments_delete' path=urlpath.path article_id=article.id attachment_id=attachment.id %}" class="btn btn-default">{% trans "Detach" %}</a> <a href="{% url 'wiki:attachments_delete' path=urlpath.path article_id=article.id attachment_id=attachment.id %}" class="btn btn-default btn-small">{% trans "Detach" %}</a>
{% endif %} {% endif %}
{% else %} {% else %}
Deleted Deleted
{% endif %} {% endif %}
{% endif %} {% endif %}
<p style="margin-top: 10px;"> <p style="margin-top: 10px; margin-bottom:0;">
<a href="{% url 'wiki:attachments_history' path=urlpath.path article_id=article.id attachment_id=attachment.id %}"> <a href="{% url 'wiki:attachments_history' path=urlpath.path article_id=article.id attachment_id=attachment.id %}">
<span class="icon-time"></span> <span class="icon-time"></span>
{% trans "File history" %} ({{ attachment.attachmentrevision_set.all.count }} {% trans "revisions" %}) {% trans "File history" %} ({{ attachment.attachmentrevision_set.all.count }} {% trans "revisions" %})
...@@ -82,7 +82,7 @@ ...@@ -82,7 +82,7 @@
{% else %} {% else %}
<form method="POST" class="form-vertical" id="attachment_form" enctype="multipart/form-data"> <form method="POST" class="form-vertical" id="attachment_form" enctype="multipart/form-data">
{% wiki_form form %} {% wiki_form form %}
<button type="submit" name="save" value="1" class="btn btn-default btn-large"> <button type="submit" name="save" value="1" class="btn btn-primary">
{% trans "Upload file" %} {% trans "Upload file" %}
</button> </button>
</form> </form>
...@@ -102,12 +102,15 @@ ...@@ -102,12 +102,15 @@
<div id="collapse_add" class="accordion-body collapse"> <div id="collapse_add" class="accordion-body collapse">
<div class="accordion-inner"> <div class="accordion-inner">
<p>{% trans "You can reuse files from other articles. These files are subject to updates on other articles which may or may not be a good thing." %}</p> <p>{% trans "You can reuse files from other articles. These files are subject to updates on other articles which may or may not be a good thing." %}</p>
<form method="GET" action="{% url 'wiki:attachments_search' path=urlpath.path article_id=article.id %}" class="form-search"> <form method="GET" action="{% url 'wiki:attachments_search' path=urlpath.path article_id=article.id %}" class="wiki-form-block">
{{ search_form.query }} <div class="input-group">
<button class="btn btn-default"> {{ search_form.query }}
<span class="icon-search"></span> <span class="input-group-btn">
{% trans "Search" %} <button class="btn btn-default" type="submit">
</button> <span class="icon-search"></span>
</button>
</span>
</div><!-- /input-group -->
</form> </form>
</div> </div>
</div> </div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment