<?php
 namespace App\Policies; use App\Models\Admin; use App\Models\Language; use Illuminate\Auth\Access\HandlesAuthorization; class LanguagePolicy { use HandlesAuthorization; public function viewAny(Admin $admin): bool { return $admin->hasPermissionTo('view languages'); } public function view(Admin $admin, Language $language): bool { return $admin->hasPermissionTo('view languages'); } public function create(Admin $admin): bool { return $admin->hasPermissionTo('create languages'); } public function update(Admin $admin, Language $language): bool { return $admin->hasPermissionTo('update languages'); } public function updateAny(Admin $admin): bool { return $admin->hasPermissionTo('update languages'); } public function delete(Admin $admin, Language $language): bool { return $admin->hasPermissionTo('delete languages'); } public function deleteAny(Admin $admin): bool { return $admin->hasPermissionTo('delete languages'); } } 