snipe-it/app/Policies/AssetPolicy.php
2018-02-21 08:13:18 -08:00

25 lines
498 B
PHP

<?php
namespace App\Policies;
use App\Models\User;
use App\Policies\CheckoutablePermissionsPolicy;
class AssetPolicy extends CheckoutablePermissionsPolicy
{
protected function columnName()
{
return 'assets';
}
public function viewRequestable(User $user, Asset $asset = null)
{
return $user->hasAccess('assets.view.requestable');
}
public function audit(User $user, Asset $asset = null)
{
return $user->hasAccess('assets.audit');
}
}