stoem
1 Mar 2012, 12:45 PM
I'm referring to Jason Johnston's recent screencast about working with data in Sencha Designer.
http://vimeo.com/37561290
Noob alert: I'm a Flex developer but new to Sencha's tools and concepts.
I got the screencast example working fine, no problem following it along. However I want to use ColdFusion to spit out recordsets as JSON, and CF's default JSON format is as follows:
{"COLUMNS":["ID","USERNAME","FIRSTNAME","LASTNAME","PASSWORD","ROLE","AVATAR","EMAIL","PHONE"],
"DATA":[["4","Jason","John","Doe","900150983cd24fb0d6963f7d28e17f72","10","","fake@email.com","07855815361"],["5","John","John","Doe","900150983cd24fb0d6963f7d28e17f72","10","","",""],["1","Stefan","Stefan","Richter","900150983cd24fb0d6963f7d28e17f72","10","","fake@email.com","077777777"]]}
This format does not match the one expected by my Reader (I am assuming the Reader is the piece that I need to modify to make the store understand my specific JSON flavour).
Any pointers here? I tried to specify rootProperty as DATA but that did not work. I am also unsure what the successProperty should be.
Or maybe it is my template settings that need editing? I'm using
<div>{FIRSTNAME} {LASTNAME} {PHONE}</div>
right now which worked for the tutorial's JSON format but not mine. I should point out that when I test the app using my CF generated JSON I still see 5 items in the list, but they are all blank.
Basically this noob needs some help :D
Thanks.
Stefan
http://vimeo.com/37561290
Noob alert: I'm a Flex developer but new to Sencha's tools and concepts.
I got the screencast example working fine, no problem following it along. However I want to use ColdFusion to spit out recordsets as JSON, and CF's default JSON format is as follows:
{"COLUMNS":["ID","USERNAME","FIRSTNAME","LASTNAME","PASSWORD","ROLE","AVATAR","EMAIL","PHONE"],
"DATA":[["4","Jason","John","Doe","900150983cd24fb0d6963f7d28e17f72","10","","fake@email.com","07855815361"],["5","John","John","Doe","900150983cd24fb0d6963f7d28e17f72","10","","",""],["1","Stefan","Stefan","Richter","900150983cd24fb0d6963f7d28e17f72","10","","fake@email.com","077777777"]]}
This format does not match the one expected by my Reader (I am assuming the Reader is the piece that I need to modify to make the store understand my specific JSON flavour).
Any pointers here? I tried to specify rootProperty as DATA but that did not work. I am also unsure what the successProperty should be.
Or maybe it is my template settings that need editing? I'm using
<div>{FIRSTNAME} {LASTNAME} {PHONE}</div>
right now which worked for the tutorial's JSON format but not mine. I should point out that when I test the app using my CF generated JSON I still see 5 items in the list, but they are all blank.
Basically this noob needs some help :D
Thanks.
Stefan