Added an simple admin page for users.

This commit is contained in:
Jan Böhmer 2019-04-28 14:18:11 +02:00
parent 0826f5e6aa
commit 8a4d665d2a
12 changed files with 276 additions and 30 deletions

View file

@ -65,7 +65,9 @@
<div class="tab-content">
<div class="tab-pane active" id="home_common">
{{ form_row(form.name) }}
{{ form_row(form.parent) }}
{% if form.parent%}
{{ form_row(form.parent) }}
{% endif %}
{% block additional_controls %}{% endblock %}
@ -101,6 +103,7 @@
<label class="col-form-label col-md-3">{% trans %}createdAt{% endtrans %}</label>
<div class="col-md-9">
<p class="form-control-plaintext">
{% if date(entity.addedDate) > date('1900/01/01') %}
{{ entity.addedDate | localizeddate("long") }}
{% else %}

View file

@ -0,0 +1,15 @@
{% extends "AdminPages/EntityAdminBase.html.twig" %}
{% block card_title %}
<i class="fas fa-file-alt fa-fw"></i> {% trans %}attachment_type.caption{% endtrans %}
{% endblock %}
{% block comment %}{% endblock %}
{% block additional_controls %}
{{ form_row(form.group) }}
{{ form_row(form.first_name) }}
{{ form_row(form.last_name) }}
{{ form_row(form.email) }}
{{ form_row(form.department) }}
{% endblock %}

View file

@ -7,10 +7,12 @@
<div class=""></div>
<div class="col offset-3 pl-2">
<button class="btn btn-danger" {% if not is_granted("delete", entity) %}disabled{% endif %}">{% trans %}entity.delete{% endtrans %}</button>
{% if entity is instanceof('\App\Entity\StructuralDBElement') %}
<div class="ml-2 custom-control custom-checkbox custom-control-inline">
<input type="checkbox" class="custom-control-input" id="recursive" name="delete_recursive">
<label class="custom-control-label" for="recursive">{% trans %}entity.delete.recursive{% endtrans %}</label>
</div>
{% endif %}
</div>
</div>
</form>