summaryrefslogtreecommitdiff
path: root/ishtar_common
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2024-05-03 16:39:28 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2024-05-06 11:20:08 +0200
commitfa19e9f25404a3363169909ff02a5cac32bd8cdc (patch)
tree36683de5351fa2e759288072c2c998515810bc0f /ishtar_common
parent4dd47534de59d7c6162a92a308dfa765ede9e6ea (diff)
downloadIshtar-fa19e9f25404a3363169909ff02a5cac32bd8cdc.tar.bz2
Ishtar-fa19e9f25404a3363169909ff02a5cac32bd8cdc.zip
💄 sheet: restore button is more visible and has been detached from navigation buttons (refs #5917)
Diffstat (limited to 'ishtar_common')
-rw-r--r--ishtar_common/models_common.py2
-rw-r--r--ishtar_common/templates/ishtar/blocks/window_nav.html22
2 files changed, 14 insertions, 10 deletions
diff --git a/ishtar_common/models_common.py b/ishtar_common/models_common.py
index ddf5d46d5..b2cf02ef9 100644
--- a/ishtar_common/models_common.py
+++ b/ishtar_common/models_common.py
@@ -3340,7 +3340,7 @@ class MainItem(ShortMenuItem, SerializeItem, SheetItem):
_("Regenerate ID"),
"fa fa-key",
_("regen."),
- "btn-info",
+ "btn-warning",
True,
200,
)
diff --git a/ishtar_common/templates/ishtar/blocks/window_nav.html b/ishtar_common/templates/ishtar/blocks/window_nav.html
index 47e99f963..e3ed13f97 100644
--- a/ishtar_common/templates/ishtar/blocks/window_nav.html
+++ b/ishtar_common/templates/ishtar/blocks/window_nav.html
@@ -10,7 +10,7 @@
{% if not item.is_external %}
<div class="row toolbar">
<div class='col-md-2'>
- <div class="btn-group btn-group-sm" role="group" aria-label="{% trans 'History'%}">
+ <div class="btn-group btn-group-sm" role="group" aria-label="{% trans 'Refresh'%}">
<button type="button" class="btn btn-secondary"
data-toggle="tooltip" data-placement="bottom"
title="{% trans 'Refresh' %}"
@@ -18,26 +18,30 @@
<i class="fa fa-refresh"></i>
</button>
{% if current_user.is_superuser and previous %}
- <button type="button" class="btn btn-secondary"
+ </div>
+ <div class="btn-group btn-group-sm ml-3" role="group" aria-label="{% trans 'History'%}">
+ <button type="button" class="btn btn-secondary"
data-toggle="tooltip" data-placement="bottom"
title="{{previous|date}} {{previous|time:'H:i'}}"
onclick='load_window("{% url histo_url item.pk previous|date:"c"%}");$("#{{window_id}}").hide();return false;'>
<i class="fa fa-step-backward"></i>
- </button>
+ </button>
{% endif %}
{% if current_user.is_superuser and next %}
<button type="button" class="btn btn-secondary"
data-toggle="tooltip" data-placement="bottom"
- onclick='if(confirm("{% trans "Are you sure to restore to this version? All changes made since this version will be lost." %}")){load_url("{% url revert_url item.pk item.history_date|date:"c"%}", function(){closeAllWindows();load_window("{% url show_url item.pk None %}");});}'
- title="{% trans 'Restore this version' %}">
- <i class="fa fa-history"></i>
- </button>
- <button type="button" class="btn btn-secondary"
- data-toggle="tooltip" data-placement="bottom"
onclick='load_window("{% url histo_url item.pk next|date:"c" %}");$("#{{window_id}}").hide();return false;'
title="{{next|date}} {{next|time:'H:i'}}">
<i class="fa fa-step-forward"></i>
</button>
+ </div>
+ <div class="btn-group btn-group-sm mr-2" role="group" aria-label="{% trans 'Restore'%}">
+ <button type="button" class="btn btn-warning"
+ data-toggle="tooltip" data-placement="bottom"
+ onclick='if(confirm("{% trans "Are you sure to restore to this version? All changes made since this version will be lost." %}")){load_url("{% url revert_url item.pk item.history_date|date:"c"%}", function(){closeAllWindows();load_window("{% url show_url item.pk None %}");});}'
+ title="{% trans 'Restore this version' %}">
+ <i class="fa fa-history"></i>
+ </button>
{% endif %}
</div>
</div>