Jetstream dashboard
This commit is contained in:
111
resources/views/admin/analytics.blade.php
Normal file
111
resources/views/admin/analytics.blade.php
Normal file
@@ -0,0 +1,111 @@
|
||||
<x-app-layout>
|
||||
<x-slot name="header">
|
||||
<h2 class="font-semibold text-xl text-gray-800 leading-tight">
|
||||
{{ __('Analytics') }}
|
||||
</h2>
|
||||
</x-slot>
|
||||
|
||||
|
||||
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 mt-8">
|
||||
<div class="sm:grid sm:grid-cols-2 sm:gap-10">
|
||||
<div>
|
||||
<h2 class="text-2xl font-bold leading-tight text-gray-900">
|
||||
Visitors and Page Views(Last 2 days)
|
||||
</h2>
|
||||
<div class="flex flex-col mt-6">
|
||||
<div class="-my-2 py-2 overflow-x-auto sm:-mx-6 sm:px-6 lg:-mx-8 lg:px-8">
|
||||
<div
|
||||
class="align-middle inline-block min-w-full shadow overflow-hidden rounded-lg border-b border-gray-200">
|
||||
<table class="min-w-full">
|
||||
<tbody>
|
||||
<tr class="bg-white">
|
||||
<td
|
||||
class="px-6 py-4 whitespace-no-wrap text-sm leading-5 font-semibold text-gray-800">
|
||||
Page Title
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-no-wrap text-sm leading-5 font-semibold text-gray-800">
|
||||
Visitors
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-no-wrap text-sm leading-5 font-semibold text-gray-800">
|
||||
Page Views
|
||||
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
@foreach ($VisitorsAndPageViews as $VisitorsAndPageView)
|
||||
<tr class="bg-gray-50">
|
||||
<td
|
||||
class="px-6 py-4 whitespace-no-wrap text-sm leading-5 font-medium text-gray-900">
|
||||
{{Str::limit($VisitorsAndPageView['pageTitle'],35)}}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-no-wrap text-sm leading-5 text-gray-500">
|
||||
{{$VisitorsAndPageView['visitors']}}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-no-wrap text-sm leading-5 text-gray-500">
|
||||
{{$VisitorsAndPageView['pageViews']}}
|
||||
|
||||
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
|
||||
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mt-6 sm:mt-0">
|
||||
<h2 class="text-2xl font-bold leading-tight text-gray-900">
|
||||
Total Visitors and Page Views (Last 7 days)
|
||||
</h2>
|
||||
|
||||
<div class="flex flex-col mt-6">
|
||||
<div class="-my-2 py-2 overflow-x-auto sm:-mx-6 sm:px-6 lg:-mx-8 lg:px-8">
|
||||
<div
|
||||
class="align-middle inline-block min-w-full shadow overflow-hidden rounded-lg border-b border-gray-200">
|
||||
<table class="min-w-full">
|
||||
<tbody>
|
||||
<tr class="bg-white">
|
||||
<td
|
||||
class="px-6 py-4 whitespace-no-wrap text-sm leading-5 font-semibold text-gray-900">
|
||||
Date
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-no-wrap text-sm leading-5 font-semibold text-gray-900">
|
||||
Visitors
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-no-wrap text-sm leading-5font-semibold text-gray-900">
|
||||
Page Views
|
||||
</td>
|
||||
</tr>
|
||||
@foreach ($TotalVisitorsAndPageViews as $TotalVisitorsAndPageView)
|
||||
<tr class="bg-gray-50">
|
||||
<td
|
||||
class="px-6 py-4 whitespace-no-wrap text-sm leading-5 font-medium text-gray-900">
|
||||
{{$TotalVisitorsAndPageView['date']->diffforHumans()}}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-no-wrap text-sm leading-5 text-gray-500">
|
||||
{{$TotalVisitorsAndPageView['visitors']}}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-no-wrap text-sm leading-5 text-gray-500">
|
||||
{{$TotalVisitorsAndPageView['pageViews']}}
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</x-app-layout>
|
||||
Reference in New Issue
Block a user