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.

71 lines
2.2 KiB

<html>
<head>
<meta charset="utf-8">
<title></title>
<link rel="stylesheet" type="text/css" href="../dist/2.0/fineui.css"/>
<!-- <script src="../dist/2.0/fineui.js"></script>-->
<script src="http://localhost:9001/fineui.js"></script>
</head>
<body>
<div id="wrapper"></div>
3 years ago
<script>
var Widget = BI.inherit(BI.Widget, {
setup: function () {
3 years ago
var wrapper, list;
return function () {
return {
3 years ago
type: "bi.vertical",
items: [{
3 years ago
type: "bi.vertical",
invisible: true,
3 years ago
ref: function (_ref) {
3 years ago
wrapper = _ref;
3 years ago
},
3 years ago
items: [{
type: "bi.button_group",
height: 100,
ref: function (_ref) {
list = _ref;
},
items: [],
layouts: [{
type: "bi.inline",
tgap: 10,
lgap: 10
}]
3 years ago
}]
}, {
3 years ago
type: "bi.button",
3 years ago
text: "点击",
3 years ago
handler: function () {
3 years ago
list.populate(BI.range(10).map(function (i) {
return {
3 years ago
type: "bi.label",
3 years ago
text: i,
3 years ago
cls: "bi-border"
};
}));
3 years ago
wrapper.setVisible(true);
3 years ago
}
}]
};
};
}
});
BI.shortcut("demo.parent", Widget);
BI.createWidget({
type: "bi.absolute",
items: [{
el: {
type: "demo.parent"
},
top: 100,
left: 100
}],
element: "#wrapper"
});
</script>
</body>
</html>