mirror of
https://github.com/Einundzwanzig-Podcast/einundzwanzig-portal.git
synced 2025-12-11 06:46:47 +00:00
19 lines
400 B
PHP
19 lines
400 B
PHP
<?php
|
|
|
|
namespace App\Models\Scopes;
|
|
|
|
use Illuminate\Database\Eloquent\Builder;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
use Illuminate\Database\Eloquent\Scope;
|
|
|
|
class ActiveBookCases implements Scope
|
|
{
|
|
/**
|
|
* Apply the scope to a given Eloquent query builder.
|
|
*/
|
|
public function apply(Builder $builder, Model $model): void
|
|
{
|
|
$builder->where('deactivated', false);
|
|
}
|
|
}
|