aboutsummaryrefslogtreecommitdiffstats
path: root/servo/templates/admin/queues
diff options
context:
space:
mode:
authorFilipp Lepalaan <filipp@mac.com>2015-08-04 10:11:24 +0300
committerFilipp Lepalaan <filipp@mac.com>2015-08-04 10:11:24 +0300
commit63b0fc6269b38edf7234b9f151b80d81f614c0a3 (patch)
tree555de3068f33f8dddb4619349bbea7d9b7c822fd /servo/templates/admin/queues
downloadServo-63b0fc6269b38edf7234b9f151b80d81f614c0a3.tar.gz
Servo-63b0fc6269b38edf7234b9f151b80d81f614c0a3.tar.bz2
Servo-63b0fc6269b38edf7234b9f151b80d81f614c0a3.zip
Initial commit
First public commit
Diffstat (limited to 'servo/templates/admin/queues')
-rw-r--r--servo/templates/admin/queues/form.html81
-rw-r--r--servo/templates/admin/queues/index.html6
-rw-r--r--servo/templates/admin/queues/remove.html17
3 files changed, 104 insertions, 0 deletions
diff --git a/servo/templates/admin/queues/form.html b/servo/templates/admin/queues/form.html
new file mode 100644
index 0000000..119275a
--- /dev/null
+++ b/servo/templates/admin/queues/form.html
@@ -0,0 +1,81 @@
+{% extends "admin/queues/index.html" %}
+{% load i18n %}
+
+{% block third_column %}
+<form method="post" action="" accept-charset="utf-8" class="form-horizontal" enctype="multipart/form-data">
+ {% csrf_token %}
+ {{ formset.management_form }}
+ <ul class="nav nav-tabs">
+ <li class="active"><a href="#tab1" data-toggle="tab">{% trans "General" %}</a></li>
+ <li><a href="#tab2" data-toggle="tab">{% trans "Statuses" %}</a></li>
+ <li><a href="#tab5" data-toggle="tab">{% trans "Defaults" %}</a></li>
+ <li><a href="#tab3" data-toggle="tab">{% trans "GSX" %}</a></li>
+ <li><a href="#tab4" data-toggle="tab">{% trans "Templates" %}</a></li>
+ <li><a href="#tab6" data-toggle="tab">{% trans "Users" %}</a></li>
+ </ul>
+ <div class="tab-content">
+ <div class="tab-pane active" id="tab1">
+ {% include "form_field_snippet.html" with field=form.title %}
+ {% include "form_field_snippet.html" with field=form.priority %}
+ {% include "form_field_snippet.html" with field=form.description %}
+ <!--{% include "form_field_snippet.html" with field=form.keywords %}//-->
+ {% include "form_field_snippet.html" with field=form.locations %}
+ </div>
+ <div class="tab-pane" id="tab2">
+ <table class="table table-condensed" id="table-queue-status">
+ <thead>
+ <tr>
+ <th>{% trans "Status" %}</th>
+ <th colspan="3">{% trans "Time limits" %}</th>
+ <th style="width:30px" class="text-center">{% trans "Delete" %}</th>
+ </tr>
+ </thead>
+ <tbody>
+ {% for form in formset %}
+ <tr class="form">
+ {% for field in form %}
+ {% if field.is_hidden %}
+ {{ field }}
+ {% else %}
+ <td>{{ field }}</td>
+ {% endif %}
+ {% endfor %}
+ </tr>
+ {% endfor %}
+ </tbody>
+ </table>
+ <a class="btn" id="add_more"><i class="icon-plus"></i> {% trans "Add Status" %}</a>
+ </div>
+ <div class="tab-pane" id="tab5">
+ {% include "form_field_snippet.html" with field=form.status_created %}
+ {% include "form_field_snippet.html" with field=form.status_assigned %}
+ {% include "form_field_snippet.html" with field=form.status_products_ordered %}
+ {% include "form_field_snippet.html" with field=form.status_products_received %}
+ {% include "form_field_snippet.html" with field=form.status_repair_completed %}
+ {% include "form_field_snippet.html" with field=form.status_dispatched %}
+ {% include "form_field_snippet.html" with field=form.status_closed %}
+ </div>
+ <div class="tab-pane" id="tab3">
+ {% include "form_field_snippet.html" with field=form.gsx_soldto %}
+ </div>
+ <div class="tab-pane" id="tab4">
+ {% include "form_field_snippet.html" with field=form.order_template %}
+ {% include "form_field_snippet.html" with field=form.quote_template %}
+ {% include "form_field_snippet.html" with field=form.receipt_template %}
+ {% include "form_field_snippet.html" with field=form.dispatch_template %}
+ </div>
+ <div class="tab-pane" id="tab6">
+ {% include "form_field_snippet.html" with field=form.users %}
+ </div>
+ </div>
+ {% include "form_buttons.html" %}
+</form>
+{% endblock third_column %}
+
+{% block media %}
+<script type="text/javascript">
+ $('#add_more').click(function() {
+ cloneMore('tr.form:last', 'queuestatus_set', true);
+ });
+</script>
+{% endblock media %}
diff --git a/servo/templates/admin/queues/index.html b/servo/templates/admin/queues/index.html
new file mode 100644
index 0000000..d161dbb
--- /dev/null
+++ b/servo/templates/admin/queues/index.html
@@ -0,0 +1,6 @@
+{% extends "generic/admin_list.html" %}
+{% load i18n %}
+
+{% block toolbar %}
+ <a href="{% url 'admin-create_queue' %}" class="btn btn-default navbar-btn"><i class="icon-plus"></i> {% trans "New Queue" %}</a>
+{% endblock toolbar %}
diff --git a/servo/templates/admin/queues/remove.html b/servo/templates/admin/queues/remove.html
new file mode 100644
index 0000000..125f89e
--- /dev/null
+++ b/servo/templates/admin/queues/remove.html
@@ -0,0 +1,17 @@
+{% extends "modal.html" %}
+{% load i18n %}
+
+{% block header %}
+ {% blocktrans with queue.title as title %}Delete queue "{{ title }}"?{% endblocktrans %}
+{% endblock header %}
+
+{% block body %}
+ <p>{% trans "Orders in this queue will not be deleted." %}</p>
+{% endblock body %}
+
+{% block footer %}
+ <form action="{% url 'admin-delete_queue' queue.pk %}" method="post">
+ {% csrf_token %}
+ <button type="submit" class="btn btn-danger">{% trans "Delete" %}</button>
+ </form>
+{% endblock footer %}