Forum


21:29

07/03/2012

Solved.. ignore posting... just had to add a sorttype attribute.. duh...
Hi,
I have a grid that sorts perfect with the grid set to JSON mode. Thing is, the server calls an external API to populate the grid, so I only want to hit that external API once, and then let the client-side take over. So I used the simple grid setting loadonce: true, and then I tried the column sorting. It was all borked.
A quick inspection showed that on initial load, the data structure for each row is {cell:[] and id: foo} but once the loadonce setting kicked in, any attempts to sort the columns revealed each row reporting a completely different structure… eg)
- _id_: "39604792_162″
- current: 439
- handle: "<a href="https://dizzbuzz.com">Fizzbuzz</a>"
- id: 162
- minimum: 80
- price: "7.99″
- sku: "FizzBuzz"
where id has morphed to _id_ and the cell array contents were flattened out to straight up attributes… so now, all the sorting is pooched… none of the columns sort properly..
What's the secret sauce to flipping from a one time server load, to client-side sorting with this Grid… seems like I am encountering something rather odd here…
Any tips most appreciated…
Most Users Ever Online: 715
Currently Online:
56 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.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66