summaryrefslogtreecommitdiff
path: root/ishtar_common/templates/ishtar/blocks/shortcut_menu.html
diff options
context:
space:
mode:
Diffstat (limited to 'ishtar_common/templates/ishtar/blocks/shortcut_menu.html')
-rw-r--r--ishtar_common/templates/ishtar/blocks/shortcut_menu.html24
1 files changed, 24 insertions, 0 deletions
diff --git a/ishtar_common/templates/ishtar/blocks/shortcut_menu.html b/ishtar_common/templates/ishtar/blocks/shortcut_menu.html
new file mode 100644
index 000000000..29c975e79
--- /dev/null
+++ b/ishtar_common/templates/ishtar/blocks/shortcut_menu.html
@@ -0,0 +1,24 @@
+{% load i18n %}
+{% load url from future%}
+{% if current_menu %}
+<form method="post" action="{% url 'update-current-item' %}">
+<fieldset>
+<i class="icon fa fa-thumb-tack fa-2x" aria-hidden="true" title="{% trans 'Pin an item in order to constrain default searches with this item. By default only your items are displayed. New created and modified items are auto-pin.' %}"></i>
+<table id='current_items'>
+{% for lbl, model_name, main_cls, items in current_menu %}
+<tr>
+ <td><label for="current_{{model_name}}">{{lbl}}</label></td>
+ <td>
+ <select class='{{main_cls}} chosen-select' id='current_{{model_name}}'>
+ <option class='normal' value=''>--</option>
+ {% for val, label, selected, cls in items %}<option{% if cls %} class='{{cls}}'{% endif %} value='{{val}}'{% if selected %} selected="selected"{% endif %}>{% ifequal cls 'basket' %}&#xf291; {% endifequal %}{% ifequal cls 'green' %}&#xf058; {% endifequal %}{% ifequal cls 'orange' %}&#xf06a; {% endifequal %}{% ifequal cls 'red' %}&#xf071; {% endifequal %}{{label}}</option>
+ {% endfor %}</select>
+ </td>{% with 'show-'|add:model_name as model_url%}
+ <td><a href='#' onclick='load_current_window("{% url model_url 0 %}", "{{model_name}}");' class='display_details'><i class="fa fa-info-circle" aria-hidden="true"></i></a></td>
+ {% endwith %}
+</tr>
+{% endfor %}
+</table>
+</fieldset>
+</form>
+{% endif %}