动态刷新 dorado树的js代码
时间:2024-04-18 09:34:21
function flushDataTree()
{
dataset_mainMenuTemp.setShowLoadingTip(true);
var rootNode = tree_Menu.getFirstRootNode();
tree_Menu.setCurrentNode(rootNode);
tree_Menu.expandNode(rootNode);
dataset_mainMenu.clearData();
dataset_mainMenuTemp.flushData();
dataset_mainMenuTemp.flushDataAsync(function(succeed)
{
if (!succeed) return;
dataset_mainMenuTemp.disableControls();
try {
dataset_mainMenuTemp.moveFirst();
while (!dataset_mainMenuTemp.isLast())
{
var record=dataset_mainMenuTemp.getCurrent();
var node = new RecordTreeNode(record, rootNode.getTreeLevel().getTreeLevel("level_menu"));
rootNode.addNode(node);
dataset_mainMenuTemp.moveNext();
}
}catch(e)
{
alert(e.message);
}
finally {
dataset_mainMenuTemp.enableControls();
flushThirdLevelNode();
}
});
}
function flushThirdLevelNode(){
try {
dataset_myMailBox.parameters().setValue("myBoxCoding","box03");
dataset_myMailBox.flushData();
//将当前节点展开
var currentNode=getCurrentNodeNum(3);
tree_Menu.expandNode(currentNode);
//向dataset中新增一条节点数据
dataset_myMailBox.disableControls();
dataset_myMailBox.moveFirst();
while (!dataset_myMailBox.isLast())
{
record=dataset_myMailBox.getCurrent();
var node = new RecordTreeNode(record, currentNode.getTreeLevel().getTreeLevel("level_myMailBox"));
//新增节点
currentNode.addNode(node);
dataset_myMailBox.moveNext();
}
}catch(e)
{
alert(e.message);
} finally {
dataset_myMailBox.enableControls();
}
}
![](/images/zang.png)
![](/images/jiucuo.png)
猜你喜欢
利用Python实现普通视频变成动漫视频
![](https://img.aspxhome.com/file/2023/6/112146_0s.gif)
Python FastAPI 多参数传递的示例详解
![](https://img.aspxhome.com/file/2023/9/131639_0s.jpg)
js+css在交互上的应用
![](https://img.aspxhome.com/file/2023/9/136219_0s.jpg)
GO语言包管理工具go mod以及包详解
![](https://img.aspxhome.com/file/2023/7/127377_0s.jpg)
Python中的pygal安装和绘制直方图代码分享
![](https://img.aspxhome.com/file/2023/9/87479_0s.png)
黄相如:如何做好用户体验
Python+Yolov5人脸口罩识别的详细步骤
![](https://img.aspxhome.com/file/2023/9/128269_0s.jpg)
Python循环实现n的全排列功能
JS实现给对象动态添加属性的方法
MySQL安装失败的原因及解决步骤
![](https://img.aspxhome.com/file/2023/5/69835_0s.jpg)
python机器学习MATLAB最小二乘法的两种解读
![](https://img.aspxhome.com/file/2023/1/66001_0s.png)
举例讲解Python中metaclass元类的创建与使用
![](https://img.aspxhome.com/file/2023/8/131148_0s.png)
python实战之实现excel读取、统计、写入的示例讲解
ASP教程:0177:800401f3错误解决
django formset实现数据表的批量操作的示例代码
Python基础之字典常见操作经典实例详解
mysql 数据类型TIMESTAMP
PHP将amr音频文件转换为mp3格式的操作细节
python如何使用代码运行助手
![](https://img.aspxhome.com/file/2023/4/89184_0s.png)