You are here

public function DashboardSectionStorage::getRedirectUrl in Dashboards with Layout Builder 8

Same name and namespace in other branches
  1. 2.0.x src/Plugin/SectionStorage/DashboardSectionStorage.php \Drupal\dashboards\Plugin\SectionStorage\DashboardSectionStorage::getRedirectUrl()

Gets the URL used when redirecting away from the Layout Builder UI.

Return value

\Drupal\Core\Url The URL object.

Overrides SectionStorageInterface::getRedirectUrl

File

src/Plugin/SectionStorage/DashboardSectionStorage.php, line 154

Class

DashboardSectionStorage
Dashboard section storage.

Namespace

Drupal\dashboards\Plugin\SectionStorage

Code

public function getRedirectUrl() {
  return Url::fromRoute('entity.dashboard.canonical', [
    'dashboard' => $this
      ->getDashboard()
      ->id(),
  ]);
}