How can I format numbers in viewrecord on a jqgrid pager?

When there are a large number of pages, the number format in the pager is "11,223", but I would like it to be "11,223"

View 11,026 - 11,031 of 11,031

it should be

View 11,026 - 11,031 of 11,031

I was looking for documentation for JQGrid but could not find a way to do this.

+6
formatting number-formatting jqgrid
source share
1 answer

You can set

$.jgrid.formatter.integer.thousandsSeparator=','; 

or modify the grid.locale-en.js file (or another locale file that you are using), line 90

 integer : {thousandsSeparator: " ", defaultValue: '0'}, 

(in the minimized version, you should look for integer:{thousandsSeparator:" " ) in the string

 integer : {thousandsSeparator: ",", defaultValue: '0'}, 

By the way, you can call set also $.jgrid.formatter.integer.thousandsSeparator='' , then it will not be a thousandth separator: instead of "11 223" you will have "11223" and not "11,223".

+5
source share

All Articles