43 lines
796 B
PHP
43 lines
796 B
PHP
<?php
|
|
|
|
namespace App\Modules\Province\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
use Spatie\Translatable\HasTranslations;
|
|
|
|
/**
|
|
* @property int $id
|
|
* @property string $region
|
|
* @property array<string, string> $name
|
|
* @property bool $active
|
|
* @property \Illuminate\Support\Carbon $created_at
|
|
* @property \Illuminate\Support\Carbon $updated_at
|
|
*/
|
|
class Province extends Model
|
|
{
|
|
use HasTranslations;
|
|
|
|
/**
|
|
* Table name
|
|
*
|
|
* @var string
|
|
*/
|
|
protected $table = 'provinces';
|
|
|
|
/**
|
|
* Translatable fieldsg
|
|
*
|
|
* @var array<int, string>
|
|
*/
|
|
public $translatable = ['name'];
|
|
|
|
/**
|
|
* The attributes that should be cast.
|
|
*
|
|
* @var array<string, string>
|
|
*/
|
|
protected $casts = [
|
|
'active' => 'boolean',
|
|
];
|
|
}
|