ext提交,很简单的问题,哪位耐心人士帮帮看看
//添加用户的窗口
function toadd() {
var addwin = new Ext.Window( {
width : 500,
height : 300,
title : '添加信息',
collapsible : true,
plain : true,
modal : true
});
//添加用户的表单
var addform = new Ext.form.FormPanel( {
layout : 'form',
id : 'add_form',
buttonAlign : 'center',
labelAlign : 'right',
region : 'center',
defaultType : 'textfield',
items : [ {
name : 'terminal_id',
fieldLabel : '终端编号',
width : 180,
allowBlank : false,
blankText : '终端编号不能为空' //错误信息提示
}, {
name : 'terminal_type',
fieldLabel : '终端类型',
width : 180,
allowBlank : false,
blankText : '终端类型不能为空'
}, {
name : 'is_controllable',
id : 'is_controllable',
fieldLabel : '是否可控制',
xtype : 'combo',
triggerAction : 'all',
store : [ [ '1', '是' ], [ '0', '否' ] ],
width : 80,
editable : false,
emptyText : '请选择'
}, {
name : 'is_shuttable',
id : 'is_shuttable',
fieldLabel : '是否可跳闸',
xtype : 'combo',
triggerAction : 'all',
store : [ [ '1', '是' ], [ '0', '否' ] ],
width : 80,
editable : false,
emptyText : '请选择'
}, {
name : 'is_readdable',
id : 'is_readdable',
fieldLabel : '是否可读表',
xtype : 'combo',
triggerAction : 'all',
store : [ [ '1', '是' ], [ '0', '否' ] ],
width : 80,
editable : false,
emptyText : '请选择'
}, {
name : 'charge_person',
fieldLabel : '负责人',
width : 180,
allowBlank : false,
blankText : '负责人不能为空'
}, {
name : 'active_time',
fieldLabel : '投运日期',
width : 140,
xtype : 'datefield',
format : 'Y-m-d'
}, {
name : 'is_active',
id : 'is_active',
fieldLabel : '是否有效',
xtype : 'combo',
triggerAction : 'all',
store : [ [ '1', '是' ], [ '0', '否' ] ],
width : 80,
editable : false,
emptyText : '请选择'
} ],
buttons : [ {
text : '确定',
type : 'submit',
handler : function() {
if (addform.form.isValid()) {
addform.form.doAction('submit', {
url : 'donew.do',
method : 'POST',
success : function(form, action) {
addwin.hide();
Ext.Msg.alert('系统信息',
action.result.data);
ds.reload();
},
failure : function(form, action) {
Ext.Msg.alert('系统信息',
action.resultldata);
ds.reload();
addwin.hide();
}
});
}
}
} ]
});
addwin.add( {
items : addform
});
addwin.show();
}
问题:点提交的时候ie浏览器报语法错误,请哪位高手帮忙看看是哪里错了
function toadd() {
var addwin = new Ext.Window( {
width : 500,
height : 300,
title : '添加信息',
collapsible : true,
plain : true,
modal : true
});
//添加用户的表单
var addform = new Ext.form.FormPanel( {
layout : 'form',
id : 'add_form',
buttonAlign : 'center',
labelAlign : 'right',
region : 'center',
defaultType : 'textfield',
items : [ {
name : 'terminal_id',
fieldLabel : '终端编号',
width : 180,
allowBlank : false,
blankText : '终端编号不能为空' //错误信息提示
}, {
name : 'terminal_type',
fieldLabel : '终端类型',
width : 180,
allowBlank : false,
blankText : '终端类型不能为空'
}, {
name : 'is_controllable',
id : 'is_controllable',
fieldLabel : '是否可控制',
xtype : 'combo',
triggerAction : 'all',
store : [ [ '1', '是' ], [ '0', '否' ] ],
width : 80,
editable : false,
emptyText : '请选择'
}, {
name : 'is_shuttable',
id : 'is_shuttable',
fieldLabel : '是否可跳闸',
xtype : 'combo',
triggerAction : 'all',
store : [ [ '1', '是' ], [ '0', '否' ] ],
width : 80,
editable : false,
emptyText : '请选择'
}, {
name : 'is_readdable',
id : 'is_readdable',
fieldLabel : '是否可读表',
xtype : 'combo',
triggerAction : 'all',
store : [ [ '1', '是' ], [ '0', '否' ] ],
width : 80,
editable : false,
emptyText : '请选择'
}, {
name : 'charge_person',
fieldLabel : '负责人',
width : 180,
allowBlank : false,
blankText : '负责人不能为空'
}, {
name : 'active_time',
fieldLabel : '投运日期',
width : 140,
xtype : 'datefield',
format : 'Y-m-d'
}, {
name : 'is_active',
id : 'is_active',
fieldLabel : '是否有效',
xtype : 'combo',
triggerAction : 'all',
store : [ [ '1', '是' ], [ '0', '否' ] ],
width : 80,
editable : false,
emptyText : '请选择'
} ],
buttons : [ {
text : '确定',
type : 'submit',
handler : function() {
if (addform.form.isValid()) {
addform.form.doAction('submit', {
url : 'donew.do',
method : 'POST',
success : function(form, action) {
addwin.hide();
Ext.Msg.alert('系统信息',
action.result.data);
ds.reload();
},
failure : function(form, action) {
Ext.Msg.alert('系统信息',
action.resultldata);
ds.reload();
addwin.hide();
}
});
}
}
} ]
});
addwin.add( {
items : addform
});
addwin.show();
}
问题:点提交的时候ie浏览器报语法错误,请哪位高手帮忙看看是哪里错了
...全文
相关推荐
ext 表单提交
但以上内容概括了Ext JS中表单提交的一般流程和关键概念。如果你需要更详细的代码示例或遇到特定问题,建议查阅Ext JS官方文档或搜索相关的开发者论坛。
EXT提交服务器的三种方式
**EXT的Form表单AJAX提交**:这是EXT中最常见的提交方式,它允许你在不刷新整个页面的情况下与服务器进行异步通信。
EXT异步提交FORM表单
- **跨域问题**:如果EXT所在的域名与后端服务器的域名不一致,则需要处理跨域问题。可以采用CORS机制或JSONP方式解决。
ext form 表单提交数据的方法小结
在EXT JS中,表单(Form)是数据输入和验证的核心组件。本文主要总结了EXT表单提交数据的三种常见方法:EXT的form表单AJAX提交、非AJAX提交以及EXT的Ajax类直接提交。1.
2、嵌入式 Linux 系统:从定义到应用
本文深入探讨了嵌入式Linux系统的定义、架构与构建方法论,涵盖从Linux的起源与发展到嵌入式系统的核心组成。文章详细介绍了嵌入式Linux的硬件平台、引导加载程序、内核定制、根文件系统构建及应用程序开发流程,并通过智能家居和工业自动化等实际案例展示了其广泛应用。同时,提供了代码使用规范、出版信息及致谢内容,帮助读者全面理解嵌入式Linux系统的设计与实现。


