PHP code example of flysquare / laravel-recurring-models
1. Go to this page and download the library: Download flysquare/laravel-recurring-models 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/ */
flysquare / laravel-recurring-models example snippets
use MohammedManssour\LaravelRecurringModels\Contracts\Repeatable as RepeatableContract;
class Task extends Model implements RepeatableContract
{
}
use MohammedManssour\LaravelRecurringModels\Contracts\Repeatable as RepeatableContract;
use MohammedManssour\LaravelRecurringModels\Concerns\Repeatable;
class Task extends Model implements RepeatableContract
{
use Repeatable;
}
/**
* define the base date that we would use to calculate repetition start_at
*/
public function repetitionBaseDate(RepetitionType $type = null): Carbon
{
return $this->created_at;
}