function MenuLinkResetForm::linkIsResettable
Same name in other branches
- 9 core/modules/menu_ui/src/Form/MenuLinkResetForm.php \Drupal\menu_ui\Form\MenuLinkResetForm::linkIsResettable()
- 8.9.x core/modules/menu_ui/src/Form/MenuLinkResetForm.php \Drupal\menu_ui\Form\MenuLinkResetForm::linkIsResettable()
- 10 core/modules/menu_ui/src/Form/MenuLinkResetForm.php \Drupal\menu_ui\Form\MenuLinkResetForm::linkIsResettable()
Checks access based on whether the link can be reset.
Parameters
\Drupal\Core\Menu\MenuLinkInterface $menu_link_plugin: The menu link plugin being checked.
Return value
\Drupal\Core\Access\AccessResultInterface The access result.
1 string reference to 'MenuLinkResetForm::linkIsResettable'
- menu_ui.routing.yml in core/
modules/ menu_ui/ menu_ui.routing.yml - core/modules/menu_ui/menu_ui.routing.yml
File
-
core/
modules/ menu_ui/ src/ Form/ MenuLinkResetForm.php, line 118
Class
- MenuLinkResetForm
- Defines a confirmation form for resetting a single modified menu link.
Namespace
Drupal\menu_ui\FormCode
public function linkIsResettable(MenuLinkInterface $menu_link_plugin) {
return AccessResult::allowedIf($menu_link_plugin->isResettable())
->setCacheMaxAge(0);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.