pas de gestion des page spour les membres

This commit is contained in:
Fred Tempez 2023-05-21 17:56:18 +02:00
parent 663dfd12ec
commit 81d8eb54d0
5 changed files with 69 additions and 48 deletions

View File

@ -531,7 +531,7 @@ class user extends common
$this->setData([
'profil',
$this->getInput('profilEditGroup'),
$this->getUrl(3),
$this->getInput('profilEditProfil'),
[
'name' => $this->getInput('profilEditName', helper::FILTER_STRING_SHORT, true),
'readonly' => false,

View File

@ -16,3 +16,7 @@
/** NE PAS EFFACER
* admin.css
*/
#containerPage {
display: none;
}

View File

@ -26,4 +26,15 @@ $(document).ready(function () {
$(".filemanager").prop("disabled", false);
}
});
// Désactive la gestion des pages pour les membres
$('#profilAddGroup').change(function() {
console.log($(this).val());
if ($(this).val() === '1') {
$('#containerPage').slideUp();
} else {
$('#containerPage').slideDown();
}
});
});

View File

@ -44,7 +44,7 @@
</div>
</div>
</div>
<div class="row">
<div class="row" id="containerPage">
<div class="col12">
<div class="block">
<h4>

View File

@ -27,11 +27,17 @@
]); ?>
</div>
<div class="col12">
<?php echo template::text('profilEditGroup', [
<?php echo template::text('profilEditDisplayGroup', [
'label' => 'Groupe',
'value' => self::$groups[$this->getUrl(2)],
'disabled' => true
]); ?>
<?php echo template::hidden('profilEditGroup', [
'value' => $this->getUrl(2),
]); ?>
<?php echo template::hidden('profilEditProfil', [
'value' => $this->getUrl(3),
]); ?>
</div>
</div>
</div>
@ -45,8 +51,8 @@
</div>
</div>
</div>
<?php if($this->getUrl(2) >= 2): ?>
<div class="row">
<?php if ($this->getUrl(2) >= self::GROUP_MODERATOR): ?>
<div class="row">
<div class="col12">
<div class="block">
<h4>
@ -93,7 +99,7 @@
</div>
</div>
</div>
</div>
</div>
<?php endif; ?>
<div class="row">
<div class="col12">