Introduced clone, edit, and delete buttons

This commit is contained in:
Jeremy Stretch
2019-12-13 15:29:55 -05:00
parent cf47170cde
commit 3506f93cd7
24 changed files with 153 additions and 184 deletions

View File

@@ -1,8 +1,9 @@
{% extends '_base.html' %}
{% load static %}
{% load buttons %}
{% load custom_links %}
{% load helpers %}
{% load secret_helpers %}
{% load static %}
{% block header %}
<div class="row noprint">
@@ -16,16 +17,10 @@
</div>
<div class="pull-right noprint">
{% if perms.secrets.change_secret %}
<a href="{% url 'secrets:secret_edit' pk=secret.pk %}" class="btn btn-warning">
<span class="fa fa-pencil" aria-hidden="true"></span>
Edit this secret
</a>
{% edit_button secret %}
{% endif %}
{% if perms.secrets.delete_secret %}
<a href="{% url 'secrets:secret_delete' pk=secret.pk %}" class="btn btn-danger">
<span class="fa fa-trash" aria-hidden="true"></span>
Delete this secret
</a>
{% delete_button secret %}
{% endif %}
</div>
<h1>{% block title %}{{ secret }}{% endblock %}</h1>