本帖最后由 victor007 于 2022-9-1 17:11 编辑
我在样例服务器上测试了一下,预览时有报错,编辑时没有

表单是同一个
表单queryLoad事件时加载级联选择器数据
[JavaScript] 纯文本查看 复制代码 var dataBefore = [];
this.view.lookup({
"view": "b3b42fbc-b711-46a9-861a-86d79fd37d29",
"application": "305a997c-d1fd-4bc3-95ae-e117916b000e",
"filter": []
}, function(data){
data.grid.forEach(function(item){
dataBefore.push(item.data);
});
// debugger;
}, false
);
let cloneData = JSON.parse(JSON.stringify(dataBefore));
// debugger;
this.treeData = cloneData.filter(father=>{
// debugger;
let branchArr = cloneData.filter(child => father.value == child.parentId);
branchArr.length > 0 ? father.children = branchArr : '';
return father.parentId == '';
});
级联选择器
而且添加级联编辑器的时候有报错
https://www.o2oa.net/forum/thread-23583-1-1.html
|