-- Guillaume ORIOL <[email protected]> wrote (on Wednesday, 21 April 2010, 04:08 PM +0200): > As far as I know, dojox.data.JsonRestStore expects to receive data in the > form: > [ > {"prop1":"value1", "prop2":"value2", ...}, > {"prop1":"value1", "prop2":"value2", ...}, > ... > ] > > On the server side, I fetch data with a paginator > (Zend_Paginator_Adapter_DbSelect). This paginator implements a > toJson function. But whatever FETCH_MODE is used to get the data, I > get a Json representation like this one: > { > "0": {"prop1":"value1", "prop2":"value2", ...}, > "1": {"prop1":"value1", "prop2":"value2", ...}, > ... > } > > Is there something obvious I miss or do I have to write my own implementation > of the toJson() function?
Honestly, I'd consider that a bug -- numeric indices should be returned as an array, not as an object. Can you file an issue, please? -- Matthew Weier O'Phinney Project Lead | [email protected] Zend Framework | http://framework.zend.com/ PGP key: http://framework.zend.com/zf-matthew-pgp-key.asc
