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
date.split is not a function
29/10/2009
13:27
Avatar
Jim P
Member
Members
Forum Posts: 102
Member Since:
29/01/2009
sp_UserOfflineSmall Offline

Tony,

I get thiis error in firefox:

date.split is not a function

and the grid wont' load.  It looks like one of the js files isn't getting loaded but I've checked every one and the links are in the code.  I also don't get and errors on files not being loaded.

We are going live on Monday and I need to get this fixed.

please help if you can.

Thanks,  Jim

29/10/2009
14:02
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Could you please publish the code, or send me a link to the problem?

It seems that you set sortype:date but nothing is passed to the date. Will look to the code tomorrow

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.

29/10/2009
14:16
Avatar
Jim P
Member
Members
Forum Posts: 102
Member Since:
29/01/2009
sp_UserOfflineSmall Offline

Thanks Tony,  - Jim

datatype: 'json', //We specify that the datatype we will be using will be JSON
    colNames:['Case ID','Site ID','Reported Problem','Closing Summary','Status','Priority','Contact','Created','Sort Date','Closed','Sort Closed','Alt Site ID','Cust Ref No','Acct Name','Email'], //Column Names
    //The Column Model to define the data. Note you can make columns non sortable, specify width, alignment, etc.
    colModel :[
        {name:'id_number',index:'id_number', align:"center", search:true, stype:"text", width: 70},
     {name:'site_id',index:'site_id',  align:"center",search:true,stype:"text", width: 60},
     {name:'title',index:'title',  align:"left", width: 100,search:true, stype:"text"},
     {name:'closing_summary',index:'closing_summary',  align:"left", width: 100,search:true, stype:"text"},     
       //{name:'condition',index:'condition', hidden:"false", search:false, stype:"text", width: 54},
     {name:'status',index:'status',  align:"center",search:true, stype:"text", width: 60},
     {name:'priority',index:'priority',  align:"center",search:true, stype:"text", width: 60},
     {name:'last_name',index:'last_name',  align:"center",search:true, stype:"text", width: 60},
        {name:'creation_time',index:'creation_time', align:"center",search:true, width: 90, formatter:'date', formatoptions:{srcformat: 'm/d/Y H:i:s',newformat: '<cfoutput>#session.myGridDateFormat#</cfoutput>'}
     }, // m/d/Y H:i:s
      {name:'sort_creation_time',index:'sort_creation_time', align:"center", hidden: true},
        {name:'case_close_date',index:'case_close_date', align:"center", width: 90, formatter:'date', formatoptions:{srcformat: 'm/d/Y H:i:s',newformat: '<cfoutput>#session.myGridDateFormat#</cfoutput>'}
     }, // m/d/Y H:i:s
      {name:'sort_case_close_date',index:'sort_case_close_date', align:"center", hidden: true},     
     {name:'alt_site_id',index:'alt_site_id',  align:"center", stype:"text", width: 60},
     {name:'x_cust_ref_no',index:'x_cust_ref_no', search:true, stype:"text", width: 60},
     {name:'name',index:'name', search:false, sortable:false, width:60},
     {name:'e_mail',index:'e_mail', search:false, sortable:false, width: 80, formatter:'email'}     ], 

29/10/2009
14:20
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Seems like you pass to the formatter date not a string, but something else. Also we need to check this into the code.

Please see what is returned from server for the fields where you have date formatter

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.

29/10/2009
15:09
Avatar
Jim P
Member
Members
Forum Posts: 102
Member Since:
29/01/2009
sp_UserOfflineSmall Offline

This is my json data:

{"ROWS":[[3609385.0,"Y300006","PW =junior10 DT pos UPS is not holding power","per yums hd issued PR840795","Closed","Closed","PR","Y300006","10\\/25\\/2009 13:32:29",2.0091025133229E13,"10\\/25\\/2009 13:34:08",2.0091025133408E13,"Y300006",4.3039414E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3603770.0,"X527045","PW =junior10 BOH UPS 700 is not holding a charge, please send replacement.","per yuyms \\nissued pr839396","Closed","Closed","PR","X527045","10\\/19\\/2009 17:14:23",2.0091019171423E13,"10\\/19\\/2009 17:16:37",2.0091019171637E13,"X527045",4.3038506E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3613454.0,"X527045","PW =junior10 The new BOH UPS that was sent last week will not longer turn on wh","issued pr842522\\n","Closed","Closed","PR","X527045","10\\/29\\/2009 15:02:36",2.0091029150236E13,"10\\/29\\/2009 15:10:05",2.0091029151005E13,"X527045",4.3040058E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3587266.0,"X527089","PW =junior10 Printer keeps jamming up papers.  Please send replacement","issued pr835264","Closed","Closed","PR","X527089","10\\/02\\/2009 17:36:00",2.00910021736E13,"10\\/02\\/2009 17:37:22",2.0091002173722E13,"X527089",4.3036005E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3601068.0,"X527089","PW =junior10 Lexmark has service error, replaced the PC kit and reset the count","per yums\\/tbhd\\nissued pr838834","Closed","Closed","PR","X527089","10\\/16\\/2009 13:54:17",2.0091016135417E13,"10\\/16\\/2009 13:55:16",2.0091016135516E13,"X527089",4.3038095E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3601322.0,"X527089","PW =junior10 FC POS 3 having calibration issues","per yum,\\nissued pr838954","Closed","Closed","PR","X527089","10\\/16\\/2009 17:08:17",2.0091016170817E13,"10\\/16\\/2009 17:10:06",2.0091016171006E13,"X527089",4.3038164E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3602835.0,"X527089","PW =junior10 Bump bar 5 has a damaged button and they can't bump orders with it","per yums\\nissued pr839091","Closed","Closed","PR","X527089","10\\/18\\/2009 21:10:32",2.0091018211032E13,"10\\/18\\/2009 21:16:18",2.0091018211618E13,"X527089",4.303839E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3596440.0,"Y314014","PW =junior10 FC POS3, drawer won't close.","per yums hd issued PR837234","Closed","Closed","PR","Y314014","10\\/12\\/2009 12:00:12",2.0091012120012E13,"10\\/12\\/2009 12:01:30",2.009101212013E13,"Y314014",4.3037394E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3595115.0,"Y300009","PW =junior10 DT creditcard swip fell off","per yums\\/tbhd\\nissued pr837034","Closed","Closed","PR","Y300009","10\\/10\\/2009 16:58:09",2.0091010165809E13,"10\\/10\\/2009 16:58:50",2.009101016585E13,"Y300009",4.3037221E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3601012.0,"Y052042","PW =junior10 DT POS UPS not passing power","per yums\\/tbhd\\nissued pr838823","Closed","Closed","PR","Y052042","10\\/16\\/2009 13:12:18",2.0091016131218E13,"10\\/16\\/2009 13:13:41",2.0091016131341E13,"Y052042",4.3038086E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3592774.0,"W710101","PW =junior10 MWS ptr. keeps jamming in back, just replaced pc kit, confirmed it","per yums hd issued PR836458-","Closed","Closed","PR","W710101","10\\/08\\/2009 11:58:06",2.0091008115806E13,"10\\/08\\/2009 11:59:21",2.0091008115921E13,"W710101",4.3036853E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3593289.0,"X610036","PW =junior10 UPS is beeping and won't reset.","per yum,\\nissued pr836691","Closed","Closed","PR","X610036","10\\/08\\/2009 20:54:07",2.0091008205407E13,"10\\/08\\/2009 20:57:42",2.0091008205742E13,"X610036",4.3036963E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3607078.0,"W710264","PW =junior10 DT POS2 will not hold calibration, troubleshot, please replace.","per yum,\\nissued pr840370","Closed","Closed","PR","W710264","10\\/22\\/2009 17:20:26",2.0091022172026E13,"10\\/22\\/2009 17:34:16",2.0091022173416E13,"W710264",4.303908E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3611330.0,"W710264","PW =junior10 dt term 2 card swipe not working","issued pr841391","Closed","Closed","PR","W710264","10\\/27\\/2009 14:16:35",2.0091027141635E13,"10\\/27\\/2009 14:19:24",2.0091027141924E13,"W710264",4.303971E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"],[3590795.0,"Y343115","PW =junior10 DT POS #2 will not power on","per yum,\\nissued pr835900","Closed","Closed","PR","Y343115","10\\/06\\/2009 16:32:05",2.0091006163205E13,"10\\/06\\/2009 16:32:51",2.0091006163251E13,"Y343115",4.3036557E7,"KFC (YUM BRANDS)","Melissa.Johnson@yum.com"]],"PAGE":1.0,"TOTAL":23.0,"USERDATA":{"MSG":"Retreived 331 Records.","TYPE":"Success"},"RECORDS":331}
29/10/2009
15:30
Avatar
Jim P
Member
Members
Forum Posts: 102
Member Since:
29/01/2009
sp_UserOfflineSmall Offline

Tony,

I cut the grid fields in half (removing my date fields) and now I get this error:

cm is undefined
../PTI/Parview/js3-5/jquery.jqGrid.min.js
Line 10

It acts like I'm missing some files but I've double checked.

Jim

29/10/2009
15:30
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Will try to test this tomorrow

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.

29/10/2009
15:33
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

check your json reader and if the number of fields from server is equal of those in colmodel.

Also will be interested on xmlReader too

Sorry I mean jsonReader

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.

30/10/2009
06:26
Avatar
Jim P
Member
Members
Forum Posts: 102
Member Since:
29/01/2009
sp_UserOfflineSmall Offline

Tony,

The number of fields are correct.  The grid was working fine on my development machine, but when I moved everything to the production machine it starting getting the error.  That's why I thought that one of the js or css files was missing. 

Which files handle the formatter?  

Jim 

30/10/2009
06:48
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Not sure if this is true. In your post you have 15 columns in colModel, but 16 fields in the response. One column is commented.

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.

30/10/2009
06:51
Avatar
Jim P
Member
Members
Forum Posts: 102
Member Since:
29/01/2009
sp_UserOfflineSmall Offline

I'll check again.

30/10/2009
08:16
Avatar
Jim P
Member
Members
Forum Posts: 102
Member Since:
29/01/2009
sp_UserOfflineSmall Offline

I counted 15:  Here's the 1st 2 rows of data.

{"ROWS":[
[3609385.0,
"Y300006",
"PW =junior10 DT pos UPS is not holding power",
"per yums hd issued PR840795",
"Closed",
"PR",
"Y300006",
"10\\/25\\/2009 13:32:29",
2.0091025133229E13,
"10\\/25\\/2009 13:34:08",
2.0091025133408E13,
"Y300006",
4.3039414E7,
"KFC (YUM BRANDS)",
"Melissa.Johnson@yum.com"],
[3603770.0,
"X527045",
"PW =junior10 BOH UPS 700 is not holding a charge, please send replacement.",
"per yuyms \\nissued pr839396",
"Closed",
"PR",
"X527045",
"10\\/19\\/2009 17:14:23",
2.0091019171423E13,
"10\\/19\\/2009 17:16:37",
2.0091019171637E13,
"X527045",
4.3038506E7,
"KFC (YUM BRANDS)",
"Melissa.Johnson@yum.com"],

30/10/2009
08:25
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Check your previous post - there is one tag "Closed" more (just copy and paste it and see

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.

30/10/2009
08:45
Avatar
Jim P
Member
Members
Forum Posts: 102
Member Since:
29/01/2009
sp_UserOfflineSmall Offline

Tony,

The grid started working!

Thank you for responding so quickly to my questions.

And thank you for the grid.

Jim

02/11/2009
15:10
Avatar
Jim P
Member
Members
Forum Posts: 102
Member Since:
29/01/2009
sp_UserOfflineSmall Offline

Tony,

I want to thank you immensely for your grid.  We went live today on our new version of our Customer Portal which employs 20+ grids to present shipping, purchasing, invoicing and servicing data. 

The grid are working well.

Thanks again,

Jim

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

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