ercore-8.x-1.20/modules/ercore_core/src/Plugin/Block/ERCoreGrantBlock.php

modules/ercore_core/src/Plugin/Block/ERCoreGrantBlock.php
<?php

namespace Drupal\ercore_core\Plugin\Block;

use Drupal\Core\Block\BlockBase;
use Drupal\Core\Form\FormStateInterface;

/**
 * Provides a 'ERCoreGrantBlock' block.
 *
 * @Block(
 *  id = "ercore_grant_block",
 *  admin_label = @Translation("ERCore Grant Block"),
 * )
 */
class ERCoreGrantBlock extends BlockBase {

  /**
   * {@inheritdoc}
   */
  public function build() {
    $build = [];
    $grant = \Drupal::config('ercore.settings')->get('ercore_epscor_number');
    $build['ercore_grant_block_ercore_grant_number']['#markup'] = '<p class="grant">This material is based upon work supported by the National Science Foundation under Cooperative Agreement Award <em class="grant-number">' . $grant . '</em>.<br />
Any opinions, findings, and conclusions or recommendations expressed in this material are those of the author(s) and do not necessarily reflect the views of the National Science Foundation.</p>';

    return $build;
  }

}

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

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