levysnail 2013-03-19
SEC7118: http://ajax.googleapis.com/ajax/libs/dojo/1.9.0/dijit//templates/TreeNode.html 的 XMLHttpRequest 需要跨域资源共享(CORS)。 home SEC7119: http://ajax.googleapis.com/ajax/libs/dojo/1.9.0/dijit//templates/TreeNode.html 的 XMLHttpRequest 需要飞行前 CORS。 home SEC7118: http://ajax.googleapis.com/ajax/libs/dojo/1.9.0/dijit//templates/Tree.html 的 XMLHttpRequest 需要跨域资源共享(CORS)。 home SEC7119: http://ajax.googleapis.com/ajax/libs/dojo/1.9.0/dijit//templates/Tree.html 的 XMLHttpRequest 需要飞行前 CORS。 home SCRIPT7002: XMLHttpRequest: 网络错误 0x80070005, 拒绝访问。 home SCRIPT7002: XMLHttpRequest: 网络错误 0x80070005, 拒绝访问。 home
1. 页面中html元素添加<html lang="en"> 属性的时候, 导致dojox.grid.DataGrid无法正常加载.
<html lang="en">
2. 当使用iframe引用dojo页面的时候, 由于主子页面中声明的IE兼容模式不同,而导致DataGrid通过on添加click事件中, 无法通过e.grid获取触发事件的grid实例引用. 例如:主子页面中各自使用, 请确保项目中所有页面设置的IE兼容模式的声明保持一致!
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
3. 给DataGrid添加onRowClick的三种方式:
正确方式:
<table data-dojo-id="myDG" data-dojo-type="dojox/grid/DataGrid"...>
    <script type="dojo/on" data-dojo-event="rowClick" data-dojo-args="e">
        // do something...
    </script>
</table><script>
    myDG.on("rowClick",function(e){
        // do something...
    });
</script><script type="dojo/require">aspect:"dojo/aspect"</script>
<script>
    aspect.after("rowClick",function(e){
        // do something...
    });
</script>错误方式:
<script type="dojo/require">on:"dojo/on"</script>        
<script>
    on("rowClick",function(e){
        // can't do anything
    });
</script>4. 使用TooltipDialog的set href 加载包含DataGrid或layout组件的时候, 必须调用startup方法,才能渲染出来, 不然只会显示空白.
5. parser.parse() 必须放在ready中进行调用
6.popup.open的orient属性, 参考ToolTip.defaultPosition
7.dojox.layout.TableContainer 设置lable和value单元格的样式的使用使用
.tableContainer-labelCell{
}
.tableContainer-valueCell{
}而不是
.labelsAndValues-labelCell{
}
.labelsAndValues-valueCell{
}
8.实现DataGrid标题上下左右局中的效果
defaultCell : {
    styles : "text-align:center;vertical-align:middle;"
}9. DataGrid不能实现第一行横向单元格合并的效果, colspan
10. DataGrid标题多行显示时, 为了实现数据行只显示第一行, 隐藏第二行, 在定义列表结构的时候, 添加如下代码
onBeforeRow : function(inDataIndex, inSubRows) {
    inSubRows[1].hidden = inDataIndex >= 0;
}11. 为Chart创建Legend时候, 必须先调用chart.render(), 否则颜色无法正常显示
12. dojox/charting 中, action2d的初始化必须在chart.render() 之前进行
13. 是用TooltipDialog的时候, 如果不设置style:height的值, 他的高度会根据起加载内容的高度而定, 如果加载内容高度过高, td会向下扩展,而不是向上, 导致对不齐
14. dojox/request/xhr 中的data参数不能用在get和delete请求中
15.使用DataGrid的set("store",store) 不会使用最新的数据源刷新列表, 请使用setStore
16.添加事件的两种方式, dojo/on, aspect.after
17. lang.hitch的使用
aspect.after(tpm, "onMoved", lang.hitch(this, function(){
    this.reDrawPoints();
}));18.SpringMVC返回json中文乱码问题解决
@RequestMapping(value = "/dologin", method = RequestMethod.POST, produces = "application/json;charset=UTF-8")
19.WIN7+Dojo1.9.0(cnd)+IE10上的问题, 但是使用Dojo1.8.4是没有问题的
SEC7118: http://ajax.googleapis.com/ajax/libs/dojo/1.9.0/dijit//templates/TreeNode.html 的 XMLHttpRequest 需要跨域资源共享(CORS)。 home SEC7119: http://ajax.googleapis.com/ajax/libs/dojo/1.9.0/dijit//templates/TreeNode.html 的 XMLHttpRequest 需要飞行前 CORS。 home SEC7118: http://ajax.googleapis.com/ajax/libs/dojo/1.9.0/dijit//templates/Tree.html 的 XMLHttpRequest 需要跨域资源共享(CORS)。 home SEC7119: http://ajax.googleapis.com/ajax/libs/dojo/1.9.0/dijit//templates/Tree.html 的 XMLHttpRequest 需要飞行前 CORS。 home SCRIPT7002: XMLHttpRequest: 网络错误 0x80070005, 拒绝访问。 home SCRIPT7002: XMLHttpRequest: 网络错误 0x80070005, 拒绝访问。 home