DateFormatFormBase::__construct

public DateFormatFormBase::__construct(DateFormatterInterface $date_formatter, ConfigEntityStorageInterface $date_format_storage)

Constructs a new date format form.

Parameters

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

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

File

core/modules/system/src/Form/DateFormatFormBase.php, line 40

Class

DateFormatFormBase
Provides a base form for date formats.

Namespace

Drupal\system\Form

Code

1
2
3
4
5
6
public function __construct(DateFormatterInterface $date_formatter, ConfigEntityStorageInterface $date_format_storage) {
  $date = new DrupalDateTime();
 
  $this->dateFormatter = $date_formatter;
  $this->dateFormatStorage = $date_format_storage;
}
doc_Drupal
2025-01-10 15:47:30
Comments
Leave a Comment

Please login to continue.