PHP code example of mindtwo / laravel-enumerable
1. Go to this page and download the library: Download mindtwo/laravel-enumerable 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/ */
mindtwo / laravel-enumerable example snippets
namespace example;
use mindtwo\LaravelEnumerable\Models\EnumerableModel
class exampleModel extends EnumerableModel
{
}
namespace example;
use Illuminate\Database\Eloquent\Model;
use mindtwo\LaravelEnumerable\Interfaces\EnumInterface;
use mindtwo\LaravelEnumerable\Models\Traits\Enumerable;
class exampleModel extends Model implements EnumInterface
{
use Enumerable;
}
namespace example;
use mindtwo\LaravelEnumerable\Models\EnumerableModel
class exampleModel extends EnumerableModel
{
public $enums = [
'examle_attribute' => ExampleEnum::class
];
}