function RequiredContext::getOperationsRouteInfo

Same name in other branches
  1. 8.x-3.x src/Form/RequiredContext.php \Drupal\ctools\Form\RequiredContext::getOperationsRouteInfo()

Document the route name and parameters for edit/delete context operations.

The route name returned from this method is used as a "base" to which ".edit" and ".delete" are appended in the getOperations() method. Subclassing '\Drupal\ctools\Form\ContextConfigure' and '\Drupal\ctools\Form\RequiredContextDelete' should set you up for using this approach quite seamlessly.

Parameters

mixed $cached_values: The Cached Values.

string $machine_name: The form machine name.

string $row: The form row to operate on.

Return value

array In the format of return ['route.base.name', ['machine_name' => $machine_name, 'context' => $row]];

2 calls to RequiredContext::getOperationsRouteInfo()
RequiredContext::renderContexts in src/Form/RequiredContext.php
Render The contexts in the form.
RequiredContext::submitForm in src/Form/RequiredContext.php
Form submission handler.

File

src/Form/RequiredContext.php, line 243

Class

RequiredContext
Required Context Form.

Namespace

Drupal\ctools\Form

Code

protected abstract function getOperationsRouteInfo(mixed $cached_values, string $machine_name, string $row);