Commit 594b47df by Frédéric

Date format

parent 657968c8
......@@ -35,7 +35,7 @@ class ResaType extends AbstractType
[
'widget' => 'single_text',
'label' => false,
'format' => 'dd-MM-yyyy',
'format' => 'd/m/Y',
'required' => false,
])
->add(
......@@ -44,7 +44,7 @@ class ResaType extends AbstractType
[
'widget' => 'single_text',
'label' => false,
'format' => 'dd-MM-yyyy',
'format' => 'd/m/Y',
'required' => false
])
->add(
......
......@@ -31,7 +31,7 @@ trait GetterSetterTrait
public function setStartDate($startDate)
{
$this->startDate = $startDate;
$this->startDate = (new \DateTime($startDate))->format('Y-m-d');
return $this;
}
......@@ -49,7 +49,7 @@ trait GetterSetterTrait
*/
public function setEndDate($endDate)
{
$this->endDate = $endDate;
$this->endDate = (new \DateTime($endDate))->format('Y-m-d');
return $this;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment