You are here

DebugController.php in RNG - Events and Registrations 8.2

File

rng_debug/src/Controller/DebugController.php
View source
<?php

namespace Drupal\rng_debug\Controller;

use Drupal\Core\Controller\ControllerBase;
use Drupal\Core\DependencyInjection\ContainerInjectionInterface;
use Drupal\Core\Entity\EntityInterface;

/**
 * Controller for rng_debug.
 */
class DebugController extends ControllerBase implements ContainerInjectionInterface {

  /**
   * Provides a list of rng rules for an event.
   *
   * @param \Drupal\Core\Entity\EntityInterface $rng_event
   *   The RNG event.
   *
   * @return array
   *   A render array.
   */
  public function listing(EntityInterface $rng_event = NULL) {
    return $this
      ->entityTypeManager()
      ->getListBuilder('rng_rule')
      ->render($rng_event);
  }

}

Classes

Namesort descending Description
DebugController Controller for rng_debug.