clrghouz/app/Models/Zone.php

22 lines
277 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
use App\Traits\ScopeActive;
class Zone extends Model
{
use ScopeActive;
/* SCOPES */
/**
* Only query active records
*/
public function scopePublic()
{
return $this->where('public',TRUE);
}
}