fro*_*sty 14
如果你返回false就找到我自己的答案,它不会在循环中进行下一次迭代.
Ext.each(arrayObj, function(obj){
if(obj.isSomethingTrue()){
doSomething();
return false; /*this will prevent each from looking at
the next obj in the arrayObj*/
}
});
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
8840 次 |
| 最近记录: |