mirror of
https://github.com/R0m1k3/LogiFlow.git
synced 2026-10-20 05:28:22 +02:00
Reorganize navigation by moving suppliers and stores to administration
Refactors the sidebar navigation by moving "Fournisseurs" and "Magasins" to the "Administration" category and removing the "Gestion" category. Replit-Commit-Author: Agent Replit-Commit-Session-Id: 7c468936-2a88-4686-ac0a-84921a45222d Replit-Commit-Checkpoint-Type: full_checkpoint Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/1957c339-2757-4d1f-8e92-e9f71a1ce58e/7c468936-2a88-4686-ac0a-84921a45222d/St2dwA2
This commit is contained in:
1 parent
f42379b330
commit
eaf2de6960
2 files changed
+21
-47
No files matched your search
@@ -125,7 +125,13 @@ export default function Sidebar() {
|
|||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
const managementItems = [
|
const adminItems = [
|
||||||
|
{
|
||||||
|
path: "/users",
|
||||||
|
label: "Utilisateurs",
|
||||||
|
icon: UserCog,
|
||||||
|
roles: ["admin"]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
path: "/suppliers",
|
path: "/suppliers",
|
||||||
label: "Fournisseurs",
|
label: "Fournisseurs",
|
||||||
@@ -138,15 +144,6 @@ export default function Sidebar() {
|
|||||||
icon: Users,
|
icon: Users,
|
||||||
roles: ["admin"]
|
roles: ["admin"]
|
||||||
},
|
},
|
||||||
];
|
|
||||||
|
|
||||||
const adminItems = [
|
|
||||||
{
|
|
||||||
path: "/users",
|
|
||||||
label: "Utilisateurs",
|
|
||||||
icon: UserCog,
|
|
||||||
roles: ["admin"]
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
path: "/utilities",
|
path: "/utilities",
|
||||||
label: "Utilitaires",
|
label: "Utilitaires",
|
||||||
@@ -377,44 +374,7 @@ export default function Sidebar() {
|
|||||||
})}
|
})}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* Management Section */}
|
|
||||||
{managementItems.some(item => hasPermission(item.roles)) && (
|
|
||||||
<>
|
|
||||||
{!sidebarCollapsed && (
|
|
||||||
<div className="mt-6 mb-2">
|
|
||||||
<h3 className="px-3 text-xs font-medium text-gray-500 uppercase tracking-wider">
|
|
||||||
Gestion
|
|
||||||
</h3>
|
|
||||||
</div>
|
|
||||||
)}
|
|
||||||
{sidebarCollapsed && <div className="mt-4 mb-2 border-t border-gray-200"></div>}
|
|
||||||
<div className="space-y-1">
|
|
||||||
{managementItems.map((item) => {
|
|
||||||
if (!hasPermission(item.roles)) return null;
|
|
||||||
|
|
||||||
const Icon = item.icon;
|
|
||||||
const active = isActive(item.path);
|
|
||||||
|
|
||||||
return (
|
|
||||||
<Link key={item.path} href={item.path}>
|
|
||||||
<div
|
|
||||||
className={`flex items-center ${sidebarCollapsed ? 'px-3 py-3 justify-center' : 'px-3 py-2'} text-sm font-medium transition-colors hover:bg-gray-100 ${
|
|
||||||
active
|
|
||||||
? 'bg-gray-100 text-gray-900 border-r-2 border-gray-700'
|
|
||||||
: 'text-gray-700'
|
|
||||||
}`}
|
|
||||||
title={sidebarCollapsed ? item.label : undefined}
|
|
||||||
onClick={() => console.log(`Navigating to management: ${item.path}`)}
|
|
||||||
>
|
|
||||||
<Icon className={`h-4 w-4 ${sidebarCollapsed ? '' : 'mr-3'}`} />
|
|
||||||
{!sidebarCollapsed && item.label}
|
|
||||||
</div>
|
|
||||||
</Link>
|
|
||||||
);
|
|
||||||
})}
|
|
||||||
</div>
|
|
||||||
</>
|
|
||||||
)}
|
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
{/* Administration Section */}
|
{/* Administration Section */}
|
||||||
|
|||||||
@@ -19,6 +19,20 @@ La plateforme fournit une gestion robuste des flux de travail de livraison avec
|
|||||||
|
|
||||||
## Recent Changes
|
## Recent Changes
|
||||||
|
|
||||||
|
### 2025-08-13 - Interface épurée + redirection automatique + réorganisation navigation
|
||||||
|
✅ **Redirection automatique vers authentification** :
|
||||||
|
- RouterProduction redirige immédiatement si utilisateur non connecté
|
||||||
|
- Query client gère les erreurs 401 avec redirection automatique
|
||||||
|
- Gestion centralisée des sessions expirées pour meilleure UX
|
||||||
|
- Plus de pages d'erreur, redirection transparente vers /auth
|
||||||
|
|
||||||
|
✅ **Interface épurée et navigation optimisée** :
|
||||||
|
- Titre LogiFlow supprimé du header principal (évite redondance)
|
||||||
|
- Seul titre dans la sidebar conservé pour navigation centralisée
|
||||||
|
- Fournisseurs et Magasins déplacés dans Administration
|
||||||
|
- Catégorie "Gestion" supprimée (consolidation menu)
|
||||||
|
- Interface plus propre et logique
|
||||||
|
|
||||||
### 2025-08-13 - Module de sauvegarde PostgreSQL implémenté + correction ESM
|
### 2025-08-13 - Module de sauvegarde PostgreSQL implémenté + correction ESM
|
||||||
✅ **Module de sauvegarde PostgreSQL complet** :
|
✅ **Module de sauvegarde PostgreSQL complet** :
|
||||||
- **Interface BackupManager** : Affichage des sauvegardes avec détails (taille, tables, statut)
|
- **Interface BackupManager** : Affichage des sauvegardes avec détails (taille, tables, statut)
|
||||||
|
|||||||
Reference in new issue
Block a user