users : Filtre et import
This commit is contained in:
parent
2e839715b5
commit
eeb96186c1
@ -1,5 +1,5 @@
|
|||||||
id;nom;prenom;email;groupe
|
id;nom;prenom;email;groupe;profil;passe;tags
|
||||||
jm1;Membre1;Jean;jean.membre1@email.fr;1
|
jm1;Membre1;Jean;jean.membre1@email.fr;1;1;jEan05;"adhérent"
|
||||||
am2;Membre2;Albert;albert.membre2@email.fr;1
|
am2;Membre2;Albert;albert.membre2@email.fr;1;1;alBertAG;"adhérent"
|
||||||
jrediteur;Editeur;Robert;robert.editeur@email.fr;2
|
jrediteur;Editeur;Robert;robert.editeur@email.fr;2;1;roBert54;"trésorier"
|
||||||
padmin;Dupuis;Admin;paul.admin@email.fr;3
|
padmin;Dupuis;Admin;paul.admin@email.fr;3;0;paul32Mirabel32;"président"
|
|
@ -75,8 +75,8 @@ class user extends common
|
|||||||
|
|
||||||
public static $alphabet = [];
|
public static $alphabet = [];
|
||||||
|
|
||||||
public static $courseGroups = [
|
public static $usersGroups = [
|
||||||
'all' => 'Tout'
|
'all' => 'Tous'
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -133,6 +133,7 @@ class user extends common
|
|||||||
'accessTimer' => null,
|
'accessTimer' => null,
|
||||||
'accessCsrf' => null,
|
'accessCsrf' => null,
|
||||||
'language' => $this->getInput('userEditLanguage', helper::FILTER_STRING_SHORT),
|
'language' => $this->getInput('userEditLanguage', helper::FILTER_STRING_SHORT),
|
||||||
|
'tags' => ''
|
||||||
]
|
]
|
||||||
]);
|
]);
|
||||||
|
|
||||||
@ -343,6 +344,7 @@ class user extends common
|
|||||||
'accessCsrf' => $this->getData(['user', $this->getUrl(2), 'accessCsrf']),
|
'accessCsrf' => $this->getData(['user', $this->getUrl(2), 'accessCsrf']),
|
||||||
'files' => $this->getInput('userEditFiles', helper::FILTER_BOOLEAN),
|
'files' => $this->getInput('userEditFiles', helper::FILTER_BOOLEAN),
|
||||||
'language' => $this->getInput('userEditLanguage', helper::FILTER_STRING_SHORT),
|
'language' => $this->getInput('userEditLanguage', helper::FILTER_STRING_SHORT),
|
||||||
|
'tags' => $this->getInput('userEditTags', helper::FILTER_STRING_SHORT),
|
||||||
]
|
]
|
||||||
]);
|
]);
|
||||||
// Redirection spécifique si l'utilisateur change son mot de passe
|
// Redirection spécifique si l'utilisateur change son mot de passe
|
||||||
@ -447,20 +449,22 @@ class user extends common
|
|||||||
public function index()
|
public function index()
|
||||||
{
|
{
|
||||||
// Liste des groupes et des profils
|
// Liste des groupes et des profils
|
||||||
$courseGroups = $this->getData(['profil']);
|
$usersGroups = $this->getData(['profil']);
|
||||||
foreach ($courseGroups as $groupId => $groupValue) {
|
foreach ($usersGroups as $groupId => $groupValue) {
|
||||||
switch ($groupId) {
|
switch ($groupId) {
|
||||||
case "-1":
|
case "-1":
|
||||||
case "0":
|
case "0":
|
||||||
break;
|
break;
|
||||||
case "3":
|
case "3":
|
||||||
self::$courseGroups['30'] = 'Administrateur';
|
self::$usersGroups['30'] = 'Administrateur';
|
||||||
|
$profils['30'] = 0;
|
||||||
break;
|
break;
|
||||||
case "1":
|
case "1":
|
||||||
case "2":
|
case "2":
|
||||||
foreach ($groupValue as $profilId => $profilValue) {
|
foreach ($groupValue as $profilId => $profilValue) {
|
||||||
if ($profilId) {
|
if ($profilId) {
|
||||||
self::$courseGroups[$groupId . $profilId] = sprintf(helper::translate('Groupe %s - Profil %s'), self::$groupPublics[$groupId], $profilValue['name']);
|
self::$usersGroups[$groupId . $profilId] = sprintf(helper::translate('Groupe %s - Profil %s'), self::$groupPublics[$groupId], $profilValue['name']);
|
||||||
|
$profils[$groupId . $profilId] = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -470,13 +474,17 @@ class user extends common
|
|||||||
self::$alphabet = range('A', 'Z');
|
self::$alphabet = range('A', 'Z');
|
||||||
$alphabet = range('A', 'Z');
|
$alphabet = range('A', 'Z');
|
||||||
self::$alphabet = array_combine($alphabet, self::$alphabet);
|
self::$alphabet = array_combine($alphabet, self::$alphabet);
|
||||||
self::$alphabet = array_merge(['all' => 'Tout'], self::$alphabet);
|
self::$alphabet = array_merge(['all' => 'Toute'], self::$alphabet);
|
||||||
|
|
||||||
// Liste des membres
|
// Liste des membres
|
||||||
$userIdsLastNames = helper::arrayColumn($this->getData(['user']), 'lastname');
|
$userIdsLastNames = helper::arrayColumn($this->getData(['user']), 'lastname');
|
||||||
ksort($userIdsLastNames);
|
ksort($userIdsLastNames);
|
||||||
foreach ($userIdsLastNames as $userId => $userLastNames) {
|
foreach ($userIdsLastNames as $userId => $userLastNames) {
|
||||||
if ($this->getData(['user', $userId, 'group'])) {
|
if ($this->getData(['user', $userId, 'group'])) {
|
||||||
|
|
||||||
|
// Compte les rôles
|
||||||
|
$profils[$this->getData(['user', $userId, 'group']) . $this->getData(['user', $userId, 'profil'])]++;
|
||||||
|
|
||||||
// Filtres
|
// Filtres
|
||||||
if ($this->isPost()) {
|
if ($this->isPost()) {
|
||||||
// Groupe et profils
|
// Groupe et profils
|
||||||
@ -503,6 +511,8 @@ class user extends common
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// Formatage de la liste
|
// Formatage de la liste
|
||||||
self::$users[] = [
|
self::$users[] = [
|
||||||
$userId,
|
$userId,
|
||||||
@ -511,6 +521,7 @@ class user extends common
|
|||||||
empty($this->getData(['profil', $this->getData(['user', $userId, 'group']), $this->getData(['user', $userId, 'profil']), 'name']))
|
empty($this->getData(['profil', $this->getData(['user', $userId, 'group']), $this->getData(['user', $userId, 'profil']), 'name']))
|
||||||
? helper::translate(self::$groups[(int) $this->getData(['user', $userId, 'group'])])
|
? helper::translate(self::$groups[(int) $this->getData(['user', $userId, 'group'])])
|
||||||
: $this->getData(['profil', $this->getData(['user', $userId, 'group']), $this->getData(['user', $userId, 'profil']), 'name']),
|
: $this->getData(['profil', $this->getData(['user', $userId, 'group']), $this->getData(['user', $userId, 'profil']), 'name']),
|
||||||
|
$this->getData(['user', $userId, 'tags']),
|
||||||
template::button('userEdit' . $userId, [
|
template::button('userEdit' . $userId, [
|
||||||
'href' => helper::baseUrl() . 'user/edit/' . $userId,
|
'href' => helper::baseUrl() . 'user/edit/' . $userId,
|
||||||
'value' => template::ico('pencil'),
|
'value' => template::ico('pencil'),
|
||||||
@ -523,6 +534,16 @@ class user extends common
|
|||||||
'help' => 'Supprimer'
|
'help' => 'Supprimer'
|
||||||
])
|
])
|
||||||
];
|
];
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Ajoute les effectifs aux profils du sélecteur
|
||||||
|
foreach (self::$usersGroups as $groupId => $groupValue) {
|
||||||
|
if ($groupId === 'all') {
|
||||||
|
self::$usersGroups['all'] = self::$usersGroups['all'] . ' (' . array_sum($profils) . ')';
|
||||||
|
} else {
|
||||||
|
self::$usersGroups[$groupId] = self::$usersGroups[$groupId] . ' (' . $profils[$groupId] . ')';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -702,10 +723,16 @@ class user extends common
|
|||||||
self::$sharePath = array_merge(['./site/file/source/' => 'Tous les dossiers'], self::$sharePath);
|
self::$sharePath = array_merge(['./site/file/source/' => 'Tous les dossiers'], self::$sharePath);
|
||||||
self::$sharePath = array_merge([null => 'Aucun dossier'], self::$sharePath);
|
self::$sharePath = array_merge([null => 'Aucun dossier'], self::$sharePath);
|
||||||
|
|
||||||
|
// Chemin vers les dossiers du gestionnaire de fichier
|
||||||
|
self::$sharePath = $this->getSubdirectories('./site/file/source');
|
||||||
|
self::$sharePath = array_flip(self::$sharePath);
|
||||||
|
self::$sharePath = array_merge(['./site/file/source/' => 'Tous les dossiers'], self::$sharePath);
|
||||||
|
self::$sharePath = array_merge([null => 'Aucun dossier'], self::$sharePath);
|
||||||
|
|
||||||
// Liste des modules installés
|
// Liste des modules installés
|
||||||
self::$listModules = helper::getModules();
|
self::$listModules = helper::getModules();
|
||||||
self::$listModules = array_keys(self::$listModules);
|
self::$listModules = array_keys(self::$listModules);
|
||||||
|
|
||||||
// Charge les dialogues du module pour afficher les traductions
|
// Charge les dialogues du module pour afficher les traductions
|
||||||
foreach (self::$listModules as $moduleId) {
|
foreach (self::$listModules as $moduleId) {
|
||||||
if (
|
if (
|
||||||
@ -868,7 +895,7 @@ class user extends common
|
|||||||
// Liste des modules installés
|
// Liste des modules installés
|
||||||
self::$listModules = helper::getModules();
|
self::$listModules = helper::getModules();
|
||||||
self::$listModules = array_keys(self::$listModules);
|
self::$listModules = array_keys(self::$listModules);
|
||||||
|
|
||||||
// Charge les dialogues du module pour afficher les traductions
|
// Charge les dialogues du module pour afficher les traductions
|
||||||
foreach (self::$listModules as $moduleId) {
|
foreach (self::$listModules as $moduleId) {
|
||||||
if (
|
if (
|
||||||
@ -1177,17 +1204,22 @@ class user extends common
|
|||||||
and array_key_exists('prenom', $item)
|
and array_key_exists('prenom', $item)
|
||||||
and array_key_exists('nom', $item)
|
and array_key_exists('nom', $item)
|
||||||
and array_key_exists('groupe', $item)
|
and array_key_exists('groupe', $item)
|
||||||
|
and array_key_exists('profil', $item)
|
||||||
and array_key_exists('email', $item)
|
and array_key_exists('email', $item)
|
||||||
and array_key_exists('passe', $item)
|
and array_key_exists('passe', $item)
|
||||||
and $item['nom']
|
and array_key_exists('tags', $item)
|
||||||
and $item['prenom']
|
and isset($item['id'])
|
||||||
and $item['id']
|
and isset($item['nom'])
|
||||||
and $item['email']
|
and isset($item['prenom'])
|
||||||
and $item['groupe']
|
and isset($item['email'])
|
||||||
and $item['passe']
|
and isset($item['groupe'])
|
||||||
|
and isset($item['profil'])
|
||||||
|
and isset($item['passe'])
|
||||||
|
and isset($item['tags'])
|
||||||
) {
|
) {
|
||||||
// Validation du groupe
|
// Validation du groupe
|
||||||
$item['groupe'] = (int) $item['groupe'];
|
$item['groupe'] = (int) $item['groupe'];
|
||||||
|
$item['profil'] = (int) $item['profil'];
|
||||||
$item['groupe'] = ($item['groupe'] >= self::GROUP_BANNED and $item['groupe'] <= self::GROUP_ADMIN)
|
$item['groupe'] = ($item['groupe'] >= self::GROUP_BANNED and $item['groupe'] <= self::GROUP_ADMIN)
|
||||||
? $item['groupe'] : 1;
|
? $item['groupe'] : 1;
|
||||||
// L'utilisateur existe
|
// L'utilisateur existe
|
||||||
@ -1200,8 +1232,12 @@ class user extends common
|
|||||||
$item['nom'],
|
$item['nom'],
|
||||||
$item['prenom'],
|
$item['prenom'],
|
||||||
self::$groups[$item['groupe']],
|
self::$groups[$item['groupe']],
|
||||||
|
($this->getData(['profil', $item['groupe'], $item['profil'], 'name']) !== null )
|
||||||
|
? $this->getData(['profil', $item['groupe'], $item['profil'], 'name'])
|
||||||
|
: $item['profil'],
|
||||||
$item['prenom'],
|
$item['prenom'],
|
||||||
helper::filter($item['email'], helper::FILTER_MAIL),
|
helper::filter($item['email'], helper::FILTER_MAIL),
|
||||||
|
$item['tags'],
|
||||||
$item['notification']
|
$item['notification']
|
||||||
];
|
];
|
||||||
// L'utilisateur n'existe pas
|
// L'utilisateur n'existe pas
|
||||||
@ -1216,6 +1252,7 @@ class user extends common
|
|||||||
'firstname' => $item['prenom'],
|
'firstname' => $item['prenom'],
|
||||||
'forgot' => 0,
|
'forgot' => 0,
|
||||||
'group' => $item['groupe'],
|
'group' => $item['groupe'],
|
||||||
|
'profil' => $item['profil'],
|
||||||
'lastname' => $item['nom'],
|
'lastname' => $item['nom'],
|
||||||
'mail' => $item['email'],
|
'mail' => $item['email'],
|
||||||
'pseudo' => $item['prenom'],
|
'pseudo' => $item['prenom'],
|
||||||
@ -1227,7 +1264,8 @@ class user extends common
|
|||||||
"connectTimeout" => null,
|
"connectTimeout" => null,
|
||||||
"accessUrl" => null,
|
"accessUrl" => null,
|
||||||
"accessTimer" => null,
|
"accessTimer" => null,
|
||||||
"accessCsrf" => null
|
"accessCsrf" => null,
|
||||||
|
'tags' => $item['tags']
|
||||||
]
|
]
|
||||||
]);
|
]);
|
||||||
// Icône de notification
|
// Icône de notification
|
||||||
@ -1253,17 +1291,23 @@ class user extends common
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Création du tableau de confirmation
|
// Création du tableau de confirmation
|
||||||
|
var_dump( $item['profil']);
|
||||||
self::$users[] = [
|
self::$users[] = [
|
||||||
$userId,
|
$userId,
|
||||||
$item['nom'],
|
$item['nom'],
|
||||||
$item['prenom'],
|
$item['prenom'],
|
||||||
self::$groups[$item['groupe']],
|
self::$groups[$item['groupe']],
|
||||||
|
($this->getData(['profil', $item['groupe'], $item['profil'], 'name']) !== null )
|
||||||
|
? $this->getData(['profil', $item['groupe'], $item['profil'], 'name'])
|
||||||
|
: $item['profil'],
|
||||||
$item['prenom'],
|
$item['prenom'],
|
||||||
$item['email'],
|
$item['email'],
|
||||||
|
$item['tags'],
|
||||||
$item['notification']
|
$item['notification']
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
if (empty(self::$users)) {
|
if (empty(self::$users)) {
|
||||||
$notification = helper::translate('Rien à importer, erreur de format ou fichier incorrect');
|
$notification = helper::translate('Rien à importer, erreur de format ou fichier incorrect');
|
||||||
|
@ -46,13 +46,28 @@
|
|||||||
]); ?>
|
]); ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<?php echo template::mail('userAddMail', [
|
<div class="row">
|
||||||
'autocomplete' => 'off',
|
<div class="col6">
|
||||||
'label' => 'Adresse électronique'
|
<?php echo template::mail('userAddMail', [
|
||||||
]); ?>
|
'autocomplete' => 'off',
|
||||||
<?php echo template::select('userAddLanguage', $module::$languagesInstalled, [
|
'label' => 'Adresse électronique'
|
||||||
'label' => 'Langues'
|
]); ?>
|
||||||
]); ?>
|
</div>
|
||||||
|
<div class="col6">
|
||||||
|
<?php echo template::select('userAddLanguage', $module::$languagesInstalled, [
|
||||||
|
'label' => 'Langues'
|
||||||
|
]); ?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col12">
|
||||||
|
<?php echo template::text('userAddTags', [
|
||||||
|
'label' => 'Etiquettes',
|
||||||
|
'value' => $this->getData(['user', $this->getUrl(2), 'tags']),
|
||||||
|
'help' => 'Le séparateur d\'étiquettes est l\'espace'
|
||||||
|
]); ?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col6">
|
<div class="col6">
|
||||||
@ -110,21 +125,23 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div id="userCommentProfil<?php echo self::GROUP_MEMBER; ?>" class="col12 displayNone userCommentProfil">
|
<div id="userCommentProfil<?php echo self::GROUP_MEMBER; ?>"
|
||||||
|
class="col12 displayNone userCommentProfil">
|
||||||
<?php echo template::textarea('useraddProfilComment' . self::GROUP_MEMBER, [
|
<?php echo template::textarea('useraddProfilComment' . self::GROUP_MEMBER, [
|
||||||
"value" => implode("\n",$module::$userProfilsComments[self::GROUP_MEMBER])
|
"value" => implode("\n", $module::$userProfilsComments[self::GROUP_MEMBER])
|
||||||
]);
|
]);
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
<div id="userCommentProfil<?php echo self::GROUP_EDITOR; ?>" class="col12 displayNone userCommentProfil">
|
<div id="userCommentProfil<?php echo self::GROUP_EDITOR; ?>"
|
||||||
|
class="col12 displayNone userCommentProfil">
|
||||||
<?php echo template::textarea('useraddProfilComment2' . self::GROUP_EDITOR, [
|
<?php echo template::textarea('useraddProfilComment2' . self::GROUP_EDITOR, [
|
||||||
"value" => implode("\n",$module::$userProfilsComments[self::GROUP_EDITOR])
|
"value" => implode("\n", $module::$userProfilsComments[self::GROUP_EDITOR])
|
||||||
]);
|
]);
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
<div id="userCommentProfil<?php echo self::GROUP_ADMIN; ?>" class="col12 displayNone userCommentProfil">
|
<div id="userCommentProfil<?php echo self::GROUP_ADMIN; ?>" class="col12 displayNone userCommentProfil">
|
||||||
<?php echo template::textarea('useraddProfilComment' . self::GROUP_ADMIN, [
|
<?php echo template::textarea('useraddProfilComment' . self::GROUP_ADMIN, [
|
||||||
"value" => implode("\n",$module::$userProfilsComments[self::GROUP_ADMIN])
|
"value" => implode("\n", $module::$userProfilsComments[self::GROUP_ADMIN])
|
||||||
]);
|
]);
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
|
@ -58,15 +58,30 @@
|
|||||||
]); ?>
|
]); ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<?php echo template::mail('userEditMail', [
|
<div class="row">
|
||||||
'autocomplete' => 'off',
|
<div class="col6">
|
||||||
'label' => 'Adresse électronique',
|
<?php echo template::mail('userEditMail', [
|
||||||
'value' => $this->getData(['user', $this->getUrl(2), 'mail'])
|
'autocomplete' => 'off',
|
||||||
]); ?>
|
'label' => 'Adresse électronique',
|
||||||
<?php echo template::select('userEditLanguage', $module::$languagesInstalled, [
|
'value' => $this->getData(['user', $this->getUrl(2), 'mail'])
|
||||||
'label' => 'Langue',
|
]); ?>
|
||||||
'selected' => $this->getData(['user', $this->getUrl(2), 'language'])
|
</div>
|
||||||
]); ?>
|
<div class="col6">
|
||||||
|
<?php echo template::select('userEditLanguage', $module::$languagesInstalled, [
|
||||||
|
'label' => 'Langue',
|
||||||
|
'selected' => $this->getData(['user', $this->getUrl(2), 'language'])
|
||||||
|
]); ?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col12">
|
||||||
|
<?php echo template::text('userEditTags', [
|
||||||
|
'label' => 'Etiquettes',
|
||||||
|
'value' => $this->getData(['user', $this->getUrl(2), 'tags']),
|
||||||
|
'help' => 'Le séparateur d\'étiquettes est l\'espace'
|
||||||
|
]); ?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col6">
|
<div class="col6">
|
||||||
|
@ -7,20 +7,20 @@
|
|||||||
'value' => template::ico('left')
|
'value' => template::ico('left')
|
||||||
]); ?>
|
]); ?>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?php /**echo template::button('userHelp', [
|
<?php /**echo template::button('userHelp', [
|
||||||
'href' => 'https://doc.zwiicms.fr/importation-d-une-liste-d-utilisateurs',
|
'href' => 'https://doc.zwiicms.fr/importation-d-une-liste-d-utilisateurs',
|
||||||
'target' => '_blank',
|
'target' => '_blank',
|
||||||
'value' => template::ico('help'),
|
'value' => template::ico('help'),
|
||||||
'class' => 'buttonHelp',
|
'class' => 'buttonHelp',
|
||||||
'help' => 'Consulter l\'aide en ligne'
|
'help' => 'Consulter l\'aide en ligne'
|
||||||
]);*/ ?>
|
]);*/?>
|
||||||
<div class="col1 offset8">
|
<div class="col1 offset8">
|
||||||
<?php echo template::button('userImporTemplate', [
|
<?php echo template::button('userImporTemplate', [
|
||||||
'href' => helper::baseUrl() . 'user/template',
|
'href' => helper::baseUrl() . 'user/template',
|
||||||
'value' => template::ico('table'),
|
'value' => template::ico('table'),
|
||||||
'help' => 'Télécharger un modèle'
|
'help' => 'Télécharger un modèle'
|
||||||
]); ?>
|
]); ?>
|
||||||
</div>
|
</div>
|
||||||
<div class="col2">
|
<div class="col2">
|
||||||
<?php echo template::submit('userImportSubmit', [
|
<?php echo template::submit('userImportSubmit', [
|
||||||
@ -31,7 +31,8 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col12">
|
<div class="col12">
|
||||||
<div class="block">
|
<div class="block">
|
||||||
<h4><?php echo helper::translate('Importation de fichier plat CSV'); ?>
|
<h4>
|
||||||
|
<?php echo helper::translate('Importation de fichier plat CSV'); ?>
|
||||||
</h4>
|
</h4>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col10">
|
<div class="col10">
|
||||||
@ -57,11 +58,13 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<?php echo template::formClose(); ?>
|
<?php echo template::formClose(); ?>
|
||||||
<?php if ($module::$users) : ?>
|
<?php if ($module::$users): ?>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col12 textAlignCenter">
|
<div class="col12 textAlignCenter">
|
||||||
<?php echo template::table([1, 3, 3, 1, 1, 2, 1], $module::$users, ['Id', 'Nom', 'Prénom', 'Groupe', 'Pseudo', 'eMail', '']); ?>
|
<?php echo template::table([1, 2, 2, 1, 1, 1, 2, 1, 1], $module::$users, ['Id', 'Nom', 'Prénom', 'Groupe', 'Profil', 'Pseudo', 'eMail', 'Etiquettes', '']); ?>
|
||||||
<?php echo template::ico('check'); ?> Compte créé | <?php echo template::ico('mail'); ?> Compte créé et notifié | <?php echo template::ico('cancel'); ?> Erreur dans le fichier, compte non créé.
|
<?php echo template::ico('check'); ?> Compte créé |
|
||||||
|
<?php echo template::ico('mail'); ?> Compte créé et notifié |
|
||||||
|
<?php echo template::ico('cancel'); ?> Erreur dans le fichier ou le compte existe.
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
@ -10,6 +10,7 @@
|
|||||||
* @license CC Attribution-NonCommercial-NoDerivatives 4.0 International
|
* @license CC Attribution-NonCommercial-NoDerivatives 4.0 International
|
||||||
* @link http://zwiicms.fr/
|
* @link http://zwiicms.fr/
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$(document).ready((function () {
|
$(document).ready((function () {
|
||||||
$(".userDelete").on("click", (function () {
|
$(".userDelete").on("click", (function () {
|
||||||
var _this = $(this);
|
var _this = $(this);
|
||||||
@ -17,7 +18,14 @@ $(document).ready((function () {
|
|||||||
$(location).attr("href", _this.attr("href"))
|
$(location).attr("href", _this.attr("href"))
|
||||||
}))
|
}))
|
||||||
}));
|
}));
|
||||||
$("#userFilterGroup, #userFilterFirstName, #userFilterLastName").change(function() {
|
|
||||||
|
$("#userFilterGroup, #userFilterFirstName, #userFilterLastName").change(function () {
|
||||||
$("#userFilterUserForm").submit();
|
$("#userFilterUserForm").submit();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
$('#dataTables').DataTable({
|
||||||
|
language: {
|
||||||
|
url: "core/vendor/datatables/french.json"
|
||||||
|
}
|
||||||
|
});
|
||||||
}));
|
}));
|
@ -8,12 +8,12 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="col1">
|
<div class="col1">
|
||||||
<?php /**echo template::button('userHelp', [
|
<?php /**echo template::button('userHelp', [
|
||||||
'href' => 'https://doc.zwiicms.fr/gestion-des-utilisateurs',
|
'href' => 'https://doc.zwiicms.fr/gestion-des-utilisateurs',
|
||||||
'target' => '_blank',
|
'target' => '_blank',
|
||||||
'value' => template::ico('help'),
|
'value' => template::ico('help'),
|
||||||
'class' => 'buttonHelp',
|
'class' => 'buttonHelp',
|
||||||
'help' => 'Consulter l\'aide en ligne'
|
'help' => 'Consulter l\'aide en ligne'
|
||||||
]);*/ ?>
|
]);*/?>
|
||||||
</div>
|
</div>
|
||||||
<div class="col1 offset7">
|
<div class="col1 offset7">
|
||||||
<?php echo template::button('userImport', [
|
<?php echo template::button('userImport', [
|
||||||
@ -40,33 +40,24 @@
|
|||||||
</div>
|
</div>
|
||||||
<?php echo template::formOpen('userFilterUserForm'); ?>
|
<?php echo template::formOpen('userFilterUserForm'); ?>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col12">
|
<div class="col3">
|
||||||
<div class="block">
|
<?php echo template::select('userFilterGroup', $module::$usersGroups, [
|
||||||
<h4>
|
'label' => 'Groupes / Profils',
|
||||||
<?php echo helper::translate('Filtres'); ?>
|
'selected' => isset($_POST['userFilterGroup']) ? $_POST['userFilterGroup'] : 'all',
|
||||||
</h4>
|
]); ?>
|
||||||
<div class="row">
|
</div>
|
||||||
<div class="col3">
|
<div class="col3">
|
||||||
<?php echo template::select('userFilterGroup', $module::$courseGroups, [
|
<?php echo template::select('userFilterFirstName', $module::$alphabet, [
|
||||||
'label' => 'Groupes / Profils',
|
'label' => 'Prénom commence par',
|
||||||
'selected' => isset($_POST['userFilterGroup']) ? $_POST['userFilterGroup'] : 'all',
|
'selected' => isset($_POST['userFilterFirstName']) ? $_POST['userFilterFirstName'] : 'all',
|
||||||
]); ?>
|
]); ?>
|
||||||
</div>
|
</div>
|
||||||
<div class="col3">
|
<div class="col3">
|
||||||
<?php echo template::select('userFilterFirstName', $module::$alphabet, [
|
<?php echo template::select('userFilterLastName', $module::$alphabet, [
|
||||||
'label' => 'Prénom commence par',
|
'label' => 'Nom commence par',
|
||||||
'selected' => isset($_POST['userFilterFirstName']) ? $_POST['userFilterFirstName'] : 'all',
|
'selected' => isset($_POST['userFilterLastName']) ? $_POST['userFilterLastName'] : 'all',
|
||||||
]); ?>
|
]); ?>
|
||||||
</div>
|
</div>
|
||||||
<div class="col3">
|
|
||||||
<?php echo template::select('userFilterLastName', $module::$alphabet, [
|
|
||||||
'label' => 'Nom commence par',
|
|
||||||
'selected' => isset($_POST['userFilterLastName']) ? $_POST['userFilterLastName'] : 'all',
|
|
||||||
]); ?>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
<?php echo template::formClose(); ?>
|
<?php echo template::formClose(); ?>
|
||||||
<?php echo template::table([2, 2 , 3, 3, 1, 1], $module::$users, ['Identifiant', 'Nom', 'Groupe', 'Profil', '', '']); ?>
|
<?php echo template::table([2, 2, 2, 2, 2, 1, 1], $module::$users, ['Identifiant', 'Nom', 'Groupe', 'Profil', 'Etiquette', '', ''], ['id' => 'dataTables']); ?>
|
@ -9,6 +9,8 @@
|
|||||||
* @link http://zwiicms.fr/
|
* @link http://zwiicms.fr/
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/** @import url("site/data/admin.css"); */
|
||||||
|
|
||||||
/** NE PAS EFFACER
|
/** NE PAS EFFACER
|
||||||
* admin.css
|
* admin.css
|
||||||
*/
|
*/
|
||||||
@ -19,6 +21,7 @@
|
|||||||
#passwordIcon {
|
#passwordIcon {
|
||||||
float: right;
|
float: right;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media screen and (max-width: 768px) {
|
@media screen and (max-width: 768px) {
|
||||||
#buttonsContainer {
|
#buttonsContainer {
|
||||||
display: grid;
|
display: grid;
|
||||||
|
@ -51,4 +51,5 @@
|
|||||||
'ico' => ''
|
'ico' => ''
|
||||||
]); ?>
|
]); ?>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
<?php echo template::formClose(); ?>
|
<?php echo template::formClose(); ?>
|
@ -12,7 +12,13 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col3 offset9">
|
<div class="col3">
|
||||||
|
<?php echo template::button('userResetBack', [
|
||||||
|
'href' => helper::baseUrl(),
|
||||||
|
'value' => template::ico('left')
|
||||||
|
]); ?>
|
||||||
|
</div>
|
||||||
|
<div class="col3 offset6">
|
||||||
<?php echo template::submit('userResetSubmit', [
|
<?php echo template::submit('userResetSubmit', [
|
||||||
'value' => 'Valider'
|
'value' => 'Valider'
|
||||||
]); ?>
|
]); ?>
|
||||||
|
Loading…
Reference in New Issue
Block a user