<?php

namespace Modules\Manage\Models;

use Catch\Base\CatchModel as Model;
use Illuminate\Database\Eloquent\Builder;


abstract class BaseModel extends Model
{

    protected array $defaultHidden = [];

    protected array $defaultCasts = [
        'created_at' => 'datetime:Y-m-d H:i:s',

        'updated_at' => 'datetime:Y-m-d H:i:s',
    ];
    protected $dateFormat = '';

    public static function bootSoftDeletes(): void{

    }


    public function scopeActive(Builder $query): void
    {
        $query->where($this->table.'.is_enabled', 1);
    }
}
