Search by

jeffersongoncalves / filament-open-hours

jeffersongoncalves

Opening hours for Filament: manage the weekly schedule, holidays, special dates and timezone from a settings page and show an open/closed status widget, powered by laravel-open-hours.

3.0.0 2026-10-08 00:44 UTC

README

Filament Open Hours

Filament Open Hours

Buy Me A Coffee

Latest Version on Packagist Tests Total Downloads License

Manage your business opening hours from the Filament panel — weekly schedule, holidays and special dates (one-off or every year) and timezone — and see at a glance whether you're open right now.

Built on jeffersongoncalves/laravel-open-hours, which stores the schedule with Spatie Laravel Settings and gives your site isOpen(), nextOpen(), the @openhours Blade directive and an "Open now · closes at 18:00" component.

Compatibility

Branch Filament Package version
1.x 3.x ^1.0
2.x 4.x ^2.0
3.x 5.x ^3.0

Installation

composer require jeffersongoncalves/filament-open-hours:"^3.0"
php artisan migrate

The settings migration seeds Monday–Friday 09:00–18:00 (change the defaults in config/open-hours.php before migrating if you like).

Usage

Add the plugin to your panel provider:

use JeffersonGoncalves\Filament\OpenHours\OpenHoursPlugin;

public function panel(Panel $panel): Panel
{
    return $panel
        ->plugins([
            OpenHoursPlugin::make(),
        ]);
}

Then open Opening hours:

Section
Weekly schedule Timezone (empty = app timezone) and the opening ranges of each day — 09:00-12:00, 13:00-18:00, overnight 22:00-02:00. A day with no range is closed.
Holidays and special dates A date, optionally every year, with its own ranges (none = closed) and a note.

Overlapping or malformed ranges are rejected on save. The dashboard gets an Opening hours widget showing Open / Closed and when that changes.

On your site:

<x-open-hours::status class="badge" />

@openhours
    <a href="https://wa.me/5511999999999">Chat with us</a>
@else
    <p>We're closed right now — leave a message.</p>
@endopenhours

Customization

OpenHoursPlugin::make()
    ->navigationGroup('Settings')
    ->settingsPage(false) // don't register the settings page
    ->widget(false),      // don't add the dashboard widget

Requirements

  • PHP 8.2 or higher
  • Filament 5.x

Testing

composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Security Vulnerabilities

Please review our security policy on how to report security vulnerabilities.

Credits

License

The MIT License (MIT). Please see License File for more information.