diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2019-09-24 10:33:07 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2019-09-24 10:33:07 +0200 |
commit | ff8681360e589ff3c8e63dcef6ad0d31ac8ecab8 (patch) | |
tree | aff85c928066d444a8639daf6dd1c52d38e6c7dc /ishtar_common/templates/ishtar/sheet.html | |
parent | fee9b4904fee90077cdb73ecddc130288ba0ab21 (diff) | |
download | Ishtar-ff8681360e589ff3c8e63dcef6ad0d31ac8ecab8.tar.bz2 Ishtar-ff8681360e589ff3c8e63dcef6ad0d31ac8ecab8.zip |
Allow own locker to edit their locks
Diffstat (limited to 'ishtar_common/templates/ishtar/sheet.html')
-rw-r--r-- | ishtar_common/templates/ishtar/sheet.html | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/ishtar_common/templates/ishtar/sheet.html b/ishtar_common/templates/ishtar/sheet.html index 5676a4419..1c3ae37a0 100644 --- a/ishtar_common/templates/ishtar/sheet.html +++ b/ishtar_common/templates/ishtar/sheet.html @@ -1,4 +1,4 @@ -{% load i18n %}{% block main_head %}<html lang="en"> +{% load i18n ishtar_helpers %}{% block main_head %}<html lang="en"> <head> <title>{% block title %}Ishtar{% if APP_NAME %} - {{APP_NAME}}{%endif%}{% endblock %} </title> @@ -121,12 +121,17 @@ <div class="body"> {% if item.locked %} <div class="alert alert-warning" role="alert"> + {% if item|is_locked:request.user %} <i class="fa fa-lock text-danger" aria-hidden="true"></i> {% if item.lock_user %}{% blocktrans with locker=item.lock_user.ishtaruser %} This item has been locked by {{locker}}. Edition is disabled. {% endblocktrans %}{% else %} {% trans "This item has been locked. Edition is disabled." %} {% endif %} + {% else %} + <i class="fa fa-lock text-success" aria-hidden="true"></i> + {% trans "You have locked this item." %} + {% endif %} </div> {% endif %} {% block content %} |