user()?->hasRole('Admin') === true; } /** * @return array */ public function rules(): array { return [ 'quantity' => ['required', 'integer', 'min:1', 'max:9999'], 'taken_at' => ['nullable', 'date'], 'taken_by_name' => ['required', 'string', 'max:255'], 'notes' => ['nullable', 'string', 'max:2000'], ]; } }