canDo('payment.refund.approve')) { return true; } return false; } /** * Determine if the given user can approve the given refund. * * @param Authenticatable $user * * @return bool */ public function submit(Authenticatable $user, Refund $refund) { if ($user->canDo('payment.refund.submit')) { return true; } return false; } /** * Determine if the given user can approve the given refund. * * @param Authenticatable $user * * @return bool */ public function publish(Authenticatable $user, Refund $refund) { if ($user->canDo('payment.refund.publish')) { return true; } return false; } /** * Determine if the given user can approve the given refund. * * @param Authenticatable $user * * @return bool */ public function unpublish(Authenticatable $user, Refund $refund) { if ($user->canDo('payment.refund.unpublish')) { return true; } return false; } /** * Determine if the given user can approve the given refund. * * @param Authenticatable $user * * @return bool */ public function archive(Authenticatable $user, Refund $refund) { if ($user->canDo('payment.refund.archive')) { return true; } return false; } /** * Determine if the given user can approve the given refund. * * @param Authenticatable $user * * @return bool */ public function unarchive(Authenticatable $user, Refund $refund) { if ($user->canDo('payment.refund.unarchive')) { return true; } return false; } /** * Determine if the given user can approve the given refund. * * @param Authenticatable $user * * @return bool */ public function reject(Authenticatable $user, Refund $refund) { if ($user->canDo('payment.refund.reject')) { return true; } return false; } }