diff --git a/src/Extensions/MenuSetParentExtension.php b/src/Extensions/MenuSetParentExtension.php index 59b5672..0af1c1e 100644 --- a/src/Extensions/MenuSetParentExtension.php +++ b/src/Extensions/MenuSetParentExtension.php @@ -31,6 +31,10 @@ class MenuSetParentExtension extends DataExtension 'MenuSets' ]; + private static $cascade_duplicates = [ + 'MenuSets' + ]; + public function updateCMSFields(FieldList $fields) { $fields->removeByName('MenuSets'); diff --git a/src/Model/MenuItem.php b/src/Model/MenuItem.php index 25d3a5a..2d06e47 100644 --- a/src/Model/MenuItem.php +++ b/src/Model/MenuItem.php @@ -70,6 +70,10 @@ class MenuItem extends SuperLink 'Children' ]; + private static $cascade_duplicates = [ + 'Children' + ]; + private static $field_labels = [ 'SubmenuMode' => 'Submenu', 'SubmenuSiteTree' => 'Select Page' diff --git a/src/Model/MenuSet.php b/src/Model/MenuSet.php index 5d8ddcb..5c36395 100644 --- a/src/Model/MenuSet.php +++ b/src/Model/MenuSet.php @@ -59,6 +59,10 @@ class MenuSet extends DataObject 'Items' ]; + private static $cascade_duplicates = [ + 'Items' + ]; + private static $defaults = [ 'IsTitleEnabled' => false, 'IsHighlightEnabled' => false,