Ad_class = function() {
        this.url= "/ajaxpro/Sober.Controls.Advertising.AjaxHandler.Ad,Sober.Controls.ashx";
    };

Ad_class.prototype = {
    OnClick: function(type, id, module, parameters, number, onsuccess, onerror, scope) {
        return Ext.Ajax.request({
            url: this.url,
            method: 'POST',
            headers: {
                'X-AjaxPro-Method': "OnClick",
                'X-AjaxPro-Token': (typeof AjaxPro !== "undefined" && AjaxPro.token !== null) ? AjaxPro.token : ""
            },
            params: {"type": type, "id": id, "module": module, "parameters": parameters, "number": number},
            success: onsuccess,
            failure: onerror,
            scope: scope
        });
    }
};

var Ad = new Ad_class();


