public function ViewUI::duplicateDisplayAsType in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/views_ui/src/ViewUI.php \Drupal\views_ui\ViewUI::duplicateDisplayAsType()
Duplicates an existing display into a new display type.
For example clone to display a page display as a block display.
Parameters
string $old_display_id: The origin of the duplicated display.
string $new_display_type: The display type of the new display.
Return value
string The display ID of the new display.
Overrides ViewEntityInterface::duplicateDisplayAsType
File
- core/
modules/ views_ui/ src/ ViewUI.php, line 1180 - Contains \Drupal\views_ui\ViewUI.
Class
- ViewUI
- Stores UI related temporary settings.
Namespace
Drupal\views_uiCode
public function duplicateDisplayAsType($old_display_id, $new_display_type) {
return $this->storage
->duplicateDisplayAsType($old_display_id, $new_display_type);
}