PHP code example of edulazaro / wireschedule

1. Go to this page and download the library: Download edulazaro/wireschedule library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

edulazaro / wireschedule example snippets


'timezone' => 'Europe/Madrid',      // organiser timezone
'ask' => ['phone' => true, 'notes' => true],
'notify' => ['to' => null],         // organiser email notified on each booking (null = no notice)
'events' => [
    'demo' => [
        'label' => 'Demo',
        'duration' => 30, 'buffer' => 0, 'days_ahead' => 21, 'min_notice' => 120,
        'availability' => [
            1 => [['10:00','14:00'], ['16:00','18:00']],  // 1 = Monday ... 7 = Sunday
        ],
    ],
],

use EduLazaro\WireSchedule\Models\Booking;

Booking::ofType('demo')->confirmed()->upcoming()->orderBy('starts_at')->get();
$booking->booker;   // polymorphic: who booked (User, ... or null for guests)
bash
composer migrate
bash
php artisan vendor:publish --tag=wireschedule-config