Skip to content

Commit 793b420

Browse files
MC-15524: Unwanted Created/Last Updated fieltes are being displayed.
- Fix filter format data.
1 parent 0421665 commit 793b420

File tree

1 file changed

+11
-9
lines changed
  • app/code/Magento/Ui/Component/Listing/Columns

1 file changed

+11
-9
lines changed

app/code/Magento/Ui/Component/Listing/Columns/Date.php

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -55,17 +55,19 @@ public function __construct(
5555
public function prepare()
5656
{
5757
$config = $this->getData('config');
58-
$config['filter'] = [
59-
'filterType' => 'dateRange',
60-
'templates' => [
61-
'date' => [
62-
'options' => [
63-
'dateFormat' => $this->timezone->getDateFormatWithLongYear()
58+
if (isset($config['filter'])) {
59+
$config['filter'] = [
60+
'filterType' => 'dateRange',
61+
'templates' => [
62+
'date' => [
63+
'options' => [
64+
'dateFormat' => $config['dateFormat'] ?? $this->timezone->getDateFormatWithLongYear()
65+
]
6466
]
6567
]
66-
]
67-
];
68-
$this->setData('config', $config);
68+
];
69+
$this->setData('config', $config);
70+
}
6971

7072
parent::prepare();
7173
}

0 commit comments

Comments
 (0)