diff --git a/app/Resources/static/themes/material/index.js b/app/Resources/static/themes/material/index.js index e808d75c2..da055e80a 100755 --- a/app/Resources/static/themes/material/index.js +++ b/app/Resources/static/themes/material/index.js @@ -57,9 +57,9 @@ $(document).ready(() => { $('.datepicker').pickadate({ selectMonths: true, selectYears: 15, - formatSubmit: 'dd/mm/yyyy', - hiddenName: true, - format: 'dd/mm/yyyy', + formatSubmit: 'yyyy-mm-dd', + hiddenName: false, + format: 'yyyy-mm-dd', container: 'body', }); diff --git a/src/Wallabag/CoreBundle/Entity/Entry.php b/src/Wallabag/CoreBundle/Entity/Entry.php index 190457983..0e19a0c20 100644 --- a/src/Wallabag/CoreBundle/Entity/Entry.php +++ b/src/Wallabag/CoreBundle/Entity/Entry.php @@ -552,7 +552,7 @@ class Entry * * @return Entry */ - public function setCreatedAt(\DateTime $createdAt) + public function setCreatedAt(\DateTimeInterface $createdAt) { $this->createdAt = $createdAt; diff --git a/src/Wallabag/CoreBundle/Form/Type/EntryFilterType.php b/src/Wallabag/CoreBundle/Form/Type/EntryFilterType.php index 17070c598..61ad99a86 100644 --- a/src/Wallabag/CoreBundle/Form/Type/EntryFilterType.php +++ b/src/Wallabag/CoreBundle/Form/Type/EntryFilterType.php @@ -73,23 +73,22 @@ class EntryFilterType extends AbstractType 'label' => 'entry.filters.reading_time.label', ]) ->add('createdAt', DateRangeFilterType::class, [ - 'left_date_options' => [ - 'attr' => [ - 'placeholder' => 'dd/mm/yyyy', - ], - 'format' => 'dd/MM/yyyy', - 'widget' => 'single_text', + 'left_date_options' => [ + 'attr' => [ + 'placeholder' => 'yyyy-mm-dd', ], - 'right_date_options' => [ - 'attr' => [ - 'placeholder' => 'dd/mm/yyyy', - ], - 'format' => 'dd/MM/yyyy', - 'widget' => 'single_text', + 'format' => 'yyyy-MM-dd', + 'widget' => 'single_text', + ], + 'right_date_options' => [ + 'attr' => [ + 'placeholder' => 'yyyy-mm-dd', ], - 'label' => 'entry.filters.created_at.label', - ] - ) + 'format' => 'yyyy-MM-dd', + 'widget' => 'single_text', + ], + 'label' => 'entry.filters.created_at.label', + ]) ->add('domainName', TextFilterType::class, [ 'apply_filter' => function (QueryInterface $filterQuery, $field, $values) { $value = $values['value']; diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig index 0c21dc5dd..0cd00cfdf 100644 --- a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig +++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig @@ -39,7 +39,7 @@