|
@@ -3,7 +3,7 @@
|
|
|
<head>
|
|
<head>
|
|
|
<meta charset="UTF-8">
|
|
<meta charset="UTF-8">
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
|
- <title>Admin - Gestion des droits d'accès - RH</title>
|
|
|
|
|
|
|
+ <title>Admin - Gestion des utilisateurs</title>
|
|
|
|
|
|
|
|
<!-- Tailwind CSS CDN -->
|
|
<!-- Tailwind CSS CDN -->
|
|
|
<script src="https://cdn.tailwindcss.com"></script>
|
|
<script src="https://cdn.tailwindcss.com"></script>
|
|
@@ -13,6 +13,7 @@
|
|
|
button[role="tab"][aria-selected="true"] {
|
|
button[role="tab"][aria-selected="true"] {
|
|
|
background-color: white !important;
|
|
background-color: white !important;
|
|
|
color: rgb(31, 41, 55) !important; /* text-gray-800 */
|
|
color: rgb(31, 41, 55) !important; /* text-gray-800 */
|
|
|
|
|
+ border-bottom: 2px solid rgb(37, 99, 235) !important; /* border-blue-600 */
|
|
|
}
|
|
}
|
|
|
@media (prefers-color-scheme: dark) {
|
|
@media (prefers-color-scheme: dark) {
|
|
|
button[role="tab"].active,
|
|
button[role="tab"].active,
|
|
@@ -38,323 +39,361 @@
|
|
|
|
|
|
|
|
<!-- Page Header -->
|
|
<!-- Page Header -->
|
|
|
<div class="mb-6">
|
|
<div class="mb-6">
|
|
|
- <div class="flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4">
|
|
|
|
|
- <!-- Title -->
|
|
|
|
|
- <div>
|
|
|
|
|
- <h1 class="text-2xl font-semibold text-gray-800 dark:text-white">Admin - Gestion des droits d'accès - RH</h1>
|
|
|
|
|
- </div>
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <h1 class="text-2xl font-semibold text-gray-800 dark:text-white">Gestion des utilisateurs</h1>
|
|
|
|
|
+ <p class="mt-2 text-sm text-gray-600 dark:text-neutral-400">Gérez les utilisateurs et leurs droits d'accès</p>
|
|
|
</div>
|
|
</div>
|
|
|
<!-- End Page Header -->
|
|
<!-- End Page Header -->
|
|
|
|
|
|
|
|
- <!-- Access Selection Section -->
|
|
|
|
|
- <div class="mb-8">
|
|
|
|
|
- <div class="bg-white border border-gray-200 rounded-xl shadow-sm p-6 dark:bg-neutral-800 dark:border-neutral-700">
|
|
|
|
|
- <div class="flex flex-col sm:flex-row items-center justify-center gap-4">
|
|
|
|
|
- <label for="access-select" class="text-base font-semibold text-gray-800 dark:text-neutral-200 whitespace-nowrap">
|
|
|
|
|
- Accès à
|
|
|
|
|
- </label>
|
|
|
|
|
- <div class="hs-dropdown relative inline-flex">
|
|
|
|
|
- <button id="hs-dropdown-access" type="button" class="hs-dropdown-toggle py-3 px-6 inline-flex items-center gap-x-3 text-base font-medium rounded-lg border-2 border-gray-300 bg-white text-gray-800 shadow-sm hover:bg-gray-50 hover:border-blue-500 focus:outline-hidden focus:ring-2 focus:ring-blue-500 focus:border-blue-500 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-600 dark:text-white dark:hover:bg-neutral-700 dark:hover:border-blue-500 transition-colors min-w-[200px] justify-between" aria-expanded="false">
|
|
|
|
|
- <span id="selected-site" class="font-semibold">Site</span>
|
|
|
|
|
- <svg class="hs-dropdown-open:rotate-180 size-5 text-gray-600 dark:text-neutral-400 transition-transform" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
- <path d="m6 9 6 6 6-6"/>
|
|
|
|
|
|
|
+ <!-- Tabs Navigation -->
|
|
|
|
|
+ <div class="mb-6">
|
|
|
|
|
+ <nav class="flex border-b border-gray-200 dark:border-neutral-700" aria-label="Tabs" role="tablist">
|
|
|
|
|
+ <button type="button" class="hs-tab-active:font-semibold hs-tab-active:border-blue-600 hs-tab-active:text-blue-600 py-4 px-6 inline-flex items-center gap-x-2 border-b-2 border-transparent text-sm whitespace-nowrap text-gray-500 hover:text-blue-600 focus:outline-none focus:text-blue-600 disabled:opacity-50 disabled:pointer-events-none dark:text-neutral-400 dark:hover:text-blue-500 active" id="tab-utilisateurs" data-hs-tab="#tab-content-utilisateurs" aria-controls="tab-content-utilisateurs" role="tab">
|
|
|
|
|
+ <svg class="flex-shrink-0 size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
+ <path d="M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2"/>
|
|
|
|
|
+ <circle cx="9" cy="7" r="4"/>
|
|
|
|
|
+ <path d="M22 21v-2a4 4 0 0 0-3-3.87"/>
|
|
|
|
|
+ <path d="M16 3.13a4 4 0 0 1 0 7.75"/>
|
|
|
|
|
+ </svg>
|
|
|
|
|
+ Utilisateurs
|
|
|
|
|
+ </button>
|
|
|
|
|
+ <button type="button" class="hs-tab-active:font-semibold hs-tab-active:border-blue-600 hs-tab-active:text-blue-600 py-4 px-6 inline-flex items-center gap-x-2 border-b-2 border-transparent text-sm whitespace-nowrap text-gray-500 hover:text-blue-600 focus:outline-none focus:text-blue-600 disabled:opacity-50 disabled:pointer-events-none dark:text-neutral-400 dark:hover:text-blue-500" id="tab-droits" data-hs-tab="#tab-content-droits" aria-controls="tab-content-droits" role="tab">
|
|
|
|
|
+ <svg class="flex-shrink-0 size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
+ <rect width="18" height="11" x="3" y="11" rx="2" ry="2"/>
|
|
|
|
|
+ <path d="M7 11V7a5 5 0 0 1 10 0v4"/>
|
|
|
</svg>
|
|
</svg>
|
|
|
|
|
+ Attribution des droits
|
|
|
</button>
|
|
</button>
|
|
|
-
|
|
|
|
|
- <div class="hs-dropdown-menu transition-[opacity,margin] duration hs-dropdown-open:opacity-100 opacity-0 hidden min-w-[200px] bg-white shadow-lg rounded-lg p-2 mt-2 dark:bg-neutral-800 dark:border dark:border-neutral-700 z-10" role="menu" aria-labelledby="hs-dropdown-access">
|
|
|
|
|
- <a class="flex items-center gap-x-3.5 py-3 px-4 rounded-lg text-sm font-medium text-gray-800 hover:bg-gray-100 focus:outline-hidden focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 transition-colors" href="#" role="menuitem">
|
|
|
|
|
- Admin RH
|
|
|
|
|
- </a>
|
|
|
|
|
- <a class="flex items-center gap-x-3.5 py-3 px-4 rounded-lg text-sm font-medium text-gray-800 hover:bg-gray-100 focus:outline-hidden focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 transition-colors" href="#" role="menuitem">
|
|
|
|
|
- Admin IT
|
|
|
|
|
- </a>
|
|
|
|
|
- <a class="flex items-center gap-x-3.5 py-3 px-4 rounded-lg text-sm font-medium text-gray-800 hover:bg-gray-100 focus:outline-hidden focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 transition-colors" href="#" role="menuitem">
|
|
|
|
|
- Dashboard IT
|
|
|
|
|
- </a>
|
|
|
|
|
- <a class="flex items-center gap-x-3.5 py-3 px-4 rounded-lg text-sm font-medium text-gray-800 hover:bg-gray-100 focus:outline-hidden focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 transition-colors" href="#" role="menuitem">
|
|
|
|
|
- Dashboard RH
|
|
|
|
|
- </a>
|
|
|
|
|
- <a class="flex items-center gap-x-3.5 py-3 px-4 rounded-lg text-sm font-medium text-gray-800 hover:bg-gray-100 focus:outline-hidden focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 transition-colors" href="#" role="menuitem">
|
|
|
|
|
- Auto 33
|
|
|
|
|
- </a>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ </nav>
|
|
|
</div>
|
|
</div>
|
|
|
- <!-- End Access Selection Section -->
|
|
|
|
|
|
|
+ <!-- End Tabs Navigation -->
|
|
|
|
|
+
|
|
|
|
|
+ <!-- Tab Contents -->
|
|
|
|
|
+ <div class="mt-3">
|
|
|
|
|
+ <!-- Tab 1: Utilisateurs -->
|
|
|
|
|
+ <div id="tab-content-utilisateurs" role="tabpanel" aria-labelledby="tab-utilisateurs">
|
|
|
|
|
|
|
|
- <!-- Table Section -->
|
|
|
|
|
|
|
+ <!-- Liste des utilisateurs -->
|
|
|
<div class="flex flex-col">
|
|
<div class="flex flex-col">
|
|
|
<div class="-m-1.5 overflow-x-auto">
|
|
<div class="-m-1.5 overflow-x-auto">
|
|
|
<div class="p-1.5 min-w-full inline-block align-middle">
|
|
<div class="p-1.5 min-w-full inline-block align-middle">
|
|
|
- <div class="bg-white border border-gray-200 rounded-xl shadow-2xs overflow-hidden dark:bg-neutral-900 dark:border-neutral-700">
|
|
|
|
|
|
|
+ <div class="bg-white border border-gray-200 rounded-xl shadow-sm overflow-hidden dark:bg-neutral-900 dark:border-neutral-700">
|
|
|
|
|
+ <!-- Header with Add Button -->
|
|
|
|
|
+ <div class="px-6 py-4 border-b border-gray-200 dark:border-neutral-700 flex justify-between items-center">
|
|
|
|
|
+ <h2 class="text-lg font-semibold text-gray-800 dark:text-white">Liste des utilisateurs</h2>
|
|
|
|
|
+ <button type="button" id="btn-add-user" class="py-2 px-4 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg border border-transparent bg-blue-600 text-white hover:bg-blue-700 focus:outline-none focus:bg-blue-700 transition-colors" data-hs-overlay="#modal-ajouter-utilisateur">
|
|
|
|
|
+ <svg class="size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
+ <path d="M5 12h14"/>
|
|
|
|
|
+ <path d="M12 5v14"/>
|
|
|
|
|
+ </svg>
|
|
|
|
|
+ Nouvel utilisateur
|
|
|
|
|
+ </button>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <!-- End Header -->
|
|
|
|
|
+
|
|
|
<!-- Table -->
|
|
<!-- Table -->
|
|
|
<table class="min-w-full divide-y divide-gray-200 dark:divide-neutral-700">
|
|
<table class="min-w-full divide-y divide-gray-200 dark:divide-neutral-700">
|
|
|
<thead class="bg-gray-50 dark:bg-neutral-900">
|
|
<thead class="bg-gray-50 dark:bg-neutral-900">
|
|
|
<tr>
|
|
<tr>
|
|
|
<th scope="col" class="px-6 py-3 text-start">
|
|
<th scope="col" class="px-6 py-3 text-start">
|
|
|
- <div class="flex items-center gap-x-2">
|
|
|
|
|
- <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">
|
|
|
|
|
- Collaborateur
|
|
|
|
|
- </span>
|
|
|
|
|
- <svg class="size-3 text-gray-400" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
- <path d="m6 9 6 6 6-6"/>
|
|
|
|
|
- </svg>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">Nom</span>
|
|
|
</th>
|
|
</th>
|
|
|
-
|
|
|
|
|
<th scope="col" class="px-6 py-3 text-start">
|
|
<th scope="col" class="px-6 py-3 text-start">
|
|
|
- <div class="flex items-center gap-x-2">
|
|
|
|
|
- <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">
|
|
|
|
|
- Site
|
|
|
|
|
- </span>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">Email</span>
|
|
|
</th>
|
|
</th>
|
|
|
-
|
|
|
|
|
<th scope="col" class="px-6 py-3 text-start">
|
|
<th scope="col" class="px-6 py-3 text-start">
|
|
|
- <div class="flex items-center gap-x-2">
|
|
|
|
|
- <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">
|
|
|
|
|
- Rôle/Groupes utilisateurs
|
|
|
|
|
- </span>
|
|
|
|
|
- </div>
|
|
|
|
|
- </th>
|
|
|
|
|
-
|
|
|
|
|
- <th scope="col" class="px-6 py-3 text-start">
|
|
|
|
|
- <div class="flex items-center gap-x-2">
|
|
|
|
|
- <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">
|
|
|
|
|
- Notification mails
|
|
|
|
|
- </span>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">Date de création</span>
|
|
|
</th>
|
|
</th>
|
|
|
-
|
|
|
|
|
- <th scope="col" class="px-6 py-3 text-start">
|
|
|
|
|
- <div class="flex items-center gap-x-2">
|
|
|
|
|
- <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">
|
|
|
|
|
- Actions
|
|
|
|
|
- </span>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <th scope="col" class="px-6 py-3 text-end">
|
|
|
|
|
+ <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">Actions</span>
|
|
|
</th>
|
|
</th>
|
|
|
</tr>
|
|
</tr>
|
|
|
</thead>
|
|
</thead>
|
|
|
|
|
|
|
|
<tbody class="divide-y divide-gray-200 dark:divide-neutral-700">
|
|
<tbody class="divide-y divide-gray-200 dark:divide-neutral-700">
|
|
|
- <!-- Ligne 1 - Fond blanc -->
|
|
|
|
|
- <tr class="bg-white dark:bg-neutral-800">
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
|
|
+ <!-- Ligne 1 -->
|
|
|
|
|
+ <tr class="hover:bg-gray-50 dark:hover:bg-neutral-800">
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <div class="flex items-center gap-x-3">
|
|
|
|
|
+ <div class="flex-shrink-0 h-10 w-10">
|
|
|
|
|
+ <div class="h-10 w-10 rounded-full bg-blue-100 dark:bg-blue-900/30 flex items-center justify-center">
|
|
|
|
|
+ <span class="text-sm font-medium text-blue-800 dark:text-blue-300">JD</span>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
<span class="text-sm font-medium text-gray-800 dark:text-neutral-200">Jean Dupont</span>
|
|
<span class="text-sm font-medium text-gray-800 dark:text-neutral-200">Jean Dupont</span>
|
|
|
</div>
|
|
</div>
|
|
|
</td>
|
|
</td>
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <span class="text-sm text-gray-600 dark:text-neutral-400">Auto33</span>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <span class="text-sm text-gray-600 dark:text-neutral-400">jean.dupont@example.com</span>
|
|
|
</td>
|
|
</td>
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <span class="py-1 px-2 inline-flex items-center gap-x-1 text-xs font-medium bg-purple-100 text-purple-800 rounded-full dark:bg-purple-500/10 dark:text-purple-500">
|
|
|
|
|
- Comptable
|
|
|
|
|
- </span>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <span class="text-sm text-gray-600 dark:text-neutral-400">12/01/2025</span>
|
|
|
</td>
|
|
</td>
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <input type="checkbox" class="shrink-0 mt-0.5 border-gray-200 rounded text-blue-600 focus:ring-blue-500 dark:bg-neutral-800 dark:border-neutral-700 dark:checked:bg-blue-500 dark:checked:border-blue-500 dark:focus:ring-offset-gray-800" checked>
|
|
|
|
|
- </div>
|
|
|
|
|
- </td>
|
|
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <div class="flex items-center gap-x-2">
|
|
|
|
|
- <button type="button" class="hs-tooltip-toggle inline-flex items-center justify-center size-7 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700" title="Modifier">
|
|
|
|
|
- <svg class="size-4 text-gray-600 dark:text-neutral-400" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
- <path d="M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7"/>
|
|
|
|
|
- <path d="M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z"/>
|
|
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap text-end">
|
|
|
|
|
+ <button type="button" class="inline-flex items-center gap-x-2 text-sm font-medium text-red-600 hover:text-red-800 dark:text-red-400 dark:hover:text-red-300" title="Supprimer l'utilisateur">
|
|
|
|
|
+ <svg class="size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
+ <path d="M3 6h18"/>
|
|
|
|
|
+ <path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/>
|
|
|
|
|
+ <path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>
|
|
|
|
|
+ <line x1="10" x2="10" y1="11" y2="17"/>
|
|
|
|
|
+ <line x1="14" x2="14" y1="11" y2="17"/>
|
|
|
</svg>
|
|
</svg>
|
|
|
|
|
+ Supprimer
|
|
|
</button>
|
|
</button>
|
|
|
- <button type="button" class="hs-tooltip-toggle inline-flex items-center justify-center size-7 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700" title="Supprimer">
|
|
|
|
|
- <svg class="size-4 text-gray-600 dark:text-neutral-400" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
|
|
+ </td>
|
|
|
|
|
+ </tr>
|
|
|
|
|
+
|
|
|
|
|
+ <!-- Ligne 2 -->
|
|
|
|
|
+ <tr class="hover:bg-gray-50 dark:hover:bg-neutral-800">
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <div class="flex items-center gap-x-3">
|
|
|
|
|
+ <div class="flex-shrink-0 h-10 w-10">
|
|
|
|
|
+ <div class="h-10 w-10 rounded-full bg-purple-100 dark:bg-purple-900/30 flex items-center justify-center">
|
|
|
|
|
+ <span class="text-sm font-medium text-purple-800 dark:text-purple-300">MM</span>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <span class="text-sm font-medium text-gray-800 dark:text-neutral-200">Marie Martin</span>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </td>
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <span class="text-sm text-gray-600 dark:text-neutral-400">marie.martin@example.com</span>
|
|
|
|
|
+ </td>
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <span class="text-sm text-gray-600 dark:text-neutral-400">10/01/2025</span>
|
|
|
|
|
+ </td>
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap text-end">
|
|
|
|
|
+ <button type="button" class="inline-flex items-center gap-x-2 text-sm font-medium text-red-600 hover:text-red-800 dark:text-red-400 dark:hover:text-red-300" title="Supprimer l'utilisateur">
|
|
|
|
|
+ <svg class="size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
<path d="M3 6h18"/>
|
|
<path d="M3 6h18"/>
|
|
|
<path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/>
|
|
<path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/>
|
|
|
<path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>
|
|
<path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>
|
|
|
|
|
+ <line x1="10" x2="10" y1="11" y2="17"/>
|
|
|
|
|
+ <line x1="14" x2="14" y1="11" y2="17"/>
|
|
|
</svg>
|
|
</svg>
|
|
|
|
|
+ Supprimer
|
|
|
</button>
|
|
</button>
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
</td>
|
|
</td>
|
|
|
</tr>
|
|
</tr>
|
|
|
|
|
|
|
|
- <!-- Ligne 2 - Fond grisé alterné -->
|
|
|
|
|
- <tr class="dark:bg-green-900/20" style="background-color: rgba(245, 248, 246, 0.45);">
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <span class="text-sm font-medium text-gray-800 dark:text-neutral-200">Marie Martin</span>
|
|
|
|
|
|
|
+ <!-- Ligne 3 -->
|
|
|
|
|
+ <tr class="hover:bg-gray-50 dark:hover:bg-neutral-800">
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <div class="flex items-center gap-x-3">
|
|
|
|
|
+ <div class="flex-shrink-0 h-10 w-10">
|
|
|
|
|
+ <div class="h-10 w-10 rounded-full bg-green-100 dark:bg-green-900/30 flex items-center justify-center">
|
|
|
|
|
+ <span class="text-sm font-medium text-green-800 dark:text-green-300">PD</span>
|
|
|
|
|
+ </div>
|
|
|
</div>
|
|
</div>
|
|
|
- </td>
|
|
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <span class="text-sm text-gray-600 dark:text-neutral-400">Admin RH</span>
|
|
|
|
|
|
|
+ <span class="text-sm font-medium text-gray-800 dark:text-neutral-200">Pierre Durand</span>
|
|
|
</div>
|
|
</div>
|
|
|
</td>
|
|
</td>
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <span class="py-1 px-2 inline-flex items-center gap-x-1 text-xs font-medium bg-blue-100 text-blue-800 rounded-full dark:bg-blue-500/10 dark:text-blue-500">
|
|
|
|
|
- Administrateur
|
|
|
|
|
- </span>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <span class="text-sm text-gray-600 dark:text-neutral-400">pierre.durand@example.com</span>
|
|
|
</td>
|
|
</td>
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <input type="checkbox" class="shrink-0 mt-0.5 border-gray-200 rounded text-blue-600 focus:ring-blue-500 dark:bg-neutral-800 dark:border-neutral-700 dark:checked:bg-blue-500 dark:checked:border-blue-500 dark:focus:ring-offset-gray-800">
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <span class="text-sm text-gray-600 dark:text-neutral-400">08/01/2025</span>
|
|
|
</td>
|
|
</td>
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <div class="flex items-center gap-x-2">
|
|
|
|
|
- <button type="button" class="hs-tooltip-toggle inline-flex items-center justify-center size-7 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700" title="Modifier">
|
|
|
|
|
- <svg class="size-4 text-gray-600 dark:text-neutral-400" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
- <path d="M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7"/>
|
|
|
|
|
- <path d="M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z"/>
|
|
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap text-end">
|
|
|
|
|
+ <button type="button" class="inline-flex items-center gap-x-2 text-sm font-medium text-red-600 hover:text-red-800 dark:text-red-400 dark:hover:text-red-300" title="Supprimer l'utilisateur">
|
|
|
|
|
+ <svg class="size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
+ <path d="M3 6h18"/>
|
|
|
|
|
+ <path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/>
|
|
|
|
|
+ <path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>
|
|
|
|
|
+ <line x1="10" x2="10" y1="11" y2="17"/>
|
|
|
|
|
+ <line x1="14" x2="14" y1="11" y2="17"/>
|
|
|
</svg>
|
|
</svg>
|
|
|
|
|
+ Supprimer
|
|
|
</button>
|
|
</button>
|
|
|
- <button type="button" class="hs-tooltip-toggle inline-flex items-center justify-center size-7 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700" title="Supprimer">
|
|
|
|
|
- <svg class="size-4 text-gray-600 dark:text-neutral-400" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
|
|
+ </td>
|
|
|
|
|
+ </tr>
|
|
|
|
|
+
|
|
|
|
|
+ <!-- Ligne 4 -->
|
|
|
|
|
+ <tr class="hover:bg-gray-50 dark:hover:bg-neutral-800">
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <div class="flex items-center gap-x-3">
|
|
|
|
|
+ <div class="flex-shrink-0 h-10 w-10">
|
|
|
|
|
+ <div class="h-10 w-10 rounded-full bg-orange-100 dark:bg-orange-900/30 flex items-center justify-center">
|
|
|
|
|
+ <span class="text-sm font-medium text-orange-800 dark:text-orange-300">SB</span>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <span class="text-sm font-medium text-gray-800 dark:text-neutral-200">Sophie Bernard</span>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </td>
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <span class="text-sm text-gray-600 dark:text-neutral-400">sophie.bernard@example.com</span>
|
|
|
|
|
+ </td>
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <span class="text-sm text-gray-600 dark:text-neutral-400">05/01/2025</span>
|
|
|
|
|
+ </td>
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap text-end">
|
|
|
|
|
+ <button type="button" class="inline-flex items-center gap-x-2 text-sm font-medium text-red-600 hover:text-red-800 dark:text-red-400 dark:hover:text-red-300" title="Supprimer l'utilisateur">
|
|
|
|
|
+ <svg class="size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
<path d="M3 6h18"/>
|
|
<path d="M3 6h18"/>
|
|
|
<path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/>
|
|
<path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/>
|
|
|
<path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>
|
|
<path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>
|
|
|
|
|
+ <line x1="10" x2="10" y1="11" y2="17"/>
|
|
|
|
|
+ <line x1="14" x2="14" y1="11" y2="17"/>
|
|
|
</svg>
|
|
</svg>
|
|
|
|
|
+ Supprimer
|
|
|
</button>
|
|
</button>
|
|
|
|
|
+ </td>
|
|
|
|
|
+ </tr>
|
|
|
|
|
+ </tbody>
|
|
|
|
|
+ </table>
|
|
|
|
|
+ <!-- End Table -->
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
- </td>
|
|
|
|
|
- </tr>
|
|
|
|
|
-
|
|
|
|
|
- <!-- Ligne 3 - Fond blanc -->
|
|
|
|
|
- <tr class="bg-white dark:bg-neutral-800">
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <span class="text-sm font-medium text-gray-800 dark:text-neutral-200">Pierre Durand</span>
|
|
|
|
|
- </div>
|
|
|
|
|
- </td>
|
|
|
|
|
|
|
+ <!-- End Tab 1: Utilisateurs -->
|
|
|
|
|
+
|
|
|
|
|
+ <!-- Tab 2: Attribution des droits -->
|
|
|
|
|
+ <div id="tab-content-droits" class="hidden" role="tabpanel" aria-labelledby="tab-droits">
|
|
|
|
|
+ <!-- Access Selection -->
|
|
|
|
|
+ <div class="mb-6">
|
|
|
|
|
+ <div class="bg-white border border-gray-200 rounded-xl shadow-sm p-6 dark:bg-neutral-800 dark:border-neutral-700">
|
|
|
|
|
+ <div class="flex flex-col sm:flex-row items-center justify-center gap-4">
|
|
|
|
|
+ <label class="text-base font-semibold text-gray-800 dark:text-neutral-200 whitespace-nowrap">
|
|
|
|
|
+ Sélectionner un site
|
|
|
|
|
+ </label>
|
|
|
|
|
+ <div class="hs-dropdown relative inline-flex">
|
|
|
|
|
+ <button id="hs-dropdown-access" type="button" class="hs-dropdown-toggle py-3 px-6 inline-flex items-center gap-x-3 text-base font-medium rounded-lg border-2 border-gray-300 bg-white text-gray-800 shadow-sm hover:bg-gray-50 hover:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-blue-500 dark:bg-neutral-800 dark:border-neutral-600 dark:text-white dark:hover:bg-neutral-700 dark:hover:border-blue-500 transition-colors min-w-[200px] justify-between" aria-expanded="false">
|
|
|
|
|
+ <span id="selected-site" class="font-semibold">Auto 33</span>
|
|
|
|
|
+ <svg class="hs-dropdown-open:rotate-180 size-5 text-gray-600 dark:text-neutral-400 transition-transform" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
+ <path d="m6 9 6 6 6-6"/>
|
|
|
|
|
+ </svg>
|
|
|
|
|
+ </button>
|
|
|
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <span class="text-sm text-gray-600 dark:text-neutral-400">Dashboard RH</span>
|
|
|
|
|
|
|
+ <div class="hs-dropdown-menu transition-[opacity,margin] duration hs-dropdown-open:opacity-100 opacity-0 hidden min-w-[200px] bg-white shadow-lg rounded-lg p-2 mt-2 dark:bg-neutral-800 dark:border dark:border-neutral-700 z-10" role="menu" aria-labelledby="hs-dropdown-access">
|
|
|
|
|
+ <a class="flex items-center gap-x-3.5 py-3 px-4 rounded-lg text-sm font-medium text-gray-800 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 transition-colors" href="#" role="menuitem">
|
|
|
|
|
+ Auto 33
|
|
|
|
|
+ </a>
|
|
|
|
|
+ <a class="flex items-center gap-x-3.5 py-3 px-4 rounded-lg text-sm font-medium text-gray-800 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 transition-colors" href="#" role="menuitem">
|
|
|
|
|
+ Admin RH
|
|
|
|
|
+ </a>
|
|
|
|
|
+ <a class="flex items-center gap-x-3.5 py-3 px-4 rounded-lg text-sm font-medium text-gray-800 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 transition-colors" href="#" role="menuitem">
|
|
|
|
|
+ Admin IT
|
|
|
|
|
+ </a>
|
|
|
|
|
+ <a class="flex items-center gap-x-3.5 py-3 px-4 rounded-lg text-sm font-medium text-gray-800 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 transition-colors" href="#" role="menuitem">
|
|
|
|
|
+ Dashboard IT
|
|
|
|
|
+ </a>
|
|
|
|
|
+ <a class="flex items-center gap-x-3.5 py-3 px-4 rounded-lg text-sm font-medium text-gray-800 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-neutral-300 transition-colors" href="#" role="menuitem">
|
|
|
|
|
+ Dashboard RH
|
|
|
|
|
+ </a>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
</div>
|
|
</div>
|
|
|
- </td>
|
|
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <span class="py-1 px-2 inline-flex items-center gap-x-1 text-xs font-medium bg-green-100 text-green-800 rounded-full dark:bg-green-500/10 dark:text-green-500">
|
|
|
|
|
- RH
|
|
|
|
|
- </span>
|
|
|
|
|
|
|
+ <!-- End Access Selection -->
|
|
|
|
|
+
|
|
|
|
|
+ <!-- Table des droits -->
|
|
|
|
|
+ <div class="flex flex-col">
|
|
|
|
|
+ <div class="-m-1.5 overflow-x-auto">
|
|
|
|
|
+ <div class="p-1.5 min-w-full inline-block align-middle">
|
|
|
|
|
+ <div class="bg-white border border-gray-200 rounded-xl shadow-sm overflow-hidden dark:bg-neutral-900 dark:border-neutral-700">
|
|
|
|
|
+ <!-- Header with Add Button -->
|
|
|
|
|
+ <div class="px-6 py-4 border-b border-gray-200 dark:border-neutral-700 flex justify-between items-center">
|
|
|
|
|
+ <h2 class="text-lg font-semibold text-gray-800 dark:text-white">Droits d'accès pour <span id="site-title">Auto 33</span></h2>
|
|
|
|
|
+ <button type="button" id="btn-add-droit" class="py-2 px-4 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg border border-transparent bg-blue-600 text-white hover:bg-blue-700 focus:outline-none focus:bg-blue-700 transition-colors" data-hs-overlay="#modal-ajouter-droit">
|
|
|
|
|
+ <svg class="size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
+ <path d="M5 12h14"/>
|
|
|
|
|
+ <path d="M12 5v14"/>
|
|
|
|
|
+ </svg>
|
|
|
|
|
+ Ajouter un accès
|
|
|
|
|
+ </button>
|
|
|
</div>
|
|
</div>
|
|
|
- </td>
|
|
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <input type="checkbox" class="shrink-0 mt-0.5 border-gray-200 rounded text-blue-600 focus:ring-blue-500 dark:bg-neutral-800 dark:border-neutral-700 dark:checked:bg-blue-500 dark:checked:border-blue-500 dark:focus:ring-offset-gray-800" checked>
|
|
|
|
|
|
|
+ <!-- End Header -->
|
|
|
|
|
+
|
|
|
|
|
+ <!-- Table -->
|
|
|
|
|
+ <table class="min-w-full divide-y divide-gray-200 dark:divide-neutral-700">
|
|
|
|
|
+ <thead class="bg-gray-50 dark:bg-neutral-900">
|
|
|
|
|
+ <tr>
|
|
|
|
|
+ <th scope="col" class="px-6 py-3 text-start">
|
|
|
|
|
+ <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">Utilisateur</span>
|
|
|
|
|
+ </th>
|
|
|
|
|
+ <th scope="col" class="px-6 py-3 text-start">
|
|
|
|
|
+ <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">Rôle / Groupe</span>
|
|
|
|
|
+ </th>
|
|
|
|
|
+ <th scope="col" class="px-6 py-3 text-end">
|
|
|
|
|
+ <span class="text-xs font-semibold uppercase text-gray-800 dark:text-neutral-200">Actions</span>
|
|
|
|
|
+ </th>
|
|
|
|
|
+ </tr>
|
|
|
|
|
+ </thead>
|
|
|
|
|
+
|
|
|
|
|
+ <tbody class="divide-y divide-gray-200 dark:divide-neutral-700">
|
|
|
|
|
+ <!-- Ligne 1 -->
|
|
|
|
|
+ <tr class="hover:bg-gray-50 dark:hover:bg-neutral-800">
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <div class="flex items-center gap-x-3">
|
|
|
|
|
+ <div class="flex-shrink-0 h-10 w-10">
|
|
|
|
|
+ <div class="h-10 w-10 rounded-full bg-blue-100 dark:bg-blue-900/30 flex items-center justify-center">
|
|
|
|
|
+ <span class="text-sm font-medium text-blue-800 dark:text-blue-300">JD</span>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <span class="text-sm font-medium text-gray-800 dark:text-neutral-200">Jean Dupont</span>
|
|
|
</div>
|
|
</div>
|
|
|
</td>
|
|
</td>
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <div class="flex items-center gap-x-2">
|
|
|
|
|
- <button type="button" class="hs-tooltip-toggle inline-flex items-center justify-center size-7 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700" title="Modifier">
|
|
|
|
|
- <svg class="size-4 text-gray-600 dark:text-neutral-400" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
- <path d="M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7"/>
|
|
|
|
|
- <path d="M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z"/>
|
|
|
|
|
- </svg>
|
|
|
|
|
- </button>
|
|
|
|
|
- <button type="button" class="hs-tooltip-toggle inline-flex items-center justify-center size-7 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700" title="Supprimer">
|
|
|
|
|
- <svg class="size-4 text-gray-600 dark:text-neutral-400" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <span class="py-1 px-2 inline-flex items-center gap-x-1 text-xs font-medium bg-purple-100 text-purple-800 rounded-full dark:bg-purple-500/10 dark:text-purple-500">
|
|
|
|
|
+ Comptable
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </td>
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap text-end">
|
|
|
|
|
+ <button type="button" class="inline-flex items-center gap-x-2 text-sm font-medium text-red-600 hover:text-red-800 dark:text-red-400 dark:hover:text-red-300" title="Retirer l'accès">
|
|
|
|
|
+ <svg class="size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
<path d="M3 6h18"/>
|
|
<path d="M3 6h18"/>
|
|
|
<path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/>
|
|
<path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/>
|
|
|
<path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>
|
|
<path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>
|
|
|
|
|
+ <line x1="10" x2="10" y1="11" y2="17"/>
|
|
|
|
|
+ <line x1="14" x2="14" y1="11" y2="17"/>
|
|
|
</svg>
|
|
</svg>
|
|
|
|
|
+ Retirer
|
|
|
</button>
|
|
</button>
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
</td>
|
|
</td>
|
|
|
</tr>
|
|
</tr>
|
|
|
|
|
|
|
|
- <!-- Ligne 4 - Fond grisé alterné -->
|
|
|
|
|
- <tr class="dark:bg-green-900/20" style="background-color: rgba(245, 248, 246, 0.45);">
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
|
|
+ <!-- Ligne 2 -->
|
|
|
|
|
+ <tr class="hover:bg-gray-50 dark:hover:bg-neutral-800">
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
|
|
+ <div class="flex items-center gap-x-3">
|
|
|
|
|
+ <div class="flex-shrink-0 h-10 w-10">
|
|
|
|
|
+ <div class="h-10 w-10 rounded-full bg-orange-100 dark:bg-orange-900/30 flex items-center justify-center">
|
|
|
|
|
+ <span class="text-sm font-medium text-orange-800 dark:text-orange-300">SB</span>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
<span class="text-sm font-medium text-gray-800 dark:text-neutral-200">Sophie Bernard</span>
|
|
<span class="text-sm font-medium text-gray-800 dark:text-neutral-200">Sophie Bernard</span>
|
|
|
</div>
|
|
</div>
|
|
|
</td>
|
|
</td>
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <span class="text-sm text-gray-600 dark:text-neutral-400">Auto33</span>
|
|
|
|
|
- </div>
|
|
|
|
|
- </td>
|
|
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap">
|
|
|
<span class="py-1 px-2 inline-flex items-center gap-x-1 text-xs font-medium bg-orange-100 text-orange-800 rounded-full dark:bg-orange-500/10 dark:text-orange-500">
|
|
<span class="py-1 px-2 inline-flex items-center gap-x-1 text-xs font-medium bg-orange-100 text-orange-800 rounded-full dark:bg-orange-500/10 dark:text-orange-500">
|
|
|
Directeur
|
|
Directeur
|
|
|
</span>
|
|
</span>
|
|
|
- </div>
|
|
|
|
|
</td>
|
|
</td>
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <input type="checkbox" class="shrink-0 mt-0.5 border-gray-200 rounded text-blue-600 focus:ring-blue-500 dark:bg-neutral-800 dark:border-neutral-700 dark:checked:bg-blue-500 dark:checked:border-blue-500 dark:focus:ring-offset-gray-800">
|
|
|
|
|
- </div>
|
|
|
|
|
- </td>
|
|
|
|
|
-
|
|
|
|
|
- <td class="size-px whitespace-nowrap">
|
|
|
|
|
- <div class="px-6 py-3">
|
|
|
|
|
- <div class="flex items-center gap-x-2">
|
|
|
|
|
- <button type="button" class="hs-tooltip-toggle inline-flex items-center justify-center size-7 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700" title="Modifier">
|
|
|
|
|
- <svg class="size-4 text-gray-600 dark:text-neutral-400" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
- <path d="M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7"/>
|
|
|
|
|
- <path d="M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z"/>
|
|
|
|
|
- </svg>
|
|
|
|
|
- </button>
|
|
|
|
|
- <button type="button" class="hs-tooltip-toggle inline-flex items-center justify-center size-7 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700" title="Supprimer">
|
|
|
|
|
- <svg class="size-4 text-gray-600 dark:text-neutral-400" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
|
|
+ <td class="px-6 py-4 whitespace-nowrap text-end">
|
|
|
|
|
+ <button type="button" class="inline-flex items-center gap-x-2 text-sm font-medium text-red-600 hover:text-red-800 dark:text-red-400 dark:hover:text-red-300" title="Retirer l'accès">
|
|
|
|
|
+ <svg class="size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
<path d="M3 6h18"/>
|
|
<path d="M3 6h18"/>
|
|
|
<path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/>
|
|
<path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/>
|
|
|
<path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>
|
|
<path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>
|
|
|
|
|
+ <line x1="10" x2="10" y1="11" y2="17"/>
|
|
|
|
|
+ <line x1="14" x2="14" y1="11" y2="17"/>
|
|
|
</svg>
|
|
</svg>
|
|
|
|
|
+ Retirer
|
|
|
</button>
|
|
</button>
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
</td>
|
|
</td>
|
|
|
</tr>
|
|
</tr>
|
|
|
</tbody>
|
|
</tbody>
|
|
|
</table>
|
|
</table>
|
|
|
<!-- End Table -->
|
|
<!-- End Table -->
|
|
|
-
|
|
|
|
|
- <!-- Add User Button -->
|
|
|
|
|
- <div class="px-6 py-4 border-t border-gray-200 dark:border-neutral-700">
|
|
|
|
|
- <div class="flex justify-center">
|
|
|
|
|
- <button type="button" id="btn-add-user" class="py-2 px-4 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg border border-transparent bg-blue-600 text-white hover:bg-blue-700 focus:outline-hidden focus:bg-blue-700 disabled:opacity-50 disabled:pointer-events-none dark:focus:outline-hidden dark:focus:ring-1 dark:focus:ring-neutral-700" data-hs-overlay="#modal-ajouter-utilisateur">
|
|
|
|
|
- <span id="btn-add-user-text">Ajouter un utilisateur [[auto 33]]</span>
|
|
|
|
|
- </button>
|
|
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
- <!-- End Add User Button -->
|
|
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+ <!-- End Tab 2: Attribution des droits -->
|
|
|
</div>
|
|
</div>
|
|
|
- <!-- End Table Section -->
|
|
|
|
|
|
|
+ <!-- End Tab Contents -->
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
<!-- End Content -->
|
|
<!-- End Content -->
|
|
@@ -366,7 +405,7 @@
|
|
|
<!-- Header -->
|
|
<!-- Header -->
|
|
|
<div class="flex justify-between items-center py-4 px-6 border-b border-gray-200 dark:border-neutral-700">
|
|
<div class="flex justify-between items-center py-4 px-6 border-b border-gray-200 dark:border-neutral-700">
|
|
|
<h3 class="text-xl font-semibold text-gray-800 dark:text-white">
|
|
<h3 class="text-xl font-semibold text-gray-800 dark:text-white">
|
|
|
- Ajouter un utilisateur
|
|
|
|
|
|
|
+ Nouvel utilisateur
|
|
|
</h3>
|
|
</h3>
|
|
|
<button type="button" class="flex justify-center items-center size-8 text-sm font-semibold rounded-lg border border-transparent text-gray-500 hover:bg-gray-100 hover:text-gray-800 disabled:opacity-50 disabled:pointer-events-none dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-white transition-colors" data-hs-overlay="#modal-ajouter-utilisateur">
|
|
<button type="button" class="flex justify-center items-center size-8 text-sm font-semibold rounded-lg border border-transparent text-gray-500 hover:bg-gray-100 hover:text-gray-800 disabled:opacity-50 disabled:pointer-events-none dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-white transition-colors" data-hs-overlay="#modal-ajouter-utilisateur">
|
|
|
<span class="sr-only">Fermer</span>
|
|
<span class="sr-only">Fermer</span>
|
|
@@ -382,43 +421,124 @@
|
|
|
<div class="p-6 overflow-y-auto max-h-[calc(100vh-200px)]">
|
|
<div class="p-6 overflow-y-auto max-h-[calc(100vh-200px)]">
|
|
|
<form class="space-y-5">
|
|
<form class="space-y-5">
|
|
|
<div>
|
|
<div>
|
|
|
- <label for="collaborateur" class="block text-sm font-medium text-gray-700 dark:text-neutral-300 mb-2">
|
|
|
|
|
- Collaborateur
|
|
|
|
|
|
|
+ <label for="nom" class="block text-sm font-medium text-gray-700 dark:text-neutral-300 mb-2">
|
|
|
|
|
+ Nom complet
|
|
|
</label>
|
|
</label>
|
|
|
<input
|
|
<input
|
|
|
type="text"
|
|
type="text"
|
|
|
- id="collaborateur"
|
|
|
|
|
- name="collaborateur"
|
|
|
|
|
|
|
+ id="nom"
|
|
|
|
|
+ name="nom"
|
|
|
class="py-2.5 px-4 block w-full border-gray-200 rounded-lg text-sm focus:border-blue-500 focus:ring-blue-500 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-400 dark:placeholder-neutral-500 dark:focus:ring-neutral-600 transition-colors"
|
|
class="py-2.5 px-4 block w-full border-gray-200 rounded-lg text-sm focus:border-blue-500 focus:ring-blue-500 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-400 dark:placeholder-neutral-500 dark:focus:ring-neutral-600 transition-colors"
|
|
|
- placeholder="Rechercher un collaborateur..."
|
|
|
|
|
|
|
+ placeholder="Jean Dupont"
|
|
|
|
|
+ required
|
|
|
>
|
|
>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
<div>
|
|
<div>
|
|
|
- <label for="site" class="block text-sm font-medium text-gray-700 dark:text-neutral-300 mb-2">
|
|
|
|
|
- Site
|
|
|
|
|
|
|
+ <label for="email" class="block text-sm font-medium text-gray-700 dark:text-neutral-300 mb-2">
|
|
|
|
|
+ Adresse email
|
|
|
|
|
+ </label>
|
|
|
|
|
+ <input
|
|
|
|
|
+ type="email"
|
|
|
|
|
+ id="email"
|
|
|
|
|
+ name="email"
|
|
|
|
|
+ class="py-2.5 px-4 block w-full border-gray-200 rounded-lg text-sm focus:border-blue-500 focus:ring-blue-500 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-400 dark:placeholder-neutral-500 dark:focus:ring-neutral-600 transition-colors"
|
|
|
|
|
+ placeholder="jean.dupont@example.com"
|
|
|
|
|
+ required
|
|
|
|
|
+ >
|
|
|
|
|
+ </div>
|
|
|
|
|
+
|
|
|
|
|
+ <div>
|
|
|
|
|
+ <label for="password" class="block text-sm font-medium text-gray-700 dark:text-neutral-300 mb-2">
|
|
|
|
|
+ Mot de passe temporaire
|
|
|
|
|
+ </label>
|
|
|
|
|
+ <input
|
|
|
|
|
+ type="password"
|
|
|
|
|
+ id="password"
|
|
|
|
|
+ name="password"
|
|
|
|
|
+ class="py-2.5 px-4 block w-full border-gray-200 rounded-lg text-sm focus:border-blue-500 focus:ring-blue-500 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-400 dark:placeholder-neutral-500 dark:focus:ring-neutral-600 transition-colors"
|
|
|
|
|
+ placeholder="••••••••"
|
|
|
|
|
+ required
|
|
|
|
|
+ >
|
|
|
|
|
+ <p class="mt-1 text-xs text-gray-500 dark:text-neutral-400">
|
|
|
|
|
+ L'utilisateur devra changer son mot de passe à la première connexion
|
|
|
|
|
+ </p>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </form>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <!-- End Body -->
|
|
|
|
|
+
|
|
|
|
|
+ <!-- Footer -->
|
|
|
|
|
+ <div class="flex justify-end items-center gap-x-3 py-4 px-6 border-t border-gray-200 dark:border-neutral-700 bg-gray-50 dark:bg-neutral-900/50">
|
|
|
|
|
+ <button
|
|
|
|
|
+ type="button"
|
|
|
|
|
+ class="py-2.5 px-4 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 shadow-sm hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700 transition-colors"
|
|
|
|
|
+ data-hs-overlay="#modal-ajouter-utilisateur"
|
|
|
|
|
+ >
|
|
|
|
|
+ Annuler
|
|
|
|
|
+ </button>
|
|
|
|
|
+ <button
|
|
|
|
|
+ type="button"
|
|
|
|
|
+ class="py-2.5 px-4 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg border border-transparent bg-blue-600 text-white hover:bg-blue-700 focus:outline-none focus:bg-blue-700 disabled:opacity-50 disabled:pointer-events-none transition-colors"
|
|
|
|
|
+ >
|
|
|
|
|
+ Créer l'utilisateur
|
|
|
|
|
+ </button>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <!-- End Footer -->
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <!-- End Modal Ajouter Utilisateur -->
|
|
|
|
|
+
|
|
|
|
|
+ <!-- Modal Ajouter Droit -->
|
|
|
|
|
+ <div id="modal-ajouter-droit" class="hs-overlay hidden size-full fixed top-0 start-0 z-[80] overflow-x-hidden overflow-y-auto pointer-events-none">
|
|
|
|
|
+ <div class="hs-overlay-open:mt-7 hs-overlay-open:opacity-100 hs-overlay-open:duration-500 mt-0 opacity-0 ease-out transition-all sm:max-w-lg sm:w-full m-3 sm:mx-auto min-h-[calc(100%-3.5rem)] flex items-center">
|
|
|
|
|
+ <div class="w-full flex flex-col bg-white border shadow-sm rounded-xl pointer-events-auto dark:bg-neutral-800 dark:border-neutral-700 dark:shadow-neutral-700/70">
|
|
|
|
|
+ <!-- Header -->
|
|
|
|
|
+ <div class="flex justify-between items-center py-4 px-6 border-b border-gray-200 dark:border-neutral-700">
|
|
|
|
|
+ <h3 class="text-xl font-semibold text-gray-800 dark:text-white">
|
|
|
|
|
+ Ajouter un accès
|
|
|
|
|
+ </h3>
|
|
|
|
|
+ <button type="button" class="flex justify-center items-center size-8 text-sm font-semibold rounded-lg border border-transparent text-gray-500 hover:bg-gray-100 hover:text-gray-800 disabled:opacity-50 disabled:pointer-events-none dark:text-neutral-400 dark:hover:bg-neutral-700 dark:hover:text-white transition-colors" data-hs-overlay="#modal-ajouter-droit">
|
|
|
|
|
+ <span class="sr-only">Fermer</span>
|
|
|
|
|
+ <svg class="flex-shrink-0 size-4" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
+ <path d="m18 6-12 12"/>
|
|
|
|
|
+ <path d="m6 6 12 12"/>
|
|
|
|
|
+ </svg>
|
|
|
|
|
+ </button>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <!-- End Header -->
|
|
|
|
|
+
|
|
|
|
|
+ <!-- Body -->
|
|
|
|
|
+ <div class="p-6 overflow-y-auto max-h-[calc(100vh-200px)]">
|
|
|
|
|
+ <form class="space-y-5">
|
|
|
|
|
+ <div>
|
|
|
|
|
+ <label for="utilisateur-droit" class="block text-sm font-medium text-gray-700 dark:text-neutral-300 mb-2">
|
|
|
|
|
+ Utilisateur
|
|
|
</label>
|
|
</label>
|
|
|
<select
|
|
<select
|
|
|
- id="site"
|
|
|
|
|
- name="site"
|
|
|
|
|
|
|
+ id="utilisateur-droit"
|
|
|
|
|
+ name="utilisateur-droit"
|
|
|
class="py-2.5 px-4 block w-full border-gray-200 rounded-lg text-sm focus:border-blue-500 focus:ring-blue-500 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-400 dark:focus:ring-neutral-600 transition-colors"
|
|
class="py-2.5 px-4 block w-full border-gray-200 rounded-lg text-sm focus:border-blue-500 focus:ring-blue-500 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-400 dark:focus:ring-neutral-600 transition-colors"
|
|
|
|
|
+ required
|
|
|
>
|
|
>
|
|
|
- <option value="auto33">Auto 33</option>
|
|
|
|
|
- <option value="admin-rh">Admin RH</option>
|
|
|
|
|
- <option value="admin-it">Admin IT</option>
|
|
|
|
|
- <option value="dashboard-it">Dashboard IT</option>
|
|
|
|
|
- <option value="dashboard-rh">Dashboard RH</option>
|
|
|
|
|
|
|
+ <option value="">Sélectionner un utilisateur</option>
|
|
|
|
|
+ <option value="jean-dupont">Jean Dupont</option>
|
|
|
|
|
+ <option value="marie-martin">Marie Martin</option>
|
|
|
|
|
+ <option value="pierre-durand">Pierre Durand</option>
|
|
|
|
|
+ <option value="sophie-bernard">Sophie Bernard</option>
|
|
|
</select>
|
|
</select>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
<div>
|
|
<div>
|
|
|
- <label for="role" class="block text-sm font-medium text-gray-700 dark:text-neutral-300 mb-2">
|
|
|
|
|
- Rôle / Groupes utilisateurs
|
|
|
|
|
|
|
+ <label for="role-droit" class="block text-sm font-medium text-gray-700 dark:text-neutral-300 mb-2">
|
|
|
|
|
+ Rôle / Groupe
|
|
|
</label>
|
|
</label>
|
|
|
<select
|
|
<select
|
|
|
- id="role"
|
|
|
|
|
- name="role"
|
|
|
|
|
|
|
+ id="role-droit"
|
|
|
|
|
+ name="role-droit"
|
|
|
class="py-2.5 px-4 block w-full border-gray-200 rounded-lg text-sm focus:border-blue-500 focus:ring-blue-500 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-400 dark:focus:ring-neutral-600 transition-colors"
|
|
class="py-2.5 px-4 block w-full border-gray-200 rounded-lg text-sm focus:border-blue-500 focus:ring-blue-500 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-400 dark:focus:ring-neutral-600 transition-colors"
|
|
|
|
|
+ required
|
|
|
>
|
|
>
|
|
|
<option value="">Sélectionner un rôle</option>
|
|
<option value="">Sélectionner un rôle</option>
|
|
|
<option value="comptable">Comptable</option>
|
|
<option value="comptable">Comptable</option>
|
|
@@ -428,21 +548,19 @@
|
|
|
</select>
|
|
</select>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
- <div class="pt-2">
|
|
|
|
|
- <label class="flex items-center gap-3 cursor-pointer">
|
|
|
|
|
- <input
|
|
|
|
|
- type="checkbox"
|
|
|
|
|
- id="notification-mails"
|
|
|
|
|
- name="notification-mails"
|
|
|
|
|
- class="shrink-0 size-4 border-gray-200 rounded text-blue-600 focus:ring-2 focus:ring-blue-500 focus:ring-offset-0 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:checked:bg-blue-500 dark:checked:border-blue-500 dark:focus:ring-offset-gray-800 transition-colors"
|
|
|
|
|
- >
|
|
|
|
|
- <span class="text-sm text-gray-700 dark:text-neutral-300 font-medium">
|
|
|
|
|
- Notification mails
|
|
|
|
|
- </span>
|
|
|
|
|
- </label>
|
|
|
|
|
- <p class="mt-1 text-xs text-gray-500 dark:text-neutral-400 ms-7">
|
|
|
|
|
- L'utilisateur recevra des notifications par email
|
|
|
|
|
- </p>
|
|
|
|
|
|
|
+ <div class="bg-blue-50 dark:bg-blue-900/20 rounded-lg p-4">
|
|
|
|
|
+ <div class="flex gap-x-3">
|
|
|
|
|
+ <svg class="flex-shrink-0 size-5 text-blue-600 dark:text-blue-400" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
|
|
|
+ <circle cx="12" cy="12" r="10"/>
|
|
|
|
|
+ <path d="M12 16v-4"/>
|
|
|
|
|
+ <path d="M12 8h.01"/>
|
|
|
|
|
+ </svg>
|
|
|
|
|
+ <div class="flex-1">
|
|
|
|
|
+ <p class="text-sm text-blue-800 dark:text-blue-400">
|
|
|
|
|
+ Cet accès sera ajouté au site actuellement sélectionné : <strong id="modal-site-name">Auto 33</strong>
|
|
|
|
|
+ </p>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
</div>
|
|
</div>
|
|
|
</form>
|
|
</form>
|
|
|
</div>
|
|
</div>
|
|
@@ -453,181 +571,58 @@
|
|
|
<button
|
|
<button
|
|
|
type="button"
|
|
type="button"
|
|
|
class="py-2.5 px-4 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 shadow-sm hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700 transition-colors"
|
|
class="py-2.5 px-4 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg border border-gray-200 bg-white text-gray-800 shadow-sm hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700 transition-colors"
|
|
|
- data-hs-overlay="#modal-ajouter-utilisateur"
|
|
|
|
|
|
|
+ data-hs-overlay="#modal-ajouter-droit"
|
|
|
>
|
|
>
|
|
|
Annuler
|
|
Annuler
|
|
|
</button>
|
|
</button>
|
|
|
<button
|
|
<button
|
|
|
type="button"
|
|
type="button"
|
|
|
- class="py-2.5 px-4 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg border border-transparent bg-blue-600 text-white hover:bg-blue-700 focus:outline-hidden focus:bg-blue-700 disabled:opacity-50 disabled:pointer-events-none dark:focus:outline-hidden dark:focus:ring-1 dark:focus:ring-neutral-700 transition-colors"
|
|
|
|
|
|
|
+ class="py-2.5 px-4 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg border border-transparent bg-blue-600 text-white hover:bg-blue-700 focus:outline-none focus:bg-blue-700 disabled:opacity-50 disabled:pointer-events-none transition-colors"
|
|
|
>
|
|
>
|
|
|
- Ajouter
|
|
|
|
|
|
|
+ Ajouter l'accès
|
|
|
</button>
|
|
</button>
|
|
|
</div>
|
|
</div>
|
|
|
<!-- End Footer -->
|
|
<!-- End Footer -->
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
- <!-- End Modal Ajouter Utilisateur -->
|
|
|
|
|
|
|
+ <!-- End Modal Ajouter Droit -->
|
|
|
|
|
|
|
|
<!-- Preline UI - Chargé à la fin du body pour une initialisation correcte -->
|
|
<!-- Preline UI - Chargé à la fin du body pour une initialisation correcte -->
|
|
|
<script src="https://cdn.jsdelivr.net/npm/preline@2.1.0/dist/preline.js"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/preline@2.1.0/dist/preline.js"></script>
|
|
|
|
|
|
|
|
- <!-- Script pour le dropdown de notifications -->
|
|
|
|
|
|
|
+ <!-- Script principal -->
|
|
|
<script>
|
|
<script>
|
|
|
- // Gérer le dropdown de notifications
|
|
|
|
|
document.addEventListener('DOMContentLoaded', function() {
|
|
document.addEventListener('DOMContentLoaded', function() {
|
|
|
- const notificationButton = document.getElementById('hs-notification-dropdown');
|
|
|
|
|
- const notificationMenu = document.getElementById('notification-dropdown-menu');
|
|
|
|
|
-
|
|
|
|
|
- if (notificationButton && notificationMenu) {
|
|
|
|
|
- function updateDropdownPosition() {
|
|
|
|
|
- const buttonRect = notificationButton.getBoundingClientRect();
|
|
|
|
|
- notificationMenu.style.top = (buttonRect.bottom + 8) + 'px';
|
|
|
|
|
- notificationMenu.style.right = (window.innerWidth - buttonRect.right) + 'px';
|
|
|
|
|
- notificationMenu.style.maxWidth = '400px';
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- notificationButton.addEventListener('click', function(e) {
|
|
|
|
|
- e.stopPropagation();
|
|
|
|
|
- const isExpanded = notificationButton.getAttribute('aria-expanded') === 'true';
|
|
|
|
|
- const newExpanded = !isExpanded;
|
|
|
|
|
-
|
|
|
|
|
- notificationButton.setAttribute('aria-expanded', newExpanded);
|
|
|
|
|
-
|
|
|
|
|
- if (newExpanded) {
|
|
|
|
|
- updateDropdownPosition();
|
|
|
|
|
- notificationMenu.classList.remove('opacity-0', 'invisible', 'translate-y-2');
|
|
|
|
|
- notificationMenu.classList.add('opacity-100', 'visible', 'translate-y-0');
|
|
|
|
|
- } else {
|
|
|
|
|
- notificationMenu.classList.remove('opacity-100', 'visible', 'translate-y-0');
|
|
|
|
|
- notificationMenu.classList.add('opacity-0', 'invisible', 'translate-y-2');
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
-
|
|
|
|
|
- document.addEventListener('click', function(e) {
|
|
|
|
|
- if (!notificationButton.contains(e.target) && !notificationMenu.contains(e.target)) {
|
|
|
|
|
- notificationMenu.classList.remove('opacity-100', 'visible', 'translate-y-0');
|
|
|
|
|
- notificationMenu.classList.add('opacity-0', 'invisible', 'translate-y-2');
|
|
|
|
|
- notificationButton.setAttribute('aria-expanded', 'false');
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
-
|
|
|
|
|
- window.addEventListener('resize', function() {
|
|
|
|
|
- if (notificationButton.getAttribute('aria-expanded') === 'true') {
|
|
|
|
|
- updateDropdownPosition();
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
- </script>
|
|
|
|
|
-
|
|
|
|
|
- <!-- Script pour gérer le changement de site dans le dropdown et la modal -->
|
|
|
|
|
- <script>
|
|
|
|
|
- document.addEventListener('DOMContentLoaded', function() {
|
|
|
|
|
- // Fonctions de gestion de la modal
|
|
|
|
|
- const modal = document.getElementById('modal-ajouter-utilisateur');
|
|
|
|
|
- const modalButton = document.getElementById('btn-add-user');
|
|
|
|
|
- const modalInner = modal ? modal.querySelector('div[class*="hs-overlay-open"]') : null;
|
|
|
|
|
-
|
|
|
|
|
- function openModal() {
|
|
|
|
|
- if (modal && modalInner) {
|
|
|
|
|
- modal.classList.remove('hidden');
|
|
|
|
|
- document.body.style.overflow = 'hidden';
|
|
|
|
|
- // Forcer les classes d'animation
|
|
|
|
|
- setTimeout(() => {
|
|
|
|
|
- modalInner.classList.add('mt-7', 'opacity-100');
|
|
|
|
|
- }, 10);
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- function closeModal() {
|
|
|
|
|
- if (modal && modalInner) {
|
|
|
|
|
- modalInner.classList.remove('mt-7', 'opacity-100');
|
|
|
|
|
- setTimeout(() => {
|
|
|
|
|
- modal.classList.add('hidden');
|
|
|
|
|
- document.body.style.overflow = '';
|
|
|
|
|
- }, 300);
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- // Ouvrir la modal au clic sur le bouton
|
|
|
|
|
- if (modalButton) {
|
|
|
|
|
- modalButton.addEventListener('click', function(e) {
|
|
|
|
|
- e.preventDefault();
|
|
|
|
|
- e.stopPropagation();
|
|
|
|
|
- openModal();
|
|
|
|
|
- });
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- // Fermer la modal avec les boutons de fermeture
|
|
|
|
|
- const closeButtons = modal ? modal.querySelectorAll('[data-hs-overlay="#modal-ajouter-utilisateur"]') : [];
|
|
|
|
|
- closeButtons.forEach(btn => {
|
|
|
|
|
- if (btn.id !== 'btn-add-user') { // Ne pas ajouter l'écouteur au bouton d'ouverture
|
|
|
|
|
- btn.addEventListener('click', function(e) {
|
|
|
|
|
- e.preventDefault();
|
|
|
|
|
- closeModal();
|
|
|
|
|
- });
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
-
|
|
|
|
|
- // Fermer la modal en cliquant à l'extérieur
|
|
|
|
|
- if (modal) {
|
|
|
|
|
- modal.addEventListener('click', function(e) {
|
|
|
|
|
- if (e.target === modal) {
|
|
|
|
|
- closeModal();
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- // Fermer avec la touche Échap
|
|
|
|
|
- document.addEventListener('keydown', function(e) {
|
|
|
|
|
- if (e.key === 'Escape' && modal && !modal.classList.contains('hidden')) {
|
|
|
|
|
- closeModal();
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
-
|
|
|
|
|
- // Attendre que Preline soit chargé pour le dropdown
|
|
|
|
|
|
|
+ // Gérer le changement de site dans le dropdown (onglet droits)
|
|
|
setTimeout(function() {
|
|
setTimeout(function() {
|
|
|
- // Gérer le changement de site dans le dropdown
|
|
|
|
|
const dropdownButton = document.getElementById('hs-dropdown-access');
|
|
const dropdownButton = document.getElementById('hs-dropdown-access');
|
|
|
const dropdownContainer = dropdownButton?.closest('.hs-dropdown');
|
|
const dropdownContainer = dropdownButton?.closest('.hs-dropdown');
|
|
|
const dropdownMenu = dropdownContainer?.querySelector('.hs-dropdown-menu');
|
|
const dropdownMenu = dropdownContainer?.querySelector('.hs-dropdown-menu');
|
|
|
const dropdownItems = dropdownMenu?.querySelectorAll('a');
|
|
const dropdownItems = dropdownMenu?.querySelectorAll('a');
|
|
|
const selectedSiteSpan = document.getElementById('selected-site');
|
|
const selectedSiteSpan = document.getElementById('selected-site');
|
|
|
- const addButtonText = document.getElementById('btn-add-user-text');
|
|
|
|
|
|
|
+ const siteTitle = document.getElementById('site-title');
|
|
|
|
|
+ const modalSiteName = document.getElementById('modal-site-name');
|
|
|
|
|
|
|
|
// Valeur par défaut
|
|
// Valeur par défaut
|
|
|
- let selectedSite = 'auto 33';
|
|
|
|
|
|
|
+ let selectedSite = 'Auto 33';
|
|
|
|
|
|
|
|
if (dropdownItems && dropdownItems.length > 0) {
|
|
if (dropdownItems && dropdownItems.length > 0) {
|
|
|
dropdownItems.forEach(item => {
|
|
dropdownItems.forEach(item => {
|
|
|
item.addEventListener('click', function(e) {
|
|
item.addEventListener('click', function(e) {
|
|
|
e.preventDefault();
|
|
e.preventDefault();
|
|
|
const selectedText = this.textContent.trim();
|
|
const selectedText = this.textContent.trim();
|
|
|
- selectedSite = selectedText.toLowerCase();
|
|
|
|
|
|
|
+ selectedSite = selectedText;
|
|
|
|
|
|
|
|
- // Mettre à jour le texte du bouton dropdown
|
|
|
|
|
|
|
+ // Mettre à jour tous les textes
|
|
|
if (selectedSiteSpan) {
|
|
if (selectedSiteSpan) {
|
|
|
selectedSiteSpan.textContent = selectedText;
|
|
selectedSiteSpan.textContent = selectedText;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
- // Mettre à jour le texte du bouton "Ajouter un utilisateur"
|
|
|
|
|
- if (addButtonText) {
|
|
|
|
|
- addButtonText.textContent = `Ajouter un utilisateur [[${selectedText}]]`;
|
|
|
|
|
|
|
+ if (siteTitle) {
|
|
|
|
|
+ siteTitle.textContent = selectedText;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
- // Mettre à jour le select dans la modal
|
|
|
|
|
- const siteSelect = document.getElementById('site');
|
|
|
|
|
- if (siteSelect) {
|
|
|
|
|
- const optionMap = {
|
|
|
|
|
- 'admin rh': 'admin-rh',
|
|
|
|
|
- 'admin it': 'admin-it',
|
|
|
|
|
- 'dashboard it': 'dashboard-it',
|
|
|
|
|
- 'dashboard rh': 'dashboard-rh',
|
|
|
|
|
- 'auto 33': 'auto33'
|
|
|
|
|
- };
|
|
|
|
|
- siteSelect.value = optionMap[selectedSite] || 'auto33';
|
|
|
|
|
|
|
+ if (modalSiteName) {
|
|
|
|
|
+ modalSiteName.textContent = selectedText;
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
});
|
|
});
|