|
|
@ -4003,8 +4003,13 @@ BI.shortcut("demo.text_trigger", Demo.Func);Demo.CanvasTable = BI.inherit(BI.Wid |
|
|
|
|
|
|
|
|
|
|
|
mounted: function () { |
|
|
|
mounted: function () { |
|
|
|
var self = this; |
|
|
|
var self = this; |
|
|
|
var tableItems = this._expandData(TABLE_ITEMS, 3), |
|
|
|
if (BI.isNull(BI.isExpanded)) { |
|
|
|
headItems = this._expandHeadData(TABLE_HEADER, 3); |
|
|
|
BI.isExpanded = false; |
|
|
|
|
|
|
|
} else if (!BI.isExpanded) { |
|
|
|
|
|
|
|
TABLE_ITEMS = this._expandData(TABLE_ITEMS, 3); |
|
|
|
|
|
|
|
TABLE_HEADER = this._expandHeadData(TABLE_HEADER, 3); |
|
|
|
|
|
|
|
BI.isExpanded = true; |
|
|
|
|
|
|
|
} |
|
|
|
this._resizeHandler = BI.debounce(function () { |
|
|
|
this._resizeHandler = BI.debounce(function () { |
|
|
|
var width = self.element.width(), height = self.element.height(); |
|
|
|
var width = self.element.width(), height = self.element.height(); |
|
|
|
if (self.table.getWidth() !== width || self.table.getHeight() !== height) { |
|
|
|
if (self.table.getWidth() !== width || self.table.getHeight() !== height) { |
|
|
@ -4018,14 +4023,14 @@ BI.shortcut("demo.text_trigger", Demo.Func);Demo.CanvasTable = BI.inherit(BI.Wid |
|
|
|
}); |
|
|
|
}); |
|
|
|
this.table.setWidth(this.element.width()); |
|
|
|
this.table.setWidth(this.element.width()); |
|
|
|
this.table.setHeight(this.element.height()); |
|
|
|
this.table.setHeight(this.element.height()); |
|
|
|
this.table.attr("columnSize", BI.makeArray(headItems[0].length, "")); |
|
|
|
this.table.attr("columnSize", BI.makeArray(TABLE_HEADER[0].length, "")); |
|
|
|
this.table.attr("minColumnSize", BI.makeArray(headItems[0].length, 60)); |
|
|
|
this.table.attr("minColumnSize", BI.makeArray(TABLE_HEADER[0].length, 60)); |
|
|
|
this.table.attr("isNeedFreeze", true); |
|
|
|
this.table.attr("isNeedFreeze", true); |
|
|
|
this.table.attr("freezeCols", []); |
|
|
|
this.table.attr("freezeCols", []); |
|
|
|
this.table.attr("showSequence", true); |
|
|
|
this.table.attr("showSequence", true); |
|
|
|
this.table.attr("headerRowSize", 15); |
|
|
|
this.table.attr("headerRowSize", 15); |
|
|
|
this.table.attr("rowSize", 15); |
|
|
|
this.table.attr("rowSize", 15); |
|
|
|
this.table.populate(tableItems, headItems); |
|
|
|
this.table.populate(TABLE_ITEMS, TABLE_HEADER); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_expandData: function (items, times) { |
|
|
|
_expandData: function (items, times) { |
|
|
@ -4657,8 +4662,13 @@ BI.shortcut("bi.detail_table_header", BI.DetailTableHeader);Demo.Face = BI.inher |
|
|
|
|
|
|
|
|
|
|
|
mounted: function () { |
|
|
|
mounted: function () { |
|
|
|
var self = this; |
|
|
|
var self = this; |
|
|
|
var tableItems = this._expandData(TABLE_ITEMS, 3), |
|
|
|
if (BI.isNull(BI.isExpanded)) { |
|
|
|
headItems = this._expandHeadData(TABLE_HEADER, 3); |
|
|
|
BI.isExpanded = false; |
|
|
|
|
|
|
|
} else if (!BI.isExpanded) { |
|
|
|
|
|
|
|
TABLE_ITEMS = this._expandData(TABLE_ITEMS, 3); |
|
|
|
|
|
|
|
TABLE_HEADER = this._expandHeadData(TABLE_HEADER, 3); |
|
|
|
|
|
|
|
BI.isExpanded = true; |
|
|
|
|
|
|
|
} |
|
|
|
this._resizeHandler = BI.debounce(function () { |
|
|
|
this._resizeHandler = BI.debounce(function () { |
|
|
|
var width = self.element.width(), height = self.element.height(); |
|
|
|
var width = self.element.width(), height = self.element.height(); |
|
|
|
if (self.table.getWidth() !== width || self.table.getHeight() !== height) { |
|
|
|
if (self.table.getWidth() !== width || self.table.getHeight() !== height) { |
|
|
@ -4672,14 +4682,14 @@ BI.shortcut("bi.detail_table_header", BI.DetailTableHeader);Demo.Face = BI.inher |
|
|
|
}); |
|
|
|
}); |
|
|
|
this.table.setWidth(this.element.width()); |
|
|
|
this.table.setWidth(this.element.width()); |
|
|
|
this.table.setHeight(this.element.height()); |
|
|
|
this.table.setHeight(this.element.height()); |
|
|
|
this.table.attr("columnSize", BI.makeArray(headItems[0].length, "")); |
|
|
|
this.table.attr("columnSize", BI.makeArray(TABLE_HEADER[0].length, "")); |
|
|
|
this.table.attr("minColumnSize", BI.makeArray(headItems[0].length, 60)); |
|
|
|
this.table.attr("minColumnSize", BI.makeArray(TABLE_HEADER[0].length, 60)); |
|
|
|
this.table.attr("isNeedFreeze", true); |
|
|
|
this.table.attr("isNeedFreeze", true); |
|
|
|
this.table.attr("freezeCols", []); |
|
|
|
this.table.attr("freezeCols", []); |
|
|
|
this.table.attr("showSequence", true); |
|
|
|
this.table.attr("showSequence", true); |
|
|
|
this.table.attr("headerRowSize", 15); |
|
|
|
this.table.attr("headerRowSize", 15); |
|
|
|
this.table.attr("rowSize", 15); |
|
|
|
this.table.attr("rowSize", 15); |
|
|
|
this.table.populate(tableItems, headItems); |
|
|
|
this.table.populate(TABLE_ITEMS, TABLE_HEADER); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_expandData: function (items, times) { |
|
|
|
_expandData: function (items, times) { |
|
|
|