source: resources/views/welcome.blade.php@ 249bf91

main
Last change on this file since 249bf91 was 249bf91, checked in by bube-ristovska <ristovska725@…>, 5 months ago

New feature - details for employee

  • Property mode set to 100644
File size: 13.7 KB
Line 
1<!DOCTYPE html>
2<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
3 <head>
4 <meta charset="utf-8">
5 <meta name="viewport" content="width=device-width, initial-scale=1">
6
7 <title>Laravel</title>
8
9 <!-- Fonts -->
10 <link rel="preconnect" href="https://fonts.bunny.net">
11 <link href="https://fonts.bunny.net/css?family=figtree:400,600&display=swap" rel="stylesheet" />
12
13 <!-- Styles -->
14 <style>
15 @import url('https://fonts.googleapis.com/css?family=Karla:400,700&display=swap');
16 .font-family-karla { font-family: karla; }
17 .bg-sidebar { background: #3d68ff; }
18 .cta-btn { color: #3d68ff; }
19 .upgrade-btn { background: #1947ee; }
20 .upgrade-btn:hover { background: #0038fd; }
21 .active-nav-link { background: #1947ee; }
22 .nav-item:hover { background: #1947ee; }
23 .account-link:hover { background: #3d68ff; }
24 </style>
25 <script src="https://cdn.tailwindcss.com"></script>
26
27 </head>
28 <body class="bg-gray-100 font-family-karla flex">
29 <aside class="relative bg-sidebar h-screen w-64 hidden sm:block shadow-xl">
30 <div class="p-6">
31 @if (Session::get('is_policeman'))
32 <a href="#" class="text-white text-3xl font-semibold uppercase hover:text-gray-300">Полицаец</a>
33 <button class="w-full bg-white cta-btn font-semibold py-2 mt-5 rounded-br-lg rounded-bl-lg rounded-tr-lg shadow-lg hover:shadow-xl hover:bg-gray-300 flex items-center justify-center">
34 <i class="fas fa-plus mr-3"></i> <a href="/register-statement">Додади изјава</a>
35 </button>
36 @else
37 <a href="#" class="text-white text-3xl font-semibold uppercase hover:text-gray-300">Началник</a>
38 <button class="w-full bg-white cta-btn font-semibold py-2 mt-5 rounded-br-lg rounded-bl-lg rounded-tr-lg shadow-lg hover:shadow-xl hover:bg-gray-300 flex items-center justify-center">
39 <i class="fas fa-plus mr-3"></i> <a href="/register-policeman">Додади полицаец</a>
40 </button>
41 @endif
42 </div>
43 <nav class="text-white text-base font-semibold pt-3">
44 <a href="/" class="flex items-center active-nav-link text-white py-4 pl-6 nav-item">
45 <i class="fas fa-tachometer-alt mr-3"></i>
46 Контролна табла
47 </a>
48 <a href="/employees" class="flex items-center text-white opacity-75 hover:opacity-100 py-4 pl-6 nav-item">
49 <i class="fas fa-sticky-note mr-3"></i>
50 Вработени
51 </a>
52 <a href="/filter" class="flex items-center text-white opacity-75 hover:opacity-100 py-4 pl-6 nav-item">
53 <i class="fas fa-table mr-3"></i>
54 Филтрирај граѓани
55 </a>
56 <a href="/cases" class="flex items-center text-white opacity-75 hover:opacity-100 py-4 pl-6 nav-item">
57 <i class="fas fa-align-left mr-3"></i>
58 Случаи
59 </a>
60 <a href="/finished_cases" class="flex items-center text-white opacity-75 hover:opacity-100 py-4 pl-6 nav-item">
61 <i class="fas fa-calendar mr-3"></i>
62 Архива
63 </a>
64 </nav>
65 <a href="#" class="absolute w-full upgrade-btn bottom-0 active-nav-link text-white flex items-center justify-center py-4">
66 <i class="fas fa-arrow-circle-up mr-3"></i>
67
68 </a>
69 </aside>
70
71 <div class="w-full flex flex-col h-screen overflow-y-hidden">
72 <!-- Desktop Header -->
73 <header class="w-full items-center bg-white py-2 px-6 hidden sm:flex">
74 <div class="w-1/2"></div>
75 <div x-data="{ isOpen: false }" class="relative w-1/2 flex justify-end">
76 <button @click="isOpen = !isOpen" class="realtive z-10 w-12 h-12 rounded-full overflow-hidden border-4 border-gray-400 hover:border-gray-300 focus:border-gray-300 focus:outline-none">
77 @php
78 $person = DB::select('select * from people where pe_id=:pe_id;', ['pe_id' => Session::get('pe_id')]);
79
80 if (!empty($person)) {
81 $image = $person[0]->picture;
82 } else {
83 $image = null;
84 }
85 @endphp
86
87 <img src="{{ $image }}">
88 </button>
89 <button x-show="isOpen" @click="isOpen = false" class="h-full w-full fixed inset-0 cursor-default"></button>
90 <div x-show="isOpen" class="absolute w-32 bg-white rounded-lg shadow-lg py-2 mt-16">
91 <a href="#" class="block px-4 py-2 account-link hover:text-white">Профил</a>
92 <a href="#" class="block px-4 py-2 account-link hover:text-white">Помош</a>
93 <a href="/logout" class="block px-4 py-2 account-link hover:text-white">Одјави се</a>
94 </div>
95 </div>
96 </header>
97
98 <!-- Mobile Header & Nav -->
99 <header x-data="{ isOpen: false }" class="w-full bg-sidebar py-5 px-6 sm:hidden">
100 <div class="flex items-center justify-between">
101 <a href="/" class="text-white text-3xl font-semibold uppercase hover:text-gray-300">Началник</a>
102 <button @click="isOpen = !isOpen" class="text-white text-3xl focus:outline-none">
103 <i x-show="!isOpen" class="fas fa-bars"></i>
104 <i x-show="isOpen" class="fas fa-times"></i>
105 </button>
106 </div>
107
108 <!-- Dropdown Nav -->
109 <nav :class="isOpen ? 'flex': 'hidden'" class="flex flex-col pt-4">
110 <a href="/" class="flex items-center active-nav-link text-white py-2 pl-4 nav-item">
111 <i class="fas fa-tachometer-alt mr-3"></i>
112 Контролна табла
113 </a>
114 <a href="/employees" class="flex items-center text-white opacity-75 hover:opacity-100 py-2 pl-4 nav-item">
115 <i class="fas fa-sticky-note mr-3"></i>
116 Вработени
117 </a>
118 <a href="/filter" class="flex items-center text-white opacity-75 hover:opacity-100 py-2 pl-4 nav-item">
119 <i class="fas fa-table mr-3"></i>
120 Филтрирај граѓани
121 </a>
122 <a href="/cases" class="flex items-center text-white opacity-75 hover:opacity-100 py-2 pl-4 nav-item">
123 <i class="fas fa-align-left mr-3"></i>
124 Случаи
125 </a>
126
127 <a href="/finished_cases" class="flex items-center text-white opacity-75 hover:opacity-100 py-2 pl-4 nav-item">
128 <i class="fas fa-calendar mr-3"></i>
129 Архива
130 </a>
131 <a href="/help" class="flex items-center text-white opacity-75 hover:opacity-100 py-2 pl-4 nav-item">
132 <i class="fas fa-cogs mr-3"></i>
133 Помош
134 </a>
135 <a href="/myprofile" class="flex items-center text-white opacity-75 hover:opacity-100 py-2 pl-4 nav-item">
136 <i class="fas fa-user mr-3"></i>
137 Мој профил
138 </a>
139 <a href="/logout" class="flex items-center text-white opacity-75 hover:opacity-100 py-2 pl-4 nav-item">
140 <i class="fas fa-sign-out-alt mr-3"></i>
141 Одјави се
142 </a>
143
144 </nav>
145 <button class="w-full bg-white cta-btn font-semibold py-2 mt-5 rounded-br-lg rounded-bl-lg rounded-tr-lg shadow-lg hover:shadow-xl hover:bg-gray-300 flex items-center justify-center">
146 <i class="fas fa-plus mr-3"></i> Нов извештај
147 </button>
148 </header>
149
150 <div class="w-full overflow-x-hidden border-t flex flex-col">
151 <main class="w-full flex-grow p-6">
152 <h1 class="text-3xl text-black pb-6">Контролна табла</h1>
153
154 <div class="flex flex-wrap mt-6">
155 <div class="w-full lg:w-1/2 pr-0 lg:pr-2">
156 <p class="text-xl pb-3 flex items-center">
157 <i class="fas fa-plus mr-3"></i> Месечни извештаи
158 </p>
159 <div class="p-6 bg-white">
160 <canvas id="chartOne" width="400" height="200"></canvas>
161 </div>
162 </div>
163 <div class="w-full lg:w-1/2 pl-0 lg:pl-2 mt-12 lg:mt-0">
164 <p class="text-xl pb-3 flex items-center">
165 <i class="fas fa-check mr-3"></i> Решени случаи
166 </p>
167 <div class="p-6 bg-white">
168 <canvas id="chartTwo" width="400" height="200"></canvas>
169 </div>
170 </div>
171 </div>
172
173
174 </main>
175
176 <footer class="w-full bg-white text-right p-4">
177 UI/UX инспирирано од <a target="_blank" href="https://davidgrzyb.com" class="underline">David Grzyb</a>.
178 </footer>
179 </div>
180
181 </div>
182
183 <!-- AlpineJS -->
184 <script src="https://cdn.jsdelivr.net/gh/alpinejs/alpine@v2.x.x/dist/alpine.min.js" defer></script>
185 <!-- Font Awesome -->
186 <script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.13.0/js/all.min.js" integrity="sha256-KzZiKy0DWYsnwMF+X1DvQngQ2/FxF7MF3Ff72XcpuPs=" crossorigin="anonymous"></script>
187 <!-- ChartJS -->
188 <script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.9.3/Chart.min.js" integrity="sha256-R4pqcOYV8lt7snxMQO/HSbVCFRPMdrhAFMH+vr9giYI=" crossorigin="anonymous"></script>
189
190 <script>
191 var chartOne = document.getElementById('chartOne');
192 var myChart = new Chart(chartOne, {
193 type: 'bar',
194 data: {
195 labels: ['Јануари', 'Фебруари', 'Март', 'Април', 'Мај', 'Јуни'],
196 datasets: [{
197 label: 'Прва половина на 2023 година',
198 data: [12, 19, 3, 5, 2, 3],
199 backgroundColor: [
200 'rgba(255, 99, 132, 0.2)',
201 'rgba(54, 162, 235, 0.2)',
202 'rgba(255, 206, 86, 0.2)',
203 'rgba(75, 192, 192, 0.2)',
204 'rgba(153, 102, 255, 0.2)',
205 'rgba(255, 159, 64, 0.2)'
206 ],
207 borderColor: [
208 'rgba(255, 99, 132, 1)',
209 'rgba(54, 162, 235, 1)',
210 'rgba(255, 206, 86, 1)',
211 'rgba(75, 192, 192, 1)',
212 'rgba(153, 102, 255, 1)',
213 'rgba(255, 159, 64, 1)'
214 ],
215 borderWidth: 1
216 }]
217 },
218 options: {
219 scales: {
220 yAxes: [{
221 ticks: {
222 beginAtZero: true
223 }
224 }]
225 }
226 }
227 });
228
229 var chartTwo = document.getElementById('chartTwo');
230 var myLineChart = new Chart(chartTwo, {
231 type: 'line',
232 data: {
233 labels: ['Јануари', 'Фебруари', 'Март', 'Април', 'Мај', 'Јуни'],
234 datasets: [{
235 label: 'До моменталниот месец',
236 data: [12, 19, 3, 5, 2, 3],
237 backgroundColor: [
238 'rgba(255, 99, 132, 0.2)',
239 'rgba(54, 162, 235, 0.2)',
240 'rgba(255, 206, 86, 0.2)',
241 'rgba(75, 192, 192, 0.2)',
242 'rgba(153, 102, 255, 0.2)',
243 'rgba(255, 159, 64, 0.2)'
244 ],
245 borderColor: [
246 'rgba(255, 99, 132, 1)',
247 'rgba(54, 162, 235, 1)',
248 'rgba(255, 206, 86, 1)',
249 'rgba(75, 192, 192, 1)',
250 'rgba(153, 102, 255, 1)',
251 'rgba(255, 159, 64, 1)'
252 ],
253 borderWidth: 1
254 }]
255 },
256 options: {
257 scales: {
258 yAxes: [{
259 ticks: {
260 beginAtZero: true
261 }
262 }]
263 }
264 }
265 });
266 </script>
267 </body>
268</html>
Note: See TracBrowser for help on using the repository browser.