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
[jQGrid 4.4.1] Date formatter doesn't work properly
19/09/2012
19:46
Avatar
markos
Member
Members
Forum Posts: 4
Member Since:
19/09/2012
sp_UserOfflineSmall Offline

I had jquery-1.4.4.min.js, jquery-ui-1.8.6.custom.min.js and jQGrid 3.8.1 wit next colModel:

{name:'created', id:'created', editable:true, width: 420, formatter:'date', formatoptions: {srcformat: 'ISO8601Long', newformat: 'd.m.Y H:i:s'}}

Everything worked fine:

[Image Can Not Be Found]

until I updated scripts to jQGrid 4.4.1, jquery-1.8.1.min.js, jquery-ui-1.8.23.custom.min.js.

Fields became NaN.NaN.NaN NaN:NaN:NaN :

[Image Can Not Be Found]

When I change config parameter srcformat to 'u':

{name:'created', id:'created', editable:true, width: 420, formatter:'date', formatoptions: {srcformat: 'u', newformat: 'd.m.Y H:i:s'}}

it looks looks like this:

[Image Can Not Be Found]

What am I need to do to fix this problem?

21/09/2012
10:50
Avatar
markos
Member
Members
Forum Posts: 4
Member Since:
19/09/2012
sp_UserOfflineSmall Offline

I tried different versions.

It works fine on jqGrid 4.1.1 but on 4.3.2 doesn't.

21/09/2012
15:19
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

I will look at this. Thanks.

Regards

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.

24/09/2012
12:55
Avatar
markos
Member
Members
Forum Posts: 4
Member Since:
19/09/2012
sp_UserOfflineSmall Offline

4.2.0 doesn't work too 🙁

27/09/2012
15:05
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Just tested exactley with your settings and I do not see a problem.

The format ISO8601Long corresponds to =>Y-m-d H:i:s

This means that the grid expect exactley this format.

How look your response like,  where the date field is defined?

Regards

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.

28/09/2012
00:22
Avatar
markos
Member
Members
Forum Posts: 4
Member Since:
19/09/2012
sp_UserOfflineSmall Offline

Hello!

That date looks like this

created:1343136320634
28/09/2012
08:34
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Since ISO8601Long corresponds to =>Y-m-d H:i:s - did you think that your string correspond to the

source date formatting? I do not tink so.

Also I can not remember, but we support srcformat:u option since 4.2

Not sure, but you will need to divide your date to 1000.

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.

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
44 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