0

I am using PullRefresh in the following code, but it is not working in the build:

        xtype:'dataview',
        mode:'multi',
        plugins: [
            {
                xclass: 'Ext.plugin.PullRefresh',
                fetchLatest: function(plugin) {
                    var json = localStorage.getItem("JSON");
                    Ext.Ajax.request({
                        method:'POST',
                        url:webservice_url,
                        params:{ params:json},
                        success:function (response) {
                            var storeobj = Ext.getStore('questions');
                            storeobj.sync();
                            storeobj.add(result.info.info);
                            storeobj.sync();
                        },
                        failure: function(res){
                            console.log('Failure');
                        }
                    });
                }
            }
        ],

What happens when I run the build is that the fetchLatest function of pullRefresh.js gets excecuted, instead of the above fetchLatest function.

Rinju
  • 1
  • 2

1 Answers1

0

I just have the same problem as yours, may be it's not a good idea to configure function 'fetchLatest'.

This might be a solution:

http://www.sencha.com/forum/showthread.php?261763-PullRefresh-without-refreshFn&p=1007532#post1007532

Doctor.Who.
  • 607
  • 1
  • 7
  • 15