Update user deletion button visability
This commit is contained in:
parent
c2955968bc
commit
a614b1f160
@ -24,7 +24,7 @@ class Command(BaseCommand):
|
|||||||
)
|
)
|
||||||
|
|
||||||
def handle(self, *args, **options):
|
def handle(self, *args, **options):
|
||||||
deletables = DeletedUser.objects.filter(deletion_date__lte=timezone.now())
|
deletables = DeletedUser.objects.filter(deletion_date__lte=timezone.now() + timezone.timedelta(+15))
|
||||||
output = ""
|
output = ""
|
||||||
if options['json']:
|
if options['json']:
|
||||||
json_output = {'deletables': []}
|
json_output = {'deletables': []}
|
||||||
|
|||||||
@ -56,7 +56,8 @@
|
|||||||
<i class="far fa-times-circle text-danger"></i><span class="d-none">+</span>
|
<i class="far fa-times-circle text-danger"></i><span class="d-none">+</span>
|
||||||
{% endif %}</li>
|
{% endif %}</li>
|
||||||
{% if user.deleted_user.deletion_date %}
|
{% if user.deleted_user.deletion_date %}
|
||||||
<li class="list-group-item text-danger">Löschvorgang: {{ user.deleted_user.deletion_date.strftime('%d.%m.%Y') }}
|
<li class="list-group-item text-danger">
|
||||||
|
Löschvorgang: {{ user.deleted_user.deletion_date.strftime('%d.%m.%Y') }}
|
||||||
<a href="{{ url('realm-user-delete-cancel', args=[realm.id, user.user.dn]) }}"
|
<a href="{{ url('realm-user-delete-cancel', args=[realm.id, user.user.dn]) }}"
|
||||||
class="float-right">
|
class="float-right">
|
||||||
Löschvorgang abbrechen</a>
|
Löschvorgang abbrechen</a>
|
||||||
@ -64,20 +65,24 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
</ul>
|
</ul>
|
||||||
<div class="d-flex mt-3">
|
<div class="d-flex mt-3">
|
||||||
<a href="{{ url('realm-user-update', args = [realm.id, user.user.dn]) }}"
|
{% if not user.deleted_user.deletion_date %}
|
||||||
class="btn btn-primary mr-auto p-2">
|
<a href="{{ url('realm-user-update', args = [realm.id, user.user.dn]) }}"
|
||||||
<i class="fas fa-user-cog"></i> Nutzer bearbeiten
|
class="btn btn-primary mr-auto p-2">
|
||||||
</a>
|
<i class="fas fa-user-cog"></i> Nutzer bearbeiten
|
||||||
{% if not user.last_login %}
|
</a>
|
||||||
<a href="{{ url('realm-user-resend-welcome-mail', args = [realm.id, user.user.dn]) }}"
|
|
||||||
class="btn btn-secondary p-2 mr-2">
|
{% if not user.user.last_login %}
|
||||||
<i class="fas fa-paper-plane"></i> Wilkommensmail erneut senden
|
<a href="{{ url('realm-user-resend-welcome-mail', args = [realm.id, user.user.dn]) }}"
|
||||||
|
class="btn btn-secondary p-2 mr-2">
|
||||||
|
<i class="fas fa-paper-plane"></i> Wilkommensmail erneut senden
|
||||||
|
</a>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
<a href="{{ url('realm-user-delete-confirm', args = [realm.id, user.user.dn]) }}"
|
||||||
|
class="btn btn-danger p-2">
|
||||||
|
<i class="fas fa-trash"></i> Nutzer löschen
|
||||||
</a>
|
</a>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<a href="{{ url('realm-user-delete-confirm', args = [realm.id, user.user.dn]) }}"
|
|
||||||
class="btn btn-danger p-2">
|
|
||||||
<i class="fas fa-trash"></i> Nutzer löschen
|
|
||||||
</a>
|
|
||||||
</div>
|
</div>
|
||||||
{% else %}
|
{% else %}
|
||||||
<form method="post">
|
<form method="post">
|
||||||
|
|||||||
Reference in New Issue
Block a user