File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed
Component/Listing/Columns
view/base/web/js/grid/columns Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -105,7 +105,7 @@ public function prepare()
105
105
);
106
106
107
107
$ config ['storeLocale ' ] = $ this ->locale ;
108
- $ config ['dateData ' ] = [
108
+ $ config ['calendarConfig ' ] = [
109
109
'months ' => $ months ,
110
110
'monthsShort ' => $ monthsShort ,
111
111
];
Original file line number Diff line number Diff line change @@ -15,9 +15,9 @@ define([
15
15
16
16
return Column . extend ( {
17
17
defaults : {
18
- dateFormat : 'MMM d, YYYY h:mm:ss A'
18
+ dateFormat : 'MMM d, YYYY h:mm:ss A' ,
19
+ calendarConfig : [ ]
19
20
} ,
20
- dateData : [ ] ,
21
21
22
22
/**
23
23
* Overrides base method to normalize date format.
@@ -38,7 +38,9 @@ define([
38
38
* @returns {String } Formatted date.
39
39
*/
40
40
getLabel : function ( value , format ) {
41
- moment . locale ( this . storeLocale , { ...this . dateData } ) ;
41
+ if ( this . storeLocale !== undefined ) {
42
+ moment . locale ( this . storeLocale , { ...this . calendarConfig } ) ;
43
+ }
42
44
var date = moment ( this . _super ( ) ) ;
43
45
44
46
date = date . isValid ( ) && value [ this . index ] ?
You can’t perform that action at this time.
0 commit comments