protected function PanelsIPEPageController::loadPanelsDisplay in Panels 8.3
Same name and namespace in other branches
- 8.4 panels_ipe/src/Controller/PanelsIPEPageController.php \Drupal\panels_ipe\Controller\PanelsIPEPageController::loadPanelsDisplay()
Takes the current Page Variant and returns a possibly modified Page Variant based on what's in TempStore for this user.
Parameters
string $panels_storage_type: The Panels storage plugin which holds the Panels display.
string $panels_storage_id: The id within the Panels storage plugin for this Panels display.
Return value
\Drupal\panels\Plugin\DisplayVariant\PanelsDisplayVariant|NULL
9 calls to PanelsIPEPageController::loadPanelsDisplay()
- PanelsIPEPageController::cancel in panels_ipe/
src/ Controller/ PanelsIPEPageController.php - Removes any temporary changes to the variant.
- PanelsIPEPageController::getBlock in panels_ipe/
src/ Controller/ PanelsIPEPageController.php - Gets a single Block from the current Panels Display. Uses TempStore.
- PanelsIPEPageController::getBlockPluginForm in panels_ipe/
src/ Controller/ PanelsIPEPageController.php - Drupal AJAX compatible route for rendering a given Block Plugin's form.
- PanelsIPEPageController::getBlockPlugins in panels_ipe/
src/ Controller/ PanelsIPEPageController.php - Gets a list of Block Plugins from the server.
- PanelsIPEPageController::getLayoutForm in panels_ipe/
src/ Controller/ PanelsIPEPageController.php - Gets a layout configuration form for the requested layout.
File
- panels_ipe/
src/ Controller/ PanelsIPEPageController.php, line 119
Class
- PanelsIPEPageController
- Contains all JSON endpoints required for Panels IPE + Page Manager.
Namespace
Drupal\panels_ipe\ControllerCode
protected function loadPanelsDisplay($panels_storage_type, $panels_storage_id) {
/** @var \Drupal\panels\Plugin\DisplayVariant\PanelsDisplayVariant $panels_display */
$panels_display = $this->panelsStorage
->load($panels_storage_type, $panels_storage_id);
// If a temporary configuration for this variant exists, use it.
if ($variant_config = $this->tempStore
->get($panels_display
->id())) {
$panels_display
->setConfiguration($variant_config);
}
return $panels_display;
}