Edit group Profil TEST

This commit is contained in:
Fred Tempez 2023-03-31 17:02:56 +02:00
parent a5743ca323
commit d364b11012
10 changed files with 308 additions and 103 deletions

View File

@ -234,7 +234,7 @@ class common
'theme' => '', 'theme' => '',
'user' => '', 'user' => '',
'language' => '', 'language' => '',
'permission'=> '', 'profil'=> '',
]; ];
public static $fontsWebSafe = [ public static $fontsWebSafe = [
@ -918,10 +918,10 @@ class common
public function getPermission($key1, $key2 = null) { public function getPermission($key1, $key2 = null) {
if (is_array($this->user) === false) { if (is_array($this->user) === false) {
return false; return false;
} elseif ($key2 === null && array_key_exists($key1, $this->getData(['permission', $this->user['group']]))) { } elseif ($key2 === null && array_key_exists($key1, $this->getData(['profil', $this->user['group']]))) {
return $this->getData(['permission', $this->user['group'], $key1]); return $this->getData(['profil', $this->user['group'], $key1]);
} elseif ($key2 && array_key_exists($key2, $this->getData(['permission', $this->user['group'], $key1]))) { } elseif ($key2 && array_key_exists($key2, $this->getData(['profil', $this->user['group'], $key1]))) {
return $this->getData(['permission', $this->user['group'], $key1, $key2]); return $this->getData(['profil', $this->user['group'], $key1, $key2]);
} else { } else {
return false; return false;
} }

View File

@ -334,7 +334,7 @@ class init extends common
], ],
'blacklist' => [], 'blacklist' => [],
'language'=> [], 'language'=> [],
'permission' => [ 'profil' => [
'-1' => [ '-1' => [
'name' => 'Banni', 'name' => 'Banni',
'readonly' => true, 'readonly' => true,
@ -361,14 +361,14 @@ class init extends common
'duplicate' => false, 'duplicate' => false,
'extract' => false, 'extract' => false,
'copycut' => false, 'copycut' => false,
'permission' => false 'chmod' => false
], ],
'folder' => [ 'folder' => [
'create' => false, 'create' => false,
'delete' => false, 'delete' => false,
'rename' => false, 'rename' => false,
'copycut' => false, 'copycut' => false,
'permission' => false, 'chmod' => false,
'share' => false, 'share' => false,
'path' => './site/file/source/partage/', 'path' => './site/file/source/partage/',
] ]
@ -388,14 +388,14 @@ class init extends common
'duplicate' => false, 'duplicate' => false,
'extract' => false, 'extract' => false,
'copycut' => false, 'copycut' => false,
'permission' => false 'chmod' => false
], ],
'folder' => [ 'folder' => [
'create' => false, 'create' => false,
'delete' => false, 'delete' => false,
'rename' => false, 'rename' => false,
'copycut' => false, 'copycut' => false,
'permission' => false, 'chmod' => false,
'share' => true, 'share' => true,
'path' => './site/file/source/partage/', 'path' => './site/file/source/partage/',
] ]
@ -417,14 +417,14 @@ class init extends common
'duplicate' => false, 'duplicate' => false,
'extract' => false, 'extract' => false,
'copycut' => false, 'copycut' => false,
'permission' => false 'chmod' => false
], ],
'folder' => [ 'folder' => [
'create' => true, 'create' => true,
'delete' => true, 'delete' => true,
'rename' => true, 'rename' => true,
'copycut' => false, 'copycut' => false,
'permission' => false, 'chmod' => false,
'share' => true, 'share' => true,
'path' => './site/file/source/partage/', 'path' => './site/file/source/partage/',
] ]
@ -444,14 +444,14 @@ class init extends common
'duplicate' => false, 'duplicate' => false,
'extract' => false, 'extract' => false,
'copycut' => false, 'copycut' => false,
'permission' => false 'chmod' => false
], ],
'folder' => [ 'folder' => [
'create' => true, 'create' => true,
'delete' => true, 'delete' => true,
'rename' => true, 'rename' => true,
'copycut' => false, 'copycut' => false,
'permission' => false, 'chmod' => false,
'share' => true, 'share' => true,
'path' => './site/file/source/', 'path' => './site/file/source/',
] ]

View File

@ -27,9 +27,9 @@ class user extends common
'forgot' => self::GROUP_VISITOR, 'forgot' => self::GROUP_VISITOR,
'login' => self::GROUP_VISITOR, 'login' => self::GROUP_VISITOR,
'reset' => self::GROUP_VISITOR, 'reset' => self::GROUP_VISITOR,
'permission' => self::GROUP_ADMIN, 'profil' => self::GROUP_ADMIN,
'permissionEdit' => self::GROUP_ADMIN, 'profilEdit' => self::GROUP_ADMIN,
'permissionAdd' => self::GROUP_ADMIN, 'profilAdd' => self::GROUP_ADMIN,
]; ];
public static $users = []; public static $users = [];
@ -60,6 +60,11 @@ class user extends common
'/site/file/source/' '/site/file/source/'
]; ];
public static $groupProfils = [
self::GROUP_MEMBER => 'Membre',
self::GROUP_MODERATOR => 'Editeur'
];
/** /**
* Ajout * Ajout
*/ */
@ -411,9 +416,9 @@ class user extends common
/** /**
* Table des groupes * Table des groupes
*/ */
public function permission() public function profil()
{ {
foreach ($this->getData(['permission']) as $groupId => $groupData) { foreach ($this->getData(['profil']) as $groupId => $groupData) {
// Membres sans permissions spécifiques // Membres sans permissions spécifiques
if ( if (
@ -425,8 +430,8 @@ class user extends common
$groupId, $groupId,
$groupData['name'], $groupData['name'],
nl2br($groupData['comment']), nl2br($groupData['comment']),
template::button('permissionEdit' . $groupId, [ template::button('profilEdit' . $groupId, [
'href' => helper::baseUrl() . 'user/permissionEdit/' . $groupId . '/' . $_SESSION['csrf'], 'href' => helper::baseUrl() . 'user/profilEdit/' . $groupId . '/' . $_SESSION['csrf'],
'value' => template::ico('pencil'), 'value' => template::ico('pencil'),
'help' => 'Éditer', 'help' => 'Éditer',
'disabled' => $groupData['readonly'], 'disabled' => $groupData['readonly'],
@ -449,15 +454,15 @@ class user extends common
$groupId . '-' . $subGroupId, $groupId . '-' . $subGroupId,
self::$groups[$groupId] .'<br />Profil : '. $subGroupData['name'], self::$groups[$groupId] .'<br />Profil : '. $subGroupData['name'],
nl2br($subGroupData['comment']), nl2br($subGroupData['comment']),
template::button('permissionEdit' . $groupId.$subGroupId, [ template::button('profilEdit' . $groupId.$subGroupId, [
'href' => helper::baseUrl() . 'user/permissionEdit/' . $groupId . '/' . $subGroupId . '/' . $_SESSION['csrf'], 'href' => helper::baseUrl() . 'user/profilEdit/' . $groupId . '/' . $subGroupId . '/' . $_SESSION['csrf'],
'value' => template::ico('pencil'), 'value' => template::ico('pencil'),
'help' => 'Éditer', 'help' => 'Éditer',
'disabled' => $subGroupData['readonly'], 'disabled' => $subGroupData['readonly'],
]), ]),
template::button('permissionDelete' . $groupId.$subGroupId, [ template::button('profilDelete' . $groupId.$subGroupId, [
'class' => 'userDelete buttonRed', 'class' => 'userDelete buttonRed',
'href' => helper::baseUrl() . 'user/permissionDelete/' . $groupId . '/' . $subGroupId . '/' . $_SESSION['csrf'], 'href' => helper::baseUrl() . 'user/profilDelete/' . $groupId . '/' . $subGroupId . '/' . $_SESSION['csrf'],
'value' => template::ico('trash'), 'value' => template::ico('trash'),
'help' => 'Supprimer', 'help' => 'Supprimer',
'disabled' => $subGroupData['readonly'], 'disabled' => $subGroupData['readonly'],
@ -468,15 +473,15 @@ class user extends common
} }
// Valeurs en sortie // Valeurs en sortie
$this->addOutput([ $this->addOutput([
'title' => helper::translate('Permissions'), 'title' => helper::translate('Profils des groupes'),
'view' => 'permission' 'view' => 'profil'
]); ]);
} }
/** /**
* Edition d'un groupe * Edition d'un groupe
*/ */
public function permissionEdit() public function profilEdit()
{ {
if ( if (
$this->getUrl(4) !== $_SESSION['csrf'] $this->getUrl(4) !== $_SESSION['csrf']
@ -491,43 +496,56 @@ class user extends common
// Soumission du formulaire // Soumission du formulaire
if ($this->isPost()) { if ($this->isPost()) {
$group = $this->getUrl(2); $oldGroup = $this->getUrl(2);
$group = $this->getInput('profilEditGroup');
$profil = $this->getUrl(3); $profil = $this->getUrl(3);
// Changement de groupe, effacer le profil de l'ancien groupe et incrément le profil
if ($oldGroup !== $group) {
$this->deleteData(['profil', $oldGroup, $profil]);
$profil = helper::increment($profil, $this->getData(['profil', $group]));
}
echo "groupe " . $group;
echo "profil " . $profil;
exit();
$this->setData([ $this->setData([
'permission', 'profil',
$group, $group,
$profil, $profil,
[ [
'name' => $this->getInput('permissionEditName', null, true), 'name' => $this->getInput('profilEditName', helper::FILTER_STRING_SHORT, true),
'readonly' => false, 'readonly' => false,
'comment' => $this->getInput('permissionEditComment', helper::FILTER_STRING_SHORT, true), 'comment' => $this->getInput('profilEditComment', helper::FILTER_STRING_SHORT, true),
'file' => [ 'file' => [
'download' => $this->getInput('permissionEditDownload', helper::FILTER_BOOLEAN), 'download' => $this->getInput('profilEditDownload', helper::FILTER_BOOLEAN),
'edit' => $this->getInput('permissionEditEdit', helper::FILTER_BOOLEAN), 'edit' => $this->getInput('profilEditEdit', helper::FILTER_BOOLEAN),
'create' => $this->getInput('permissionEditCreate', helper::FILTER_BOOLEAN), 'create' => $this->getInput('profilEditCreate', helper::FILTER_BOOLEAN),
'rename' => $this->getInput('permissionEditRename', helper::FILTER_BOOLEAN), 'rename' => $this->getInput('profilEditRename', helper::FILTER_BOOLEAN),
'upload' => $this->getInput('permissionEditUpload', helper::FILTER_BOOLEAN), 'upload' => $this->getInput('profilEditUpload', helper::FILTER_BOOLEAN),
'delete' => $this->getInput('permissionEditDelete', helper::FILTER_BOOLEAN), 'delete' => $this->getInput('profilEditDelete', helper::FILTER_BOOLEAN),
'preview' => $this->getInput('permissionEditPreview', helper::FILTER_BOOLEAN), 'preview' => $this->getInput('profilEditPreview', helper::FILTER_BOOLEAN),
'duplicate' => $this->getInput('permissionEditDuplicate', helper::FILTER_BOOLEAN), 'duplicate' => $this->getInput('profilEditDuplicate', helper::FILTER_BOOLEAN),
'extract' => $this->getInput('permissionEditExtract', helper::FILTER_BOOLEAN), 'extract' => $this->getInput('profilEditExtract', helper::FILTER_BOOLEAN),
'copycut' => $this->getInput('permissionEditCopycut', helper::FILTER_BOOLEAN), 'copycut' => $this->getInput('profilEditCopycut', helper::FILTER_BOOLEAN),
'permission' => $this->getInput('permissionEditPermission', helper::FILTER_BOOLEAN), 'chmod' => $this->getInput('profilEditChmod', helper::FILTER_BOOLEAN),
], ],
'folder' => [ 'folder' => [
'create' => $this->getInput('permissionEditFolderCreate', helper::FILTER_BOOLEAN), 'create' => $this->getInput('profilEditFolderCreate', helper::FILTER_BOOLEAN),
'delete' => $this->getInput('permissionEditFolderDelete', helper::FILTER_BOOLEAN), 'delete' => $this->getInput('profilEditFolderDelete', helper::FILTER_BOOLEAN),
'rename' => $this->getInput('permissionEditFolderRename', helper::FILTER_BOOLEAN), 'rename' => $this->getInput('profilEditFolderRename', helper::FILTER_BOOLEAN),
'copycut' => $this->getInput('permissionEditFolderCopycut', helper::FILTER_BOOLEAN), 'copycut' => $this->getInput('profilEditFolderCopycut', helper::FILTER_BOOLEAN),
'permission' => $this->getInput('permissionEditFolderPermission', helper::FILTER_BOOLEAN), 'chmod' => $this->getInput('profilEditFolderChmod', helper::FILTER_BOOLEAN),
'share' => $this->getInput('permissionEditShare', helper::FILTER_BOOLEAN), 'share' => $this->getInput('profilEditShare', helper::FILTER_BOOLEAN),
'path' => $this->getInput('permissionEditPath'), 'path' => $this->getInput('profilEditPath'),
] ]
] ]
]); ]);
// Valeurs en sortie // Valeurs en sortie
$this->addOutput([ $this->addOutput([
'redirect' => helper::baseUrl() . 'user/permission', 'redirect' => helper::baseUrl() . 'user/profil',
'notification' => helper::translate('Modifications enregistrées'), 'notification' => helper::translate('Modifications enregistrées'),
'state' => true 'state' => true
]); ]);
@ -539,11 +557,23 @@ class user extends common
// Valeurs en sortie; // Valeurs en sortie;
$this->addOutput([ $this->addOutput([
'title' => sprintf(helper::translate('Groupe : %s - Profil : %s'), $this->getData(['permission', $this->getUrl(2), 'name']), $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'name'])), 'title' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'name']),
'view' => 'permissionEdit' 'view' => 'profilEdit'
]); ]);
} }
/**
* Ajouter un profil de permission
*/
public function profilAdd() {
// Valeurs en sortie;
$this->addOutput([
'title' => "Ajouter un profil",
'view' => 'profilAdd'
]);
}
/** /**
* Connexion * Connexion

View File

@ -24,9 +24,9 @@
</div> </div>
<div class="col1"> <div class="col1">
<?php echo template::button('userGroup', [ <?php echo template::button('userGroup', [
'href' => helper::baseUrl() . 'user/permission', 'href' => helper::baseUrl() . 'user/profil',
'value' => template::ico('lock'), 'value' => template::ico('lock'),
'help' => 'Gestion des permissions' 'help' => 'Gestion des profils'
]); ?> ]); ?>
</div> </div>
<div class="col1"> <div class="col1">

View File

@ -6,5 +6,13 @@
'value' => template::ico('left') 'value' => template::ico('left')
]); ?> ]); ?>
</div> </div>
<div class="col1 offset10">
<?php echo template::button('userAdd', [
'href' => helper::baseUrl() . 'user/profilAdd',
'value' => template::ico('plus'),
'class' => 'buttonGreen',
'help' => 'Ajouter un profil'
]); ?>
</div> </div>
<?php echo template::table([1, 4, 5, 1, 1], $module::$userGroups, ['#', 'Groupe et profil', 'Commentaire', '', '']); ?> </div>
<?php echo template::table([1, 4, 5, 1, 1], $module::$userGroups, ['#', 'Nom', 'Commentaire', '', '']); ?>

View File

@ -0,0 +1,139 @@
<?php echo template::formOpen('profilAddForm'); ?>
<div class="row">
<div class="col1">
<?php echo template::button('profilAddBack', [
'class' => 'buttonGrey',
'href' => helper::baseUrl() . 'user/profil',
'value' => template::ico('left')
]); ?>
</div>
<div class="col2 offset9">
<?php echo template::submit('profilAddSubmit'); ?>
</div>
</div>
<div class="row">
<div class="col12">
<div class="block">
<h4>
<?php echo helper::translate('Paramètres'); ?>
</h4>
<div class="row">
<div class="col6">
<div class="row">
<div class="col12">
<?php echo template::text('profilEditName', [
'label' => 'Nom du profil',
'value' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'name'])
]); ?>
</div>
<div class="col12">
<?php echo template::select('profilEditGroup', $module::$groupProfils, [
'label' => 'Groupe',
'selected' => $this->getUrl(2)
]); ?>
</div>
</div>
</div>
<div class="col6">
<?php echo template::textarea('profilEditComment', [
'label' => 'Commentaire',
'value' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'comment'])
]); ?>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col12">
<div class="block">
<h4>
<?php echo helper::translate('Gestionnaire de fichiers'); ?>
</h4>
<div class="row">
<div class="col3">
<?php echo template::checkbox('profilAddShare', true, 'Activé'); ?>
</div>
<div class="col6">
<?php echo template::select('profilAddPath', $module::$sharePath, [
'label' => 'Racine du dossier'
]); ?>
</div>
</div>
<div class="row">
<div class="col12">
<div class="block">
<h4>
<?php echo helper::translate('Permissions sur les dossiers'); ?>
</h4>
<div class="row">
<div class="col2">
<?php echo template::checkbox('profilAddFolderCreate', true, 'Création'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddFolderDelete', true, 'Effacement', ); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddFolderRename', true, 'Nommage'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddFolderCopycut', true, 'Coupé collé'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddFolderChmod', true, 'Droits sur les dossiers'); ?>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col12">
<div class="block">
<h4>
<?php echo helper::translate('Permissions sur les fichiers'); ?>
</h4>
<div class="row">
<div class="col2">
<?php echo template::checkbox('profilAddDownload', true, 'Téléchargement'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddEdit', true, 'Edition'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddCreate', true, 'Création'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddRename', true, 'Nommage'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddUpload', true, 'Téléversement'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddDelete', true, 'Effacement'); ?>
</div>
</div>
<div class="row">
<div class="col2">
<?php echo template::checkbox('profilAddPreview', true, 'Prévisualisation'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddDuplicate', true, 'Duplication'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddExtract', true, 'Extraction'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddCopycut', true, 'Coupé collé'); ?>
</div>
<div class="col2">
<?php echo template::checkbox('profilAddChmod', true, 'Droits sur les fichiers'); ?>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<?php echo template::formClose(); ?>

View File

@ -0,0 +1,18 @@
/**
* This file is part of Zwii.
*
* For full copyright and license information, please see the LICENSE
* file that was distributed with this source code.
*
* @author Rémi Jean <remi.jean@outlook.com>
* @copyright Copyright (C) 2008-2018, Rémi Jean
* @author Frédéric Tempez <frederic.tempez@outlook.com>
* @copyright Copyright (C) 2018-2023, Frédéric Tempez
* @license CC Attribution-NonCommercial-NoDerivatives 4.0 International
* @link http://zwiicms.fr/
*/
/** NE PAS EFFACER
* admin.css
*/

View File

@ -1,33 +1,43 @@
<?php echo template::formOpen('permissionEditForm'); ?> <?php echo template::formOpen('profilEditForm'); ?>
<div class="row"> <div class="row">
<div class="col1"> <div class="col1">
<?php echo template::button('permissionEditBack', [ <?php echo template::button('profilEditBack', [
'class' => 'buttonGrey', 'class' => 'buttonGrey',
'href' => helper::baseUrl() . 'user/permission', 'href' => helper::baseUrl() . 'user/profil',
'value' => template::ico('left') 'value' => template::ico('left')
]); ?> ]); ?>
</div> </div>
<div class="col2 offset9"> <div class="col2 offset9">
<?php echo template::submit('permissionEditSubmit'); ?> <?php echo template::submit('profilEditSubmit'); ?>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col12"> <div class="col12">
<div class="block"> <div class="block">
<h4> <h4>
<?php echo helper::translate('Identité'); ?> <?php echo helper::translate('Paramètres'); ?>
</h4> </h4>
<div class="row"> <div class="row">
<div class="col6"> <div class="col6">
<?php echo template::text('permissionEditName', [ <div class="row">
'label' => 'Profil', <div class="col12">
'value' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'name']) <?php echo template::text('profilEditName', [
'label' => 'Nom du profil',
'value' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'name'])
]); ?> ]); ?>
</div> </div>
<div class="col12">
<?php echo template::select('profilEditGroup', $module::$groupProfils, [
'label' => 'Groupe',
'selected' => $this->getUrl(2)
]); ?>
</div>
</div>
</div>
<div class="col6"> <div class="col6">
<?php echo template::textarea('permissionEditComment', [ <?php echo template::textarea('profilEditComment', [
'label' => 'Commentaire', 'label' => 'Commentaire',
'value' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'comment']) 'value' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'comment'])
]); ?> ]); ?>
</div> </div>
</div> </div>
@ -42,14 +52,14 @@
</h4> </h4>
<div class="row"> <div class="row">
<div class="col3"> <div class="col3">
<?php echo template::checkbox('permissionEditShare', true, 'Activé', [ <?php echo template::checkbox('profilEditShare', true, 'Activé', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'folder', 'share']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'folder', 'share'])
]); ?> ]); ?>
</div> </div>
<div class="col6"> <div class="col6">
<?php echo template::select('permissionEditPath', $module::$sharePath, [ <?php echo template::select('profilEditPath', $module::$sharePath, [
'label' => 'Racine du dossier', 'label' => 'Racine du dossier',
'selected' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'folder', 'path']) 'selected' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'folder', 'path'])
]); ?> ]); ?>
</div> </div>
</div> </div>
@ -61,28 +71,28 @@
</h4> </h4>
<div class="row"> <div class="row">
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditFolderCreate', true, 'Création', [ <?php echo template::checkbox('profilEditFolderCreate', true, 'Création', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'folder', 'create']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'folder', 'create'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditFolderDelete', true, 'Effacement', [ <?php echo template::checkbox('profilEditFolderDelete', true, 'Effacement', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'folder', 'delete']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'folder', 'delete'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditFolderRename', true, 'Nommage', [ <?php echo template::checkbox('profilEditFolderRename', true, 'Nommage', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'folder', 'rename']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'folder', 'rename'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditFolderCopycut', true, 'Coupé collé', [ <?php echo template::checkbox('profilEditFolderCopycut', true, 'Coupé collé', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'folder', 'copycut']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'folder', 'copycut'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditFolderPermission', true, 'Permissions', [ <?php echo template::checkbox('profilEditFolderChmod', true, 'Droits sur les dossiers', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'folder', 'permission']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'folder', 'chmod'])
]); ?> ]); ?>
</div> </div>
</div> </div>
@ -97,60 +107,60 @@
</h4> </h4>
<div class="row"> <div class="row">
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditDownload', true, 'Téléchargement', [ <?php echo template::checkbox('profilEditDownload', true, 'Téléchargement', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'download']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'download'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditEdit', true, 'Edition', [ <?php echo template::checkbox('profilEditEdit', true, 'Edition', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'edit']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'edit'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditCreate', true, 'Création', [ <?php echo template::checkbox('profilEditCreate', true, 'Création', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'create']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'create'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditRename', true, 'Nommage', [ <?php echo template::checkbox('profilEditRename', true, 'Nommage', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'rename']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'rename'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditUpload', true, 'Téléversement', [ <?php echo template::checkbox('profilEditUpload', true, 'Téléversement', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'upload']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'upload'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditDelete', true, 'Effacement', [ <?php echo template::checkbox('profilEditDelete', true, 'Effacement', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'delete']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'delete'])
]); ?> ]); ?>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditPreview', true, 'Prévisualisation', [ <?php echo template::checkbox('profilEditPreview', true, 'Prévisualisation', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'preview']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'preview'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditDuplicate', true, 'Duplication', [ <?php echo template::checkbox('profilEditDuplicate', true, 'Duplication', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'duplicate']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'duplicate'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditExtract', true, 'Extraction', [ <?php echo template::checkbox('profilEditExtract', true, 'Extraction', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'extract']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'extract'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditCopycut', true, 'Coupé collé', [ <?php echo template::checkbox('profilEditCopycut', true, 'Coupé collé', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'copycut']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'copycut'])
]); ?> ]); ?>
</div> </div>
<div class="col2"> <div class="col2">
<?php echo template::checkbox('permissionEditPermission', true, 'Permissions', [ <?php echo template::checkbox('profilEditChmod', true, 'Droits sur les fichiers', [
'checked' => $this->getData(['permission', $this->getUrl(2), $this->getUrl(3), 'file', 'permission']) 'checked' => $this->getData(['profil', $this->getUrl(2), $this->getUrl(3), 'file', 'chmod'])
]); ?> ]); ?>
</div> </div>
</div> </div>