ExtJS问题

来源:百度知道 编辑:UC知道 时间:2024/06/05 08:46:05
buttons:[{
text:"保存信息",
minWidth:70,
handler:function()
{
if(AddWorkLogForm.getForm().isValid()){
//弹出效果/*
Ext.MessageBox.show({msg: '正在保存,请稍等...',
progressText: 'Saving...',
width:300,
wait:true,
waitConfig: {interval:200},
icon:'download',
animEl: 'saving'});
setTimeout(function(){}, 1000);
AddWorkLogForm.form.submit({
url:"URL/WorkLogInfo/AddWorkLogInfo.aspx?",
method:"POST",
success:function(form,action){
//成功后var flag=action.result.success;
if(flag=="true"){
Ext.MessageBox.alert("恭喜","成功");
WorkLogStore.reload();
AddWorkLogWin.hide();
}},
failure:function(form,action){
Ext.MessageBox.alert("提示!","失败!");}});}
}
},{
text:"重置",
minWidth:70,
qtip:"重置数据",
handler:function()

public partial class URL_WorkLogInfo_AddWorkLogInfo : System.Web.UI.Page
{
WorkLogBLL bll = new WorkLogBLL();
protected void Page_Load(object sender, EventArgs e){
AddWorkLogInfo();
}
public void AddWorkLogInfo(){
string Content = Request.Form["Content"];
if (userid != null && Content != null){
WorkLogBean worklog = new WorkLogBean();
worklog.Content = Content;
worklog.LogType = 1;
worklog.DateTime = System.DateTime.Now;
worklog.UserID = userid;
int count = bll.AddWorkLog(worklog);
if (count > 0){Response.Write("{success:'true'}");}
else{Response.Write("{success:'false'}");}}
else{Response.Write("{success:'false'}");}}
}

出现逻辑错误了哦··if和else语句中啊·