diff options
-rw-r--r-- | ishtar_common/models_common.py | 2 | ||||
-rw-r--r-- | ishtar_common/templates/ishtar/blocks/window_nav.html | 22 |
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> |