diff --git a/action/views.py b/action/views.py index 125b656..0bdac32 100644 --- a/action/views.py +++ b/action/views.py @@ -73,7 +73,6 @@ class AddNoteView(View): class UpdateNoteView(UpdateView): model = Note fields = ['description'] - template_name = "blank.html" pk_url_kwarg = 'pk' def form_valid(self, form): diff --git a/device/templates/details.html b/device/templates/details.html index f420f74..16b4046 100644 --- a/device/templates/details.html +++ b/device/templates/details.html @@ -27,15 +27,19 @@ {{ note.date|timesince }} {% trans "ago" %} - + {% if user == note.user or user.is_admin %} + {% trans "Editable" %} +
{% else %} +{% endif %}@@ -69,18 +73,25 @@ - +