Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
novicell/dds / src / Controller / UtilitiesAdminController.php
Size: Mime:
<?php


namespace Drupal\dds\Controller;


use Drupal\system\Controller\SystemController;

class UtilitiesAdminController extends SystemController {

  public function utilitiesPage() {
    $block_contents = $this->systemManager->getBlockContents();

    $build = [];

    // If the block has #markup array key, it means it is showing the message
    // about not having any items.
    // As we don't want the list displayed if there are no items, we handle
    // it ourselves.
    if (!isset($block_contents['#markup'])) {
      $build['pages'] = [
        '#type' => 'fieldset',
        '#open' => TRUE,
        '#title' => $this->t('Utility specific pages'),
        'pages' => $block_contents
      ];
    }

    $form = \Drupal::formBuilder()->getForm('Drupal\dds\Form\EnableUtilitiesForm');

    $build['form'] = $form;

    return $build;
  }

}