Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
Ordering numbers at client side
14/08/2008
06:15
Avatar
josepk
Member
Members
Forum Posts: 44
Member Since:
16/06/2008
sp_UserOfflineSmall Offline

Hi,

I have a grid that has a lot of numbers with decimal point:

8.692,22    
8.626,41    
772,82    
77,15    
760,66  

But ordering with these number not work well, it appears ordering as

String.

Is there someway to ordering these numbers at client side?

thanks.

Josep Escofet

14/08/2008
13:48
Avatar
son122
Member
Members
Forum Posts: 32
Member Since:
07/07/2008
sp_UserOfflineSmall Offline

As far as I know, all sorting is done on the server side.  I think you could try this on the client side.

colModel:[

{name:'someNum', index:'someNum', sorttype:"float"},

....]

19/08/2008
02:55
Avatar
josepk
Member
Members
Forum Posts: 44
Member Since:
16/06/2008
sp_UserOfflineSmall Offline

Hi,

I have tryed it with float, and if the numbers to sort hasnt any format

the sort is done correct, but If the numbers has any format,

for example in Europe the format for numbers in Spain and France

are not the same, in Spain and Deuschland are the same, then

the sort is not done correctly, the sort should be look for the

country format of the numbers This function fort sort to client

side is not internationalized.

Does is it correct?

thanks.

Josep Escofet

19/08/2008
04:44
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello Josep,

Yes you are right. There is a need to add new proptery something

like datefmt - I mean numberfmt , or which is easer to set property

where to tell what is the decimal point.

Regards

Tony

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

19/08/2008
06:30
Avatar
josepk
Member
Members
Forum Posts: 44
Member Since:
16/06/2008
sp_UserOfflineSmall Offline

I think it would be better add the locale as in java.

The format is determined for the locale string which is different

for every country (ES, FR, US....).

It could be interesting to add an extra parameter indicating the

mask (#,###.00) or (dd/mm/yy) for a non country specialized

format sort.

Thanks for all.

At the momment I have done the sort in the server, it is a little

slow but it works well.

Josep Escofet

19/08/2008
11:41
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

I do not think that using locale is a good idea, but I like the idea of

mask(#,###.00).

Regards

Tony

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

27/10/2008
05:55
Avatar
pruss
Seefeld, Germany
New Member
Members
Forum Posts: 2
Member Since:
24/10/2008
sp_UserOfflineSmall Offline

First of all: thank you for that great plugin!
Q: Is anybody implementing numberfmt already?

Regs. Peter.

29/10/2008
02:40
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

Not yet, but will look at this.

Regards

Tony

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

03/09/2010
18:37
Avatar
Neb Okla
Columbus, OH, USA
Member
Members
Forum Posts: 10
Member Since:
03/09/2010
sp_UserOfflineSmall Offline

josepk said:

But ordering with these number not work well, it appears ordering as


Whenever anyone talks about ordering numbers, I tend to think about "the special of the day".



Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
58 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information