cannot call methods on dialog prior to initialization; attempted to call method 'close'
来源:互联网 发布:淘宝美工注意事项 编辑:程序博客网 时间:2024/05/15 12:02
使用jquery dialog 弹出框,点击确定后,执行dwr 删除方法 ,报这个错误 cannot call methods on dialog prior to initialization; attempted to call method 'close' 中文意思是说“无法调用方法的对话框之前初始化;试图调用方法“close”” ;
原来是这样写的:function deleExhibitionById(id){
$("#dialog-e-confirm").dialog({
resizable: false,
height:140,
modal: true,
buttons: {
"Delete": function() {
ExhibitionService.deleteExhibition(id,function(){
loadExhibitionList(1);
$(this).dialog( "close" );
});
},
Cancel: function() {
$(this).dialog( "close" );
}
}
});
原来是这样写的:function deleExhibitionById(id){
$("#dialog-e-confirm").dialog({
resizable: false,
height:140,
modal: true,
buttons: {
"Delete": function() {
ExhibitionService.deleteExhibition(id,function(){
loadExhibitionList(1);
$(this).dialog( "close" );
});
},
Cancel: function() {
$(this).dialog( "close" );
}
}
});
}
现在这样写: function deleExhibitionById(id){
$("#dialog-e-confirm").dialog({
resizable: false,
height:140,
modal: true,
buttons: {
"Delete": function() {
deleteExhibition(id,this);
},
Cancel: function() {
$(this).dialog( "close" );
}
}
});
}
function deleteExhibition(id,dialogObj){
ExhibitionService.deleteExhibition(id,function(){
loadExhibitionList(1);
$(dialogObj).dialog( "close" );
});
}
就不会弹出错误;具体是dwr 无法 再次初始化的问题
0 0
- cannot call methods on dialog prior to initialization; attempted to call method 'close'
- cannot call methods on dialog prior to initialization; attempted to call method 'close'
- cannot call methods on tooltip prior to initialization; attempted to call method 'close'(…)
- Uncaught Error: cannot call methods on dialog prior to initialization; attempted to call method 'clo
- cannot call methods on masonry prior to initialization; attempted to call method 'appended' 瀑布流
- cannot call methods on button prior to initialization; attempted to call method 'toggle' 解决
- Uncaught Error: cannot call methods on fileupload prior to initialization; attempted to call method
- cannot call methods on tooltip prior to initialization; attempted to call method 'hide'
- cannot call methods on button prior to initialization; attempted to call method 'loading'.
- jquery.min.js:4 Uncaught Error: cannot call methods on dialog prior to initialization; attempted to
- 解决Error: cannot call methods on tabs prior to initialization; attempted to call method 'disable'的方法
- Error: cannot call methods on draggable prior to initialization; attempted to call
- Uncaught cannot call methods on listview prior to initialization; 在刷新动态内容时报错的解决方案
- 在jquerymobile实现listview局部渲染的方法: listviewcannot call methods on listview prior to initialization; att
- bootstrap3.0关于button方法的attempted to call method 'loading'问题
- 解决session 关闭问题 WARN - unclosed connection, forgot to call close() on your session?
- How to call a DLL Dialog resource
- Unexpected call to method or property access
- Oracle RMAN 全备 脚本
- Android推送方案分析(MQTT/XMPP/GCM)
- 香港微视传媒合法吗?
- NGUI例子1
- 比较帖子发布时间和当前时间
- cannot call methods on dialog prior to initialization; attempted to call method 'close'
- DOS win7 生成目录树
- Web 开发与设计语言大盘点
- OpenStack文件注入相关分析(转载)
- java 反射demo
- CCI 2.5 链表整数求和
- jstl(fn函数)使用
- Delphi 中stdcall与external的意义
- Oracle清空当前用户下所有表的数据