You are here

protected function PageVariantContextsForm::getContextOperationsRouteInfo in Page Manager 8.4

Same name and namespace in other branches
  1. 8 page_manager_ui/src/Form/PageVariantContextsForm.php \Drupal\page_manager_ui\Form\PageVariantContextsForm::getContextOperationsRouteInfo()

Parameters

mixed $cached_values:

string $machine_name:

string $row:

Return value

array

Overrides ManageContext::getContextOperationsRouteInfo

1 call to PageVariantContextsForm::getContextOperationsRouteInfo()
PageVariantContextsForm::addContext in page_manager_ui/src/Form/PageVariantContextsForm.php
Override to add the variant id.

File

page_manager_ui/src/Form/PageVariantContextsForm.php, line 98

Class

PageVariantContextsForm

Namespace

Drupal\page_manager_ui\Form

Code

protected function getContextOperationsRouteInfo($cached_values, $machine_name, $row) {

  /** @var \Drupal\page_manager\PageVariantInterface $page_variant */
  $page_variant = $cached_values['page_variant'];
  return [
    'entity.page_variant.context',
    [
      'machine_name' => $machine_name,
      'variant_machine_name' => $page_variant
        ->id(),
      'context_id' => $row,
    ],
  ];
}