StorageRequestPolicy
class StorageRequestPolicy extends CachedPolicy
Traits
Constants
TIME |
Time to store the cached values. (is irrelevant for the array store) |
Properties
protected Repository | $cache | The cache instance to use for caching policies. |
from CachedPolicy |
Methods
Wrapper for the Cache::remember function of the array cache.
Determine if the given request can be accessed by the user.
Determine if the given user can update the storage request.
Determine if the given user can approve the storage request.
Determine if the given user can reject the storage request.
Determine if the given user can destroy the storage request.
Details
in
CachedPolicy at line 31
__construct()
Create a new CachedPolicy.
in
CachedPolicy at line 43
mixed
remember(string $key, callable $callback)
Wrapper for the Cache::remember function of the array cache.
at line 23
bool|null
before(User $user, string $ability)
Intercept all checks.
at line 38
bool
create(User $user)
Determine if the given user can create a new request.
at line 54
bool
access(User $user, StorageRequest $request)
Determine if the given request can be accessed by the user.
at line 67
bool
update(User $user, StorageRequest $request)
Determine if the given user can update the storage request.
at line 84
bool
approve(User $user, StorageRequest $request)
Determine if the given user can approve the storage request.
at line 98
bool
reject(User $user, StorageRequest $request)
Determine if the given user can reject the storage request.
at line 111
bool
destroy(User $user, StorageRequest $request)
Determine if the given user can destroy the storage request.