diff --git a/core/modules/contact/contact.module b/core/modules/contact/contact.module index 9ea6965..718a128 100644 --- a/core/modules/contact/contact.module +++ b/core/modules/contact/contact.module @@ -75,7 +75,6 @@ function contact_menu() { $items['admin/structure/contact/manage/%contact_category/edit'] = array( 'title' => 'Edit', 'type' => MENU_DEFAULT_LOCAL_TASK, - 'route_name' => 'contact_category_edit_tab', ); $items['admin/structure/contact/manage/%contact_category/delete'] = array( 'title' => 'Delete', diff --git a/core/modules/contact/contact.routing.yml b/core/modules/contact/contact.routing.yml index c5efe48..4cbfff2 100644 --- a/core/modules/contact/contact.routing.yml +++ b/core/modules/contact/contact.routing.yml @@ -16,20 +16,13 @@ contact_category_list: contact_category_add: pattern: '/admin/structure/contact/add' defaults: - _entity_form: contact_category.default + _entity_form: contact_category.add requirements: _permission: 'administer contact forms' contact_category_edit: pattern: '/admin/structure/contact/manage/{contact_category}' defaults: - _entity_form: contact_category.default - requirements: - _permission: 'administer contact forms' - -contact_category_edit_tab: - pattern: '/admin/structure/contact/manage/{contact_category}/edit' - defaults: - _entity_form: contact_category.default + _entity_form: contact_category.edit requirements: _permission: 'administer contact forms' diff --git a/core/modules/contact/lib/Drupal/contact/Plugin/Core/Entity/Category.php b/core/modules/contact/lib/Drupal/contact/Plugin/Core/Entity/Category.php index 7e068da..a224d1a 100644 --- a/core/modules/contact/lib/Drupal/contact/Plugin/Core/Entity/Category.php +++ b/core/modules/contact/lib/Drupal/contact/Plugin/Core/Entity/Category.php @@ -23,7 +23,8 @@ * "storage" = "Drupal\contact\CategoryStorageController", * "list" = "Drupal\contact\CategoryListController", * "form" = { - * "default" = "Drupal\contact\CategoryFormController" + * "add" = "Drupal\contact\CategoryFormController", + * "edit" = "Drupal\contact\CategoryFormController" * } * }, * uri_callback = "contact_category_uri", diff --git a/core/modules/contact/lib/Drupal/contact/Tests/ContactSitewideTest.php b/core/modules/contact/lib/Drupal/contact/Tests/ContactSitewideTest.php index 1ea830b..9ae74b9 100644 --- a/core/modules/contact/lib/Drupal/contact/Tests/ContactSitewideTest.php +++ b/core/modules/contact/lib/Drupal/contact/Tests/ContactSitewideTest.php @@ -276,7 +276,7 @@ function updateCategory($id, $label, $recipients, $reply, $selected) { $edit['recipients'] = $recipients; $edit['reply'] = $reply; $edit['selected'] = ($selected ? TRUE : FALSE); - $this->drupalPost("admin/structure/contact/manage/$id/edit", $edit, t('Save')); + $this->drupalPost("admin/structure/contact/manage/$id", $edit, t('Save')); } /**