source: pt123/templates/teachers.html@ 5496375

main
Last change on this file since 5496375 was 5496375, checked in by Damjan <sepetovskidamjan@…>, 2 weeks ago

Initial commit

  • Property mode set to 100644
File size: 4.9 KB
Line 
1<!DOCTYPE html>
2<html lang="en">
3<head>
4 <meta charset="UTF-8">
5 <meta name="viewport" content="width=device-width, initial-scale=1.0">
6 <title>Teachers - School Management System</title>
7 <link rel="shortcut icon" href="#">
8 <style>
9 body {
10 font-family: 'Arial', sans-serif;
11 margin: 0;
12 padding: 0;
13 background-color: #f8f9fa;
14 color: #333;
15 }
16
17 header {
18 background-color: #007bff;
19 color: white;
20 padding: 40px 20px;
21 text-align: center;
22 }
23
24 header h1 {
25 font-size: 2.5rem;
26 margin: 0;
27 }
28
29 .container {
30 width: 90%;
31 max-width: 1200px;
32 margin: 40px auto;
33 padding: 20px;
34 background-color: white;
35 border-radius: 10px;
36 box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
37 }
38
39 .filter-form {
40 margin-bottom: 20px;
41 display: flex;
42 align-items: center;
43 gap: 10px;
44 }
45
46 .filter-form label {
47 font-size: 1rem;
48 color: #333;
49 }
50
51 .filter-form input[type="date"] {
52 padding: 8px;
53 border: 1px solid #ddd;
54 border-radius: 5px;
55 font-size: 1rem;
56 }
57
58 .filter-form button {
59 padding: 8px 16px;
60 background-color: #28a745;
61 color: white;
62 border: none;
63 border-radius: 5px;
64 font-size: 1rem;
65 cursor: pointer;
66 transition: background-color 0.3s ease;
67 }
68
69 .filter-form button:hover {
70 background-color: #218838;
71 }
72
73 table {
74 width: 100%;
75 border-collapse: collapse;
76 margin: 20px 0;
77 }
78
79 th, td {
80 padding: 12px;
81 text-align: left;
82 border-bottom: 1px solid #ddd;
83 }
84
85 th {
86 background-color: #007bff;
87 color: white;
88 font-weight: bold;
89 }
90
91 tr:nth-child(even) {
92 background-color: #f9f9f9;
93 }
94
95 tr:hover {
96 background-color: #f1f1f1;
97 }
98
99 .no-data {
100 text-align: center;
101 font-size: 1.2rem;
102 color: #888;
103 padding: 20px;
104 }
105
106 .actions {
107 display: flex;
108 justify-content: center;
109 gap: 10px;
110 margin-top: 20px;
111 }
112
113 .actions a {
114 display: inline-block;
115 padding: 10px 20px;
116 background-color: #28a745;
117 color: white;
118 text-decoration: none;
119 border-radius: 5px;
120 font-size: 1rem;
121 transition: background-color 0.3s ease;
122 }
123
124 .actions a:hover {
125 background-color: #218838;
126 }
127
128 footer {
129 background-color: #343a40;
130 color: white;
131 text-align: center;
132 padding: 20px 0;
133 margin-top: 40px;
134 }
135
136 footer p {
137 margin: 0;
138 }
139
140 @media (max-width: 768px) {
141 table {
142 display: block;
143 overflow-x: auto;
144 }
145
146 .filter-form {
147 flex-direction: column;
148 align-items: flex-start;
149 }
150 }
151 </style>
152</head>
153<body>
154 <header>
155 <h1>Teachers List</h1>
156 </header>
157
158 <div class="container">
159 <!-- Filter Form -->
160 <form method="GET" action="/teachers" class="filter-form">
161 <label for="from_date">From Date:</label>
162 <input type="date" id="from_date" name="from_date">
163 <button type="submit">Filter</button>
164 </form>
165
166 {% if teachers %}
167 <table>
168 <thead>
169 <tr>
170 <th>ID Teacher</th>
171 <th>Hire Date</th>
172 <th>Username</th>
173 <th>Email</th>
174 <th>Subject</th>
175 </tr>
176 </thead>
177 <tbody>
178 {% for teacher in teachers %}
179 <tr>
180 <td>{{ teacher.id_teacher }}</td>
181 <td>{{ teacher.hire_date }}</td>
182 <td>{{ teacher.username }}</td>
183 <td>{{ teacher.email }}</td>
184 <td>{{ teacher.department }}</td>
185 </tr>
186 {% endfor %}
187 </tbody>
188 </table>
189 {% else %}
190 <p class="no-data">No teachers available at the moment.</p>
191 {% endif %}
192
193 <div class="actions">
194 <a href="/">Home</a>
195 <a href="/subjects">View Subjects</a>
196 <a href="/users">View Users</a>
197 </div>
198 </div>
199
200 <footer>
201 <p>&copy; 2023 School Management System. All rights reserved.</p>
202 </footer>
203</body>
204</html>
Note: See TracBrowser for help on using the repository browser.