@extends('admin.layout') @section('content')
Manage holiday schedules and special dates
{{ session('success') }}
Showing {{ $holidays->count() }} @if($filter === 'upcoming') upcoming holiday(s) @else holiday(s) @endif
| Title | Start Date | End Date | Actions |
|---|---|---|---|
|
@if($holiday->emoji)
{{ $holiday->emoji }}
@else
{{ $holiday->title }} @php $startDate = \Carbon\Carbon::parse($holiday->start_date); $endDate = \Carbon\Carbon::parse($holiday->end_date); $now = now(); $isPast = $endDate->lt($now); $isActive = $startDate->lte($now) && $endDate->gte($now); $isUpcoming = $startDate->gt($now); @endphp @if($isPast) Past @elseif($isActive) Active Now @elseif($isUpcoming) Upcoming @endif |
{{ $holiday->start_date->format('M d, Y') }}
{{ $holiday->start_date->format('g:i A T') }}
|
{{ $holiday->end_date->format('M d, Y') }}
{{ $holiday->end_date->format('g:i A T') }}
|
{{-- Edit Button --}}
Edit
{{-- Delete Button --}}
|
|
@if($filter === 'upcoming') No upcoming holidays found @else No holidays found @endif @if($filter === 'upcoming') Try viewing all holidays or create a new one @else Get started by adding your first holiday @endif |
|||