You are here

public function MysqlDate::__construct in Views Custom Table 8

Same name in this branch
  1. 8 src/Plugin/views/filter/MysqlDate.php \Drupal\view_custom_table\Plugin\views\filter\MysqlDate::__construct()
  2. 8 src/Plugin/views/field/MysqlDate.php \Drupal\view_custom_table\Plugin\views\field\MysqlDate::__construct()
Same name and namespace in other branches
  1. 9.0.x src/Plugin/views/field/MysqlDate.php \Drupal\view_custom_table\Plugin\views\field\MysqlDate::__construct()

Constructs a new Date object.

Parameters

array $configuration: A configuration array containing information about the plugin instance.

string $plugin_id: The plugin ID for the plugin instance.

mixed $plugin_definition: The plugin implementation definition.

\Drupal\Core\Datetime\DateFormatterInterface $date_formatter: The date formatter service.

\Drupal\Core\Entity\EntityStorageInterface $date_format_storage: The date format storage.

Overrides HandlerBase::__construct

File

src/Plugin/views/field/MysqlDate.php, line 49

Class

MysqlDate
A handler to provide a field that is completely custom by the administrator.

Namespace

Drupal\view_custom_table\Plugin\views\field

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, DateFormatterInterface $date_formatter, EntityStorageInterface $date_format_storage) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this->dateFormatter = $date_formatter;
  $this->dateFormatStorage = $date_format_storage;
}