Skip to content

Instantly share code, notes, and snippets.

@derhansen
Created January 24, 2016 17:21
Show Gist options
  • Select an option

  • Save derhansen/d60ff75c1e167dc2a6a0 to your computer and use it in GitHub Desktop.

Select an option

Save derhansen/d60ff75c1e167dc2a6a0 to your computer and use it in GitHub Desktop.
Example on how to set the date format of a TYPO3 DatetimeConverter
public function initializeCreateAction()
{
$this->arguments->getArgument('mymodel')
->getPropertyMappingConfiguration()
->forProperty('mydate')
->setTypeConverterOption(
'TYPO3\\CMS\\Extbase\\Property\\TypeConverter\\DateTimeConverter',
DateTimeConverter::CONFIGURATION_DATE_FORMAT,
'd.m.Y'
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment