Spaces:
Running

rh-manager / index.html
dSteve01's picture
développez les fonctionnalités suivantes : "Pointage" ,"Congés", " Équipe" "Rapports" , "Pointer maintenant", "Ajouter une tâche", "Demander un congé", "Créer un rapport" et "Paramètres" - Follow Up Deployment
0257344 verified
Raw History Blame Contribute Delete
21.2 kB
<!DOCTYPE html>
<html lang="fr">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Tableau de bord RH</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<style>
.sidebar {
transition: all 0.3s ease;
}
.sidebar.collapsed {
width: 70px;
}
.sidebar.collapsed .menu-text {
display: none;
}
.sidebar.collapsed .logo-text {
display: none;
}
.main-content {
transition: margin-left 0.3s ease;
}
.card-hover:hover {
transform: translateY(-5px);
box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}
@media (max-width: 768px) {
.sidebar {
width: 70px;
}
.sidebar .menu-text {
display: none;
}
.sidebar .logo-text {
display: none;
}
.main-content {
margin-left: 70px;
}
}
</style>
</head>
<body class="bg-gray-100">
<div class="flex h-screen">
<!-- Sidebar -->
<div class="sidebar bg-blue-800 text-white w-64 flex flex-col fixed h-full">
<div class="p-4 flex items-center">
<i class="fas fa-user-clock text-2xl mr-3"></i>
<span class="logo-text text-xl font-bold">RH Manager</span>
</div>
<div class="flex-grow mt-6">
<nav>
<a href="#" onclick="alert('Fonctionnalité Tableau de bord en cours de développement')" class="block py-3 px-6 hover:bg-blue-700 flex items-center">
<i class="fas fa-home mr-3"></i>
<span class="menu-text">Tableau de bord</span>
</a>
<a href="/pointage" class="block py-3 px-6 bg-blue-700 flex items-center">
<i class="fas fa-fingerprint mr-3"></i>
<span class="menu-text">Pointage</span>
</a>
<a href="/conges" class="block py-3 px-6 hover:bg-blue-700 flex items-center">
<i class="fas fa-umbrella-beach mr-3"></i>
<span class="menu-text">Congés</span>
</a>
<a href="/equipe" class="block py-3 px-6 hover:bg-blue-700 flex items-center">
<i class="fas fa-users mr-3"></i>
<span class="menu-text">Équipe</span>
</a>
<a href="/rapports" class="block py-3 px-6 hover:bg-blue-700 flex items-center">
<i class="fas fa-chart-bar mr-3"></i>
<span class="menu-text">Rapports</span>
</a>
<a href="/parametres" class="block py-3 px-6 hover:bg-blue-700 flex items-center">
<i class="fas fa-cog mr-3"></i>
<span class="menu-text">Paramètres</span>
</a>
</nav>
</div>
<div class="p-4 border-t border-blue-700">
<div class="flex items-center">
<img src="https://randomuser.me/api/portraits/women/44.jpg" alt="Profile" class="w-10 h-10 rounded-full mr-3">
<div class="menu-text">
<div class="font-medium">Marie Dupont</div>
<div class="text-sm text-blue-200">Administrateur</div>
</div>
</div>
</div>
</div>
<!-- Main Content -->
<div class="main-content flex-grow ml-64 p-6">
<div class="flex justify-between items-center mb-8">
<h1 class="text-2xl font-bold text-gray-800">Pointage</h1>
<div class="flex items-center">
<div class="relative mr-4">
<input type="text" placeholder="Rechercher..." class="pl-10 pr-4 py-2 rounded-lg border border-gray-300 focus:outline-none focus:ring-2 focus:ring-blue-500">
<i class="fas fa-search absolute left-3 top-3 text-gray-400"></i>
</div>
<button class="bg-blue-600 hover:bg-blue-700 text-white px-4 py-2 rounded-lg flex items-center">
<i class="fas fa-bell mr-2"></i>
<span>Notifications</span>
</button>
</div>
</div>
<!-- Quick Actions -->
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6 mb-8">
<a href="/pointer-maintenant" class="bg-white rounded-xl shadow-md p-6 card-hover transition-all duration-300 cursor-pointer">
<div class="flex items-center">
<div class="bg-blue-100 p-3 rounded-full mr-4">
<i class="fas fa-fingerprint text-blue-600 text-xl"></i>
</div>
<div>
<h3 class="font-semibold text-gray-800">Pointer maintenant</h3>
<p class="text-sm text-gray-500">Enregistrez votre heure d'arrivée</p>
</div>
</div>
</a>
<a href="/ajouter-tache" class="bg-white rounded-xl shadow-md p-6 card-hover transition-all duration-300 cursor-pointer">
<div class="flex items-center">
<div class="bg-green-100 p-3 rounded-full mr-4">
<i class="fas fa-tasks text-green-600 text-xl"></i>
</div>
<div>
<h3 class="font-semibold text-gray-800">Ajouter une tâche</h3>
<p class="text-sm text-gray-500">Planifiez vos activités</p>
</div>
</div>
</a>
<a href="/demander-conge" class="bg-white rounded-xl shadow-md p-6 card-hover transition-all duration-300 cursor-pointer">
<div class="flex items-center">
<div class="bg-yellow-100 p-3 rounded-full mr-4">
<i class="fas fa-umbrella-beach text-yellow-600 text-xl"></i>
</div>
<div>
<h3 class="font-semibold text-gray-800">Demander un congé</h3>
<p class="text-sm text-gray-500">Soumettez une demande</p>
</div>
</div>
</a>
<a href="/creer-rapport" class="bg-white rounded-xl shadow-md p-6 card-hover transition-all duration-300 cursor-pointer">
<div class="flex items-center">
<div class="bg-purple-100 p-3 rounded-full mr-4">
<i class="fas fa-file-alt text-purple-600 text-xl"></i>
</div>
<div>
<h3 class="font-semibold text-gray-800">Créer un rapport</h3>
<p class="text-sm text-gray-500">Générez un rapport d'activité</p>
</div>
</div>
</a>
</div>
<!-- Main Content Sections -->
<div class="grid grid-cols-1 lg:grid-cols-3 gap-6">
<!-- Pointage Section -->
<div class="lg:col-span-2 bg-white rounded-xl shadow-md p-6">
<div class="flex justify-between items-center mb-6">
<h2 class="text-xl font-semibold text-gray-800">Historique de pointage</h2>
<div class="flex space-x-2">
<button class="px-3 py-1 bg-gray-100 rounded-lg text-sm">Aujourd'hui</button>
<button class="px-3 py-1 bg-gray-100 rounded-lg text-sm">Semaine</button>
<button class="px-3 py-1 bg-blue-100 text-blue-600 rounded-lg text-sm">Mois</button>
</div>
</div>
<div class="overflow-x-auto">
<table class="min-w-full divide-y divide-gray-200">
<thead class="bg-gray-50">
<tr>
<th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Date</th>
<th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Heure d'arrivée</th>
<th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Heure de départ</th>
<th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">Statut</th>
</tr>
</thead>
<tbody class="bg-white divide-y divide-gray-200">
<tr>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500">Lun, 12 Juin</td>
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-900">08:45</td>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500">17:30</td>
<td class="px-6 py-4 whitespace-nowrap">
<span class="px-2 py-1 text-xs rounded-full bg-green-100 text-green-800">Complet</span>
</td>
</tr>
<tr>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500">Mar, 13 Juin</td>
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-900">09:00</td>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500">17:15</td>
<td class="px-6 py-4 whitespace-nowrap">
<span class="px-2 py-1 text-xs rounded-full bg-green-100 text-green-800">Complet</span>
</td>
</tr>
<tr>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500">Mer, 14 Juin</td>
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-900">08:30</td>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500">-</td>
<td class="px-6 py-4 whitespace-nowrap">
<span class="px-2 py-1 text-xs rounded-full bg-yellow-100 text-yellow-800">En cours</span>
</td>
</tr>
</tbody>
</table>
</div>
<div class="mt-6 flex justify-center">
<a href="/ajouter-pointage" class="px-4 py-2 bg-blue-600 text-white rounded-lg hover:bg-blue-700 flex items-center">
<i class="fas fa-plus mr-2"></i>
Ajouter un pointage manuel
</a>
</div>
</div>
<!-- Stats Section -->
<div class="bg-white rounded-xl shadow-md p-6">
<h2 class="text-xl font-semibold text-gray-800 mb-6">Statistiques</h2>
<div class="space-y-6">
<div>
<div class="flex justify-between mb-2">
<span class="text-sm font-medium text-gray-500">Heures travaillées</span>
<span class="text-sm font-bold text-gray-800">38.5h</span>
</div>
<div class="w-full bg-gray-200 rounded-full h-2.5">
<div class="bg-blue-600 h-2.5 rounded-full" style="width: 85%"></div>
</div>
</div>
<div>
<div class="flex justify-between mb-2">
<span class="text-sm font-medium text-gray-500">Congés restants</span>
<span class="text-sm font-bold text-gray-800">12 jours</span>
</div>
<div class="w-full bg-gray-200 rounded-full h-2.5">
<div class="bg-green-500 h-2.5 rounded-full" style="width: 60%"></div>
</div>
</div>
<div>
<div class="flex justify-between mb-2">
<span class="text-sm font-medium text-gray-500">Retards ce mois</span>
<span class="text-sm font-bold text-gray-800">1</span>
</div>
<div class="w-full bg-gray-200 rounded-full h-2.5">
<div class="bg-red-500 h-2.5 rounded-full" style="width: 10%"></div>
</div>
</div>
</div>
<div class="mt-8">
<h3 class="text-lg font-semibold text-gray-800 mb-4">Prochain congé</h3>
<div class="bg-blue-50 rounded-lg p-4">
<div class="flex items-center">
<div class="bg-blue-100 p-3 rounded-lg mr-4">
<i class="fas fa-umbrella-beach text-blue-600"></i>
</div>
<div>
<h4 class="font-medium text-gray-800">Vacances d'été</h4>
<p class="text-sm text-gray-500">15 Juillet - 30 Juillet</p>
<span class="text-xs bg-blue-100 text-blue-800 px-2 py-1 rounded-full mt-1 inline-block">Approuvé</span>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- Recent Activities -->
<div class="mt-8 bg-white rounded-xl shadow-md p-6">
<h2 class="text-xl font-semibold text-gray-800 mb-6">Activités récentes</h2>
<div class="space-y-4">
<div class="flex items-start">
<div class="bg-green-100 p-2 rounded-full mr-4 mt-1">
<i class="fas fa-check text-green-600"></i>
</div>
<div>
<p class="text-gray-800">Vous avez pointé à 08:45 aujourd'hui</p>
<p class="text-sm text-gray-500">Mer, 14 Juin 2023 - 08:45</p>
</div>
</div>
<div class="flex items-start">
<div class="bg-blue-100 p-2 rounded-full mr-4 mt-1">
<i class="fas fa-file-alt text-blue-600"></i>
</div>
<div>
<p class="text-gray-800">Nouveau rapport mensuel généré</p>
<p class="text-sm text-gray-500">Mar, 13 Juin 2023 - 16:30</p>
</div>
</div>
<div class="flex items-start">
<div class="bg-purple-100 p-2 rounded-full mr-4 mt-1">
<i class="fas fa-user-plus text-purple-600"></i>
</div>
<div>
<p class="text-gray-800">Nouveau membre ajouté à l'équipe</p>
<p class="text-sm text-gray-500">Lun, 12 Juin 2023 - 11:20</p>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
// Fonctions pour les actions
function pointerMaintenant() {
const now = new Date();
const heure = now.toLocaleTimeString('fr-FR', {hour: '2-digit', minute:'2-digit'});
alert(`Vous avez pointé à ${heure}`);
// Ici ajouter la logique pour enregistrer en base de données
}
function demanderConge() {
const dateDebut = prompt("Date de début (JJ/MM/AAAA):");
const dateFin = prompt("Date de fin (JJ/MM/AAAA):");
const motif = prompt("Motif du congé:");
if (dateDebut && dateFin && motif) {
alert(`Demande de congé envoyée du ${dateDebut} au ${dateFin}\nMotif: ${motif}`);
// Ici ajouter la logique pour enregistrer en base de données
}
}
function ajouterTache() {
const tache = prompt("Description de la tâche:");
const deadline = prompt("Date limite (JJ/MM/AAAA):");
if (tache && deadline) {
alert(`Tâche "${tache}" ajoutée avec deadline le ${deadline}`);
// Ici ajouter la logique pour enregistrer en base de données
}
}
function creerRapport() {
const type = prompt("Type de rapport (mensuel, trimestriel, annuel):");
if (type) {
alert(`Rapport ${type} généré avec succès`);
// Ici ajouter la logique pour générer le rapport
}
}
// Toggle sidebar
document.addEventListener('DOMContentLoaded', function() {
const toggleBtn = document.createElement('button');
toggleBtn.innerHTML = '<i class="fas fa-bars"></i>';
toggleBtn.className = 'fixed top-4 left-4 z-50 bg-blue-600 text-white p-2 rounded-lg shadow-lg md:hidden';
document.body.appendChild(toggleBtn);
const sidebar = document.querySelector('.sidebar');
const mainContent = document.querySelector('.main-content');
toggleBtn.addEventListener('click', function() {
sidebar.classList.toggle('collapsed');
if (window.innerWidth > 768) {
mainContent.style.marginLeft = sidebar.classList.contains('collapsed') ? '70px' : '256px';
}
});
// Responsive behavior
function handleResize() {
if (window.innerWidth <= 768) {
sidebar.classList.add('collapsed');
mainContent.style.marginLeft = '70px';
} else {
sidebar.classList.remove('collapsed');
mainContent.style.marginLeft = '256px';
}
}
window.addEventListener('resize', handleResize);
handleResize();
// Quick action buttons functionality
const quickActions = document.querySelectorAll('.card-hover');
// Gestion des actions rapides
document.querySelector('a[href="/pointer-maintenant"]').addEventListener('click', function(e) {
e.preventDefault();
pointerMaintenant();
});
document.querySelector('a[href="/demander-conge"]').addEventListener('click', function(e) {
e.preventDefault();
demanderConge();
});
document.querySelector('a[href="/ajouter-tache"]').addEventListener('click', function(e) {
e.preventDefault();
ajouterTache();
});
document.querySelector('a[href="/creer-rapport"]').addEventListener('click', function(e) {
e.preventDefault();
creerRapport();
});
});
</script>
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=dSteve01/rh-manager" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>