{% extends "forms/field.html.twig" %} {% set value = (value is null ? field.default : value) %} {% set default_php_dateformat = admin.guessDateFormat(value) %} {% set php_dateformat = field.format ?: (form ? form.object.dateformat : admin.page.dateformat) ?: config.system.pages.dateformat.default ?: default_php_dateformat %} {% set js_dateformat = admin.dateformatToMomentJS(php_dateformat) %} {% set value = (value is null ? value : value|date(php_dateformat)) %} {% block input %}
{% set input_value = value is iterable ? value|join(',') : value|string %}
{% endblock %}