@extends('adminlte::page') @section('title', config('adminlte.title') . ' | Dashboard') @php $firstName = explode(' ', Auth::user()->name)[0]; @endphp @section('content_header')

Welcome Back, {{ $firstName }}!

{{--
{{ \Carbon\Carbon::now()->format('l jS F Y H:i') }}
--}}
@stop @section('content')
{{-- Announcement Section --}}
@if ($announcement->status === 1) @php $description = $announcement->description; preg_match('/\[(.*?)\]\s*(.*)/', $description, $matches); if (count($matches) === 3) { $type = $matches[1]; $message = $matches[2]; } else { $type = 'info'; $message = $description; } @endphp @endif
{{-- Weather & Quick Info --}}

Current Weather

Loading...
@php // Calculate total entitlement and taken for current year $currentYearTotal = $holidaysTotal ?? 0; $currentYearRemaining = $holidaysRemaining ?? 0; // Calculate taken as the difference $currentYearTaken = $currentYearTotal - $currentYearRemaining; @endphp

Duvet Day

@if (!!$duvetDayUsed)

Already Used

Used on: {{ $duvetDayDate ?? 'N/A' }}

@else

Available

1 duvet day remaining this year

@endif
{{-- Quick Actions --}}
{{-- Upcoming Holidays --}} @if (isset($upcomingHolidays) && count($upcomingHolidays) > 0)

Your Upcoming Holidays

@foreach ($upcomingHolidays as $holiday) @endforeach
Start Date End Date Type Days Status
{{ $holiday->start_date->format('d M Y') }} {{ $holiday->end_date->format('d M Y') }} {{ $holiday->type }} {{ number_format($holiday->days, 1) }} days {{ ucfirst($holiday->status) }}
@endif @stop @section('footer')   @stop @section('js') @stop