protected function EntityMenuLinkCloneForm::menuLinksAvailabilityCheck in Menu Link Clone 8
Same name and namespace in other branches
- 8.3 src/Form/EntityMenuLinkCloneForm.php \Drupal\menu_link_clone\Form\EntityMenuLinkCloneForm::menuLinksAvailabilityCheck()
- 8.2 src/Form/EntityMenuLinkCloneForm.php \Drupal\menu_link_clone\Form\EntityMenuLinkCloneForm::menuLinksAvailabilityCheck()
Check Menu Link items are availabe inside the menu.
Parameters
string $source_menu_id: Menu name for which we need to check their items.
1 call to EntityMenuLinkCloneForm::menuLinksAvailabilityCheck()
- EntityMenuLinkCloneForm::submitForm in src/
Form/ EntityMenuLinkCloneForm.php - Form submission handler.
File
- src/
Form/ EntityMenuLinkCloneForm.php, line 123
Class
- EntityMenuLinkCloneForm
- Provides a menu link clone form.
Namespace
Drupal\menu_link_clone\FormCode
protected function menuLinksAvailabilityCheck($source_menu_id) {
$result = FALSE;
if (isset($source_menu_id) && !empty($source_menu_id)) {
$menuLinkIds = $this
->getMenuItemIds($source_menu_id);
if ($menuLinkIds['status']) {
$result = TRUE;
}
}
return $result;
}