2016-07-06 17:22:10 -04:00
|
|
|
{% load secret_helpers %}
|
2016-03-01 11:23:03 -05:00
|
|
|
<tr>
|
|
|
|
<td><a href="{% url 'secrets:secret' pk=secret.pk %}">{{ secret.role }}</a></td>
|
|
|
|
<td>{{ secret.name }}</td>
|
|
|
|
<td id="secret_{{ secret.pk }}">********</td>
|
2019-03-05 15:42:47 -06:00
|
|
|
<td class="text-right noprint">
|
2016-07-06 17:22:10 -04:00
|
|
|
{% if secret|decryptable_by:request.user %}
|
|
|
|
<button class="btn btn-xs btn-success unlock-secret" secret-id="{{ secret.pk }}">
|
|
|
|
<i class="fa fa-lock"></i> Unlock
|
|
|
|
</button>
|
2019-02-21 18:26:19 +00:00
|
|
|
<button class="btn btn-xs btn-default copy-secret collapse" secret-id="{{ secret.pk }}" data-clipboard-target="#secret_{{ secret.pk }}">
|
|
|
|
<i class="fa fa-copy"></i> Copy
|
|
|
|
</button>
|
2016-07-06 17:22:10 -04:00
|
|
|
<button class="btn btn-xs btn-danger lock-secret collapse" secret-id="{{ secret.pk }}">
|
|
|
|
<i class="fa fa-unlock-alt"></i> Lock
|
|
|
|
</button>
|
|
|
|
{% else %}
|
|
|
|
<button class="btn btn-xs btn-default" disabled="disabled" title="Permission denied">
|
|
|
|
<i class="fa fa-lock"></i> Unlock
|
|
|
|
</button>
|
|
|
|
{% endif %}
|
2016-03-01 11:23:03 -05:00
|
|
|
</td>
|
|
|
|
</tr>
|