コード例 #1
0
ファイル: NodeMatcher.php プロジェクト: eloiv/botafoc.cat
  /**
   * {@inheritdoc}
   */
  public function getSummary() {
    $summery = parent::getSummary();

    $summery[] = $this->t('Include unpublished: @include_unpublished', [
      '@include_unpublished' => $this->configuration['include_unpublished'] ? $this->t('Yes') : $this->t('No'),
    ]);

    return $summery;
  }
コード例 #2
0
ファイル: UserMatcher.php プロジェクト: eloiv/botafoc.cat
  /**
   * {@inheritdoc}
   */
  public function getSummary() {
    $summery = parent::getSummary();

    $roles = !empty($this->configuration['roles']) ? $this->configuration['roles'] : ['None'];
    $summery[] = $this->t('Role filter: @role_filter', [
      '@role_filter' => implode(', ', $roles),
    ]);

    $summery[] = $this->t('Include blocked users: @include_blocked', [
      '@include_blocked' => $this->configuration['include_blocked'] ? $this->t('Yes') : $this->t('No'),
    ]);

    return $summery;
  }
コード例 #3
0
ファイル: FileMatcher.php プロジェクト: eloiv/botafoc.cat
  /**
   * {@inheritdoc}
   */
  public function getSummary() {
    $summery = parent::getSummary();

    $summery[] = $this->t('Show image dimensions: @show_image_dimensions', [
      '@show_image_dimensions' => $this->configuration['images']['show_dimensions'] ? $this->t('Yes') : $this->t('No'),
    ]);

    $summery[] = $this->t('Show image thumbnail: @show_image_thumbnail', [
      '@show_image_thumbnail' => $this->configuration['images']['show_thumbnail'] ? $this->t('Yes') : $this->t('No'),
    ]);

    if ($this->moduleHandler->moduleExists('image') && $this->configuration['images']['show_thumbnail']) {
      $image_style = ImageStyle::load($this->configuration['images']['thumbnail_image_style']);
        if (!is_null($image_style)) {
          $summery[] = $this->t('Thumbnail style: @thumbnail_style', [
          '@thumbnail_style' =>  $image_style->label(),
        ]);
      }
    }

    return $summery;
  }