PDA

View Full Version : Load method returns data for first node only



prakadam
29 Oct 2011, 10:19 AM
Even though the different IDs have been passed to the load method, it loads only for first child. I think this is because of it tries to load for first record only. Please see below code in red.



load : function(a, b) {
b = Ext.applyIf(b || {}, {
action : "read",
id : a
});
var c = new Ext.data.Operation(b), f = b.callback, h = b.success, e = b.failure, i = b.scope, d, g;
g = function(j) {
d = j.getRecords()[0];
if (j.wasSuccessful()) {
if (typeof h == "function") {
h.call(i, d, j)
}
} else {
if (typeof e == "function") {
e.call(i, d, j)
}