-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathadmin.html
More file actions
200 lines (194 loc) · 7.72 KB
/
Copy pathadmin.html
File metadata and controls
200 lines (194 loc) · 7.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
<!DOCTYPE html>
<html lang="vi">
<head>
<!--Dashboard-->
<link rel="stylesheet" href="admin.css">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Dashboard - YouMed Admin</title>
<script src="https://cdn.tailwindcss.com"></script>
<link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.3/css/all.min.css" rel="stylesheet"/>
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
<link rel="website icon" type="png" href="hospital-logo.png">
<script src="sideBar.js"></script>
<style>
.sidebar {
width: 250px;
height: 100vh;
position: fixed;
left: 0;
top: 0;
background-color: #4a90e2;
color: white;
padding: 20px;
}
.main-content {
margin-left: 250px;
padding: 20px;
}
.nav-item {
padding: 10px;
margin: 5px 0;
border-radius: 5px;
cursor: pointer;
transition: background-color 0.3s;
display: block;
text-decoration: none;
color: white;
}
.nav-item:hover {
background-color: #357abd;
}
.nav-item.active {
background-color: #357abd;
}
.dropdown-menu {
display: none;
position: absolute;
right: 0;
top: 100%;
background-color: white;
min-width: 160px;
box-shadow: 0 2px 5px rgba(0,0,0,0.2);
border-radius: 4px;
z-index: 1000;
margin-top: 0.5rem;
}
.dropdown-menu.show {
display: block;
}
.dropdown-item {
padding: 8px 16px;
color: #333;
text-decoration: none;
display: block;
white-space: nowrap;
}
.dropdown-item:hover {
background-color: #f5f5f5;
}
.dropdown-divider {
height: 1px;
background-color: #e5e5e5;
margin: 4px 0;
}
</style>
</head>
<body class="bg-gray-100">
<!-- Sidebar -->
<div class="sidebar">
</div>
<!-- Main Content -->
<div class="main-content">
<!-- Top Bar -->
<div class="flex justify-between items-center mb-8">
<h2 class="text-2xl font-bold text-gray-800">Dashboard</h2>
<div class="flex items-center">
<div class="relative mr-4" id="notificationBell">
<i class="fas fa-bell text-gray-600 text-xl"></i>
<span class="absolute -top-2 -right-1 bg-red-500 text-white text-xs rounded-full h-5 w-5 flex items-center justify-center"></span>
</div>
<div class="avatar">
<!-- Avatar dropdown -->
</div>
</div>
</div>
<!-- Stats Cards -->
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6 mb-8">
<div class="bg-white rounded-lg shadow-md p-6">
<div class="flex items-center">
<div class="p-3 rounded-full bg-blue-100 text-blue-500">
<i class="fas fa-users text-2xl"></i>
</div>
<div class="ml-4">
<p class="text-gray-500">Tổng người dùng</p>
<p class="text-2xl font-bold" id="userCount"></p>
</div>
</div>
</div>
<div class="bg-white rounded-lg shadow-md p-6">
<div class="flex items-center">
<div class="p-3 rounded-full bg-green-100 text-green-500">
<i class="fas fa-user-md text-2xl"></i>
</div>
<div class="ml-4">
<p class="text-gray-500">Tổng bác sĩ</p>
<p class="text-2xl font-bold" id="doctorCount"></p>
</div>
</div>
</div>
<div class="bg-white rounded-lg shadow-md p-6">
<div class="flex items-center">
<div class="p-3 rounded-full bg-yellow-100 text-yellow-500">
<i class="fas fa-calendar-check text-2xl"></i>
</div>
<div class="ml-4">
<p class="text-gray-500">Lịch khám hôm nay</p>
<p class="text-2xl font-bold" id="timeSlotCount"></p>
</div>
</div>
</div>
<div class="bg-white rounded-lg shadow-md p-6">
<div class="flex items-center">
<div class="p-3 rounded-full bg-red-100 text-red-500">
<i class="fas fa-hospital text-2xl"></i>
</div>
<div class="ml-4">
<p class="text-gray-500">Cuộc hẹn khám hôm nay</p>
<p class="text-2xl font-bold" id="bookingCount"></p>
</div>
</div>
</div>
</div>
<!-- Charts -->
<div class="grid grid-cols-1 lg:grid-cols-2 gap-6 mb-8">
<div class="bg-white rounded-lg shadow-md p-6">
<h3 class="text-xl font-bold mb-4">Thống kê xác nhận hẹn khám</h3>
<canvas id="appointmentsChart"></canvas>
</div>
<div class="bg-white rounded-lg shadow-md p-6">
<h3 class="text-xl font-bold mb-4">Doanh thu</h3>
<canvas id="revenueChart"></canvas>
</div>
</div>
<!-- Recent Activities -->
<div class="bg-white rounded-lg shadow-md p-6">
<h3 class="text-xl font-bold mb-4">Hoạt động gần đây</h3>
<div class="space-y-4" id="recentActivities">
<div class="flex items-center p-4 bg-gray-50 rounded-lg">
<div class="p-2 rounded-full bg-blue-100 text-blue-500">
<i class="fas fa-user-plus"></i>
</div>
<div class="ml-4">
<p class="font-medium" id="activity-user">Người dùng mới đăng ký</p>
<p class="text-sm text-gray-500" id="activity-user-time">--</p>
</div>
</div>
<div class="flex items-center p-4 bg-gray-50 rounded-lg">
<div class="p-2 rounded-full bg-green-100 text-green-500">
<i class="fas fa-calendar-check"></i>
</div>
<div class="ml-4">
<p class="font-medium" id="activity-appointment">Lịch khám đã xác nhận hôm nay</p>
<p class="text-sm text-gray-500" id="activity-appointment-time">--</p>
</div>
</div>
<div class="flex items-center p-4 bg-gray-50 rounded-lg">
<div class="p-2 rounded-full bg-yellow-100 text-yellow-500">
<i class="fas fa-user-md"></i>
</div>
<div class="ml-4">
<p class="font-medium" id="activity-doctor">Bác sĩ mới tham gia</p>
<p class="text-sm text-gray-500" id="activity-doctor-time">--</p>
</div>
</div>
</div>
</div>
</div>
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
<script src="toast.js"></script>
<script src="notificationBell.js"></script>
<script src="avatarDropdown.js"></script>
<script src="admin.js"></script>
</body>
</html>