把两种方法分别放入两个function中:
代码
funcrion Insert(){
Ext.Ajax.request({
url:'handler1.ashx?parm=List',
method:'post', //传递到后台的方式,这种要带参数
success:function(){},
failure:function(){},
params:
{
stu_id:add_panel.getForm.findFiedl("add_stu_id").getValue()
}
});
};
Ext.Ajax.request({
url:'handler1.ashx?parm=List',
method:'post', //传递到后台的方式,这种要带参数
success:function(){},
failure:function(){},
params:
{
stu_id:add_panel.getForm.findFiedl("add_stu_id").getValue()
}
});
};
代码
funcrion Update(){
update_panel.form.submit({
url:'handler1.ashx?parm=List',
method:'get, //传递到后台的方式,这种不用带参数
success:function(){},
failure:function(){}
});
};
update_panel.form.submit({
url:'handler1.ashx?parm=List',
method:'get, //传递到后台的方式,这种不用带参数
success:function(){},
failure:function(){}
});
};