fineui是帆软报表和BI产品线所使用的前端框架。
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
import { shortcut, Widget, deepClone } from "@/core";
|
|
|
|
import { Msg } from "@/base";
|
|
|
|
|
|
|
|
@shortcut()
|
|
|
|
export class MultiLayerSelectTreeCombo extends Widget {
|
|
|
|
static xtype = "demo.multilayer_select_tree_combo";
|
|
|
|
|
|
|
|
props = { baseCls: "" };
|
|
|
|
|
|
|
|
render() {
|
|
|
|
const self = this;
|
|
|
|
const items = deepClone(Demo.CONSTANTS.TREE);
|
|
|
|
|
|
|
|
return {
|
|
|
|
type: "bi.horizontal_auto",
|
|
|
|
items: [
|
|
|
|
{
|
|
|
|
type: "bi.multilayer_select_tree_combo",
|
|
|
|
ref(_ref) {
|
|
|
|
self.tree = _ref;
|
|
|
|
},
|
|
|
|
defaultText: "请选择",
|
|
|
|
items,
|
|
|
|
width: 300,
|
|
|
|
value: ["第五级文件1"],
|
|
|
|
},
|
|
|
|
{
|
|
|
|
type: "bi.button",
|
|
|
|
text: "getVlaue",
|
|
|
|
handler() {
|
|
|
|
Msg.toast(self.tree.getValue()[0]);
|
|
|
|
},
|
|
|
|
width: 300,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
type: "bi.button",
|
|
|
|
text: "setVlaue (第二级文件1)",
|
|
|
|
handler() {
|
|
|
|
self.tree.setValue(["11"]);
|
|
|
|
},
|
|
|
|
width: 300,
|
|
|
|
}
|
|
|
|
],
|
|
|
|
vgap: 20,
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|