form_field_access-1.0.0-alpha1/src/Controller/FormFieldAccessController.php

src/Controller/FormFieldAccessController.php
<?php

namespace Drupal\form_field_access\Controller;

use Drupal\Core\Entity\Controller\EntityController;
use Drupal\Core\Entity\EntityInterface;
use Drupal\Core\Routing\RouteMatchInterface;

/**
 * Provides the title callbacks for entities.
 */
class FormFieldAccessController extends EntityController {

  /**
   * {@inheritDoc}
   */
  public function editTitle(RouteMatchInterface $route_match, EntityInterface $_entity = NULL) {
    if ($entity = $this->doGetEntity($route_match, $_entity)) {
      return $this->t('Edit %label form field access', ['%label' => $entity->id()]);
    }
    return parent::editTitle($route_match, $_entity);
  }

}

Главная | Обратная связь

drupal hosting | друпал хостинг | it patrol .inc