diff options
Diffstat (limited to 'archaeological_files/templates')
-rw-r--r-- | archaeological_files/templates/ishtar/blocks/window_file_nav.html | 12 | ||||
-rw-r--r-- | archaeological_files/templates/ishtar/sheet_file.html | 27 |
2 files changed, 17 insertions, 22 deletions
diff --git a/archaeological_files/templates/ishtar/blocks/window_file_nav.html b/archaeological_files/templates/ishtar/blocks/window_file_nav.html new file mode 100644 index 000000000..149603af8 --- /dev/null +++ b/archaeological_files/templates/ishtar/blocks/window_file_nav.html @@ -0,0 +1,12 @@ +{% extends "ishtar/blocks/window_nav.html" %} +{% load i18n %} +{% load url from future %} +{% block extra_actions %} +<a class='history-nav' href='{% url "operation_add" item.pk %}'> + <span class="fa-stack fa-lg"> + <i class="fa fa-circle fa-stack-2x"></i> + <i class="fa fa-plus fa-stack-1x fa-inverse"></i> + </span> + <br/>{%trans "Add an operation for this file" %} +</a> +{% endblock %} diff --git a/archaeological_files/templates/ishtar/sheet_file.html b/archaeological_files/templates/ishtar/sheet_file.html index a5879b3ec..9ff6e8356 100644 --- a/archaeological_files/templates/ishtar/sheet_file.html +++ b/archaeological_files/templates/ishtar/sheet_file.html @@ -1,31 +1,14 @@ {% extends "ishtar/sheet.html" %} -{% load i18n window_ope_tables window_field %} +{% load i18n window_ope_tables window_field window_header %} -{% block head_sheet %} -{{block.super}} -<h1>{% trans "Archaeological file"%}</h1> -{% endblock %} +{% block head_title %}{% trans "Archaeological file" %}{% endblock %} {% block content %} -{% if previous or next %} -<div class='tool'> -{%if previous%} -<a href="#" onclick='load_window("{% url show-historized-file item.pk previous|date:"c"%}");$("#{{window_id}}").hide();return false;'>{%trans "Previous version"%} ({{previous}})</a> -{% endif %} -{% if previous and next %} - {% endif %} -{%if next%} -<a href="#" onclick='if(confirm("{%trans "Are you sure to rollback to this version?"%}")){load_url("{% url revert-file item.pk item.history_date|date:"c"%}");closeAllWindows();load_window("{% url show-file item.pk None %}");}'>Rollback</a> - -<a href="#" onclick='load_window("{% url show-historized-file item.pk next|date:"c" %}");$("#{{window_id}}").hide();return false;'>{%trans "Next version"%} ({{next}})</a> -{% endif %} -</div> -{% endif %} -<div class='tool'>{%trans "Export as:"%} <a href='{% url show-file item.pk "odt" %}'>{%trans "OpenOffice.org file"%}</a>, <a href='{% url show-file item.pk "pdf" %}'>{%trans "PDF file"%}</a></div> -<hr/> -<div class='tool modify'><a href='{% url file_modify item.pk %}'>{% trans "Modify" %}</a></div> {% if can_add_operation %} -<div class='tool modify'><a href='{% url operation_add item.pk %}'>{%trans "Add an associated archaeological operation"%}</a></div> - +{% window_file_nav item window_id previous next %} +{% else %} +{% window_nav item window_id 'show-file' 'file_modify' 'show-historized-file' 'revert-file' previous next %} {%endif%} <h3>{% trans "General"%}</h3> |