PDA

View Full Version : extend Ext.data.DataProxy



monkeyvu
13 Mar 2011, 6:49 AM
Hi all,

I'm extending the Ext.data.DataProxy like below:

Ext.extend(Ext.ux.data.MyProxy, Ext.data.DataProxy, {
request: function(action, rs, params, reader, callback, scope, options) {
alert(action);
}
});

Then I implement the JSonStore which uses MyProxy. When I delete an event, I get the "destroy" action , when I update an event I get the "update" action, when I create an event, I get "create" action.

The problem is:

I create an event A, I get the "create" action. Then I update that event, I still get the "create" action. Should it be "update" action instead?

monkeyvu
13 Mar 2011, 7:03 AM
If I delete an event has been created, the request method isn't called anyway. Anyone knows this issue?