fix(activeuser): user isactive & adress niveau & route all
This commit is contained in:
@ -67,7 +67,12 @@
|
||||
{% endif %}
|
||||
<img id="user_avatar_img" src="{{ path('app_minio_image',{file:"avatar/"~avatar}) }}" style="max-width:90px;background-color:var(--colorbgbodydark);">
|
||||
{{ form_widget(form.avatar) }}
|
||||
<a class="btn btn-info btn-modal" style="width:100%" data-modalid="mymodallarge" data-modaltitle="Avatar" data-modalurl="{{ path('app_user_crop01', {"type": "avatar", "reportinput": "#user_avatar" }) }}" title='Ajouter un Avatar'>Modifier</a>
|
||||
<a class="btn btn-info btn-modal" style="width:100%" data-modalid="mymodallarge" data-modaltitle="Avatar" data-modalurl="{{ path('app_all_crop01', {"type": "avatar", "reportinput": "#user_avatar" }) }}" title='Ajouter un Avatar'>Modifier</a>
|
||||
|
||||
{% if form.isactive is defined %}
|
||||
<center>{{ form_row(form.isactive) }}</center>
|
||||
{% endif %}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
{% extends 'base.html.twig' %}
|
||||
|
||||
{% block body %}
|
||||
{% if access=="admin" or access=="modo" %}
|
||||
{% if access!="all" %}
|
||||
<h1 class="page-header">Gestion des Utilisateurs</h1>
|
||||
{% if appMasteridentity=="SQL" or not appSynchroPurgeUser %}
|
||||
<a class="btn btn-success" href={{ path('app_'~access~'_user_submit') }}>Ajouter</a>
|
||||
@ -9,9 +9,17 @@
|
||||
{% endif %}
|
||||
|
||||
{% if auditUse and (access=="admin" or access=="audit") %}
|
||||
<a class="btn btn-secondary float-end" href="{{ path("app_"~access~"_audit_render",{entityname:"User"}) }}"><i class="fas fa-eye fa-fw"></i> Audit</a>
|
||||
<a class="btn btn-secondary float-end ms-3" href="{{ path("app_"~access~"_audit_render",{entityname:"User"}) }}"><i class="fas fa-eye fa-fw"></i> Audit</a>
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% if access!="all" %}
|
||||
<div class="form-check form-switch float-end mt-2">
|
||||
<input class="form-check-input" type="checkbox" role="switch" id="checkisactivate" {% if isactive %}checked{%endif%}>
|
||||
<label class="form-check-label" for="checkisactivate">{% if isactive %}Utilisateurs Actif{%else%}Utilisateurs Inactif{%endif%}</label>
|
||||
</div>
|
||||
{%endif%}
|
||||
|
||||
<div class="card mt-4">
|
||||
<div class="card-header">
|
||||
<i class="fa fa-table fa-fw"></i> Liste des Utilisateurs
|
||||
@ -61,9 +69,26 @@
|
||||
ajax: "{{ path('app_modo_user_tablelist') }}",
|
||||
{% else %}
|
||||
order: [[ 1, "asc" ]],
|
||||
ajax: "{{ path('app_user_user_tablelist') }}",
|
||||
ajax: "{{ path('app_all_user_tablelist') }}",
|
||||
{% endif %}
|
||||
});
|
||||
|
||||
{% if access!="all" %}
|
||||
$('#checkisactivate').change(function() {
|
||||
$.ajax({
|
||||
method: "POST",
|
||||
url: "{{ path('app_all_preference') }}",
|
||||
data: {
|
||||
id:0,
|
||||
key:'userisactive',
|
||||
value: ($("#checkisactivate").is(":checked"))
|
||||
},
|
||||
success: function() {
|
||||
location.reload();
|
||||
}
|
||||
});
|
||||
});
|
||||
{% endif %}
|
||||
});
|
||||
</script>
|
||||
{% endblock %}
|
||||
|
Reference in New Issue
Block a user