Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ExtJs Date format in Grid panel

Tags:

extjs

How to display date in ExtJS Gridpanel column (Date with time )

Please provide syntax.

like image 883
MNR Avatar asked May 24 '26 07:05

MNR


1 Answers

ExtJs provides a separate class to handle Dates and it its formatting. Have a look at Date class. There is enough examples and explanation on how to format a given date or time.

To render dates in grids according to your desired formatting you will have to use a renderer method. In you date column configuration you need to added renderer method as follows:

renderer: function(date){
    // process you date to your required format and return it
}

Important point: The return value from the renderer method is displayed onto the column.So, make sure you return your formatted date or time.

like image 70
Abdel Raoof Olakara Avatar answered May 27 '26 13:05

Abdel Raoof Olakara



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!