You are here

protected function DateRecurDefaultFormatter::showNextOptions in Recurring Dates Field 8

1 call to DateRecurDefaultFormatter::showNextOptions()
DateRecurDefaultFormatter::settingsForm in src/Plugin/Field/FieldFormatter/DateRecurDefaultFormatter.php
Returns a form to configure settings for the formatter.

File

src/Plugin/Field/FieldFormatter/DateRecurDefaultFormatter.php, line 41

Class

DateRecurDefaultFormatter
Plugin implementation of the 'date_recur_default_formatter' formatter.

Namespace

Drupal\date_recur\Plugin\Field\FieldFormatter

Code

protected function showNextOptions() {

  // This cannot work for infinite fields.
  // $next_options[-1] = $this->t('All');
  $next_options[0] = $this
    ->t('None');
  for ($i = 1; $i <= 20; $i++) {
    $next_options[$i] = $i;
  }
  return $next_options;
}