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, createWidget } from "@/core";
|
|
|
|
|
|
|
|
@shortcut()
|
|
|
|
export class Func extends Widget {
|
|
|
|
static xtype = "demo.direction_pager";
|
|
|
|
|
|
|
|
props = { baseCls: "demo-func" };
|
|
|
|
|
|
|
|
mounted() {
|
|
|
|
this.pager.populate();
|
|
|
|
}
|
|
|
|
|
|
|
|
render() {
|
|
|
|
const self = this;
|
|
|
|
createWidget({
|
|
|
|
type: "bi.vertical",
|
|
|
|
hgap: 200,
|
|
|
|
vgap: 50,
|
|
|
|
element: this,
|
|
|
|
items: [
|
|
|
|
{
|
|
|
|
type: "bi.direction_pager",
|
|
|
|
ref(_ref) {
|
|
|
|
self.pager = _ref;
|
|
|
|
},
|
|
|
|
horizontal: {
|
|
|
|
pages: false, // 总页数
|
|
|
|
curr: 1, // 初始化当前页, pages为数字时可用
|
|
|
|
|
|
|
|
hasPrev(v) {
|
|
|
|
return v > 1;
|
|
|
|
},
|
|
|
|
hasNext() {
|
|
|
|
return true;
|
|
|
|
},
|
|
|
|
firstPage: 1,
|
|
|
|
},
|
|
|
|
vertical: {
|
|
|
|
pages: false, // 总页数
|
|
|
|
curr: 1, // 初始化当前页, pages为数字时可用
|
|
|
|
|
|
|
|
hasPrev(v) {
|
|
|
|
return v > 1;
|
|
|
|
},
|
|
|
|
hasNext() {
|
|
|
|
return true;
|
|
|
|
},
|
|
|
|
firstPage: 1,
|
|
|
|
},
|
|
|
|
}
|
|
|
|
],
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|