[Answer]-Using Dojo Grid with REST (tastypie)

1👍

Untested, but you might try creating a custom store that inherits from JsonRestStore and override the internal _processResults method. It’s a two-liner in the Dojo 1.7 code base, so you can implement you own behavior quite simply.

_processResults: function(results, deferred){
    var count = results.objects.length;
    return {totalCount: deferred.fullLength || (deferred.request.count == count ? (deferred.request.start || 0) + count * 2 : count), items: results.objects};
}

See lines 414-417 of the dojox/data/JsonRestStore.js for reference.

👤Lucas

0👍

I don’t know whether this will helpful for you or not. http://jayapal-d.blogspot.in/2009/08/dojo-datagrid-with-editable-cells-in.html

Leave a comment