Commit 0f485337 authored by GoshaZotov's avatar GoshaZotov Committed by Alexander.Trofimov

add new props and change name(class asc_CFormatTableInfo)

parent 54244141
...@@ -149,8 +149,6 @@ ...@@ -149,8 +149,6 @@
/** @constructor */ /** @constructor */
function asc_CAutoFilterInfo() { function asc_CAutoFilterInfo() {
this.tableStyleName = null;
this.tableName = null;
this.isApplyAutoFilter = false; // Кнопка очистить фильтр: false - disable, true - pressed button this.isApplyAutoFilter = false; // Кнопка очистить фильтр: false - disable, true - pressed button
this.isAutoFilter = false; // Кнопка автофильтр (также влияет на formatTable и Sort). Возможные состояния: this.isAutoFilter = false; // Кнопка автофильтр (также влияет на formatTable и Sort). Возможные состояния:
// - null - мы в пересечении с таблицой (но не полностью в ней) // - null - мы в пересечении с таблицой (но не полностью в ней)
...@@ -158,8 +156,6 @@ ...@@ -158,8 +156,6 @@
} }
asc_CAutoFilterInfo.prototype = { asc_CAutoFilterInfo.prototype = {
asc_getTableStyleName: function () { return this.tableStyleName; },
asc_getTableName: function () { return this.tableName; },
asc_getIsAutoFilter: function () { return this.isAutoFilter; }, asc_getIsAutoFilter: function () { return this.isAutoFilter; },
asc_getIsApplyAutoFilter: function () { return this.isApplyAutoFilter; } asc_getIsApplyAutoFilter: function () { return this.isApplyAutoFilter; }
}; };
...@@ -167,14 +163,15 @@ ...@@ -167,14 +163,15 @@
window["Asc"].asc_CAutoFilterInfo = window["Asc"]["asc_CAutoFilterInfo"] = asc_CAutoFilterInfo; window["Asc"].asc_CAutoFilterInfo = window["Asc"]["asc_CAutoFilterInfo"] = asc_CAutoFilterInfo;
prot = asc_CAutoFilterInfo.prototype; prot = asc_CAutoFilterInfo.prototype;
prot["asc_getTableStyleName"] = prot.asc_getTableStyleName;
prot["asc_getTableName"] = prot.asc_getTableName;
prot["asc_getIsAutoFilter"] = prot.asc_getIsAutoFilter; prot["asc_getIsAutoFilter"] = prot.asc_getIsAutoFilter;
prot["asc_getIsApplyAutoFilter"] = prot.asc_getIsApplyAutoFilter; prot["asc_getIsApplyAutoFilter"] = prot.asc_getIsApplyAutoFilter;
/** @constructor */ /** @constructor */
function asc_CFormatTableInfo() { function asc_CFormatTableInfo() {
this.tableStyleName = null;
this.tableName = null;
this.isShowColumnStripes = null; this.isShowColumnStripes = null;
this.isShowFirstColumn = null; this.isShowFirstColumn = null;
this.isShowLastColumn = null; this.isShowLastColumn = null;
...@@ -184,23 +181,31 @@ ...@@ -184,23 +181,31 @@
} }
asc_CFormatTableInfo.prototype = { asc_CFormatTableInfo.prototype = {
asc_getIsShowColumnStripes: function () { return this.isShowColumnStripes; }, asc_getTableStyleName: function () { return this.tableStyleName; },
asc_getIsShowFirstColumn: function () { return this.isShowFirstColumn; }, asc_getTableName: function () { return this.tableName; },
asc_getIsShowLastColumn: function () { return this.isShowLastColumn; },
asc_getIsShowRowStripes: function () { return this.isShowRowStripes; }, asc_getFirstRow: function () { return this.firstRow; },
asc_getIsShowTotalRow: function () { return this.isShowTotalRow; }, asc_getLastRow: function () { return this.lastRow; },
asc_getIsShowHeaderRow: function () { return this.isShowHeaderRow; } asc_getBandHor: function () { return this.bandHor; },
asc_getFirstCol: function () { return this.firstCol; },
asc_getLastCol: function () { return this.lastCol; },
asc_getBandVer: function () { return this.bandVer; },
asc_getFilterButton: function () { return this.filterButton; }
}; };
window["Asc"].asc_CFormatTableInfo = window["Asc"]["asc_CFormatTableInfo"] = asc_CFormatTableInfo; window["Asc"].asc_CFormatTableInfo = window["Asc"]["asc_CFormatTableInfo"] = asc_CFormatTableInfo;
prot = asc_CFormatTableInfo.prototype; prot = asc_CFormatTableInfo.prototype;
prot["asc_getIsShowColumnStripes"] = prot.asc_getIsShowColumnStripes; prot["asc_getTableStyleName"] = prot.asc_getTableStyleName;
prot["asc_getIsShowFirstColumn"] = prot.asc_getIsShowFirstColumn; prot["asc_getTableName"] = prot.asc_getTableName;
prot["asc_getIsShowLastColumn"] = prot.asc_getIsShowLastColumn;
prot["asc_getIsShowRowStripes"] = prot.asc_getIsShowRowStripes; prot["asc_getFirstRow"] = prot.asc_getFirstRow;
prot["asc_getIsShowTotalRow"] = prot.asc_getIsShowTotalRow; prot["asc_getLastRow"] = prot.asc_getLastRow;
prot["asc_getIsShowHeaderRow"] = prot.asc_getIsShowHeaderRow; prot["asc_getBandHor"] = prot.asc_getBandHor;
prot["asc_getFirstCol"] = prot.asc_getFirstCol;
prot["asc_getLastCol"] = prot.asc_getLastCol;
prot["asc_getBandVer"] = prot.asc_getBandVer;
prot["asc_getFilterButton"] = prot.asc_getFilterButton;
/** @constructor */ /** @constructor */
......
...@@ -7286,8 +7286,6 @@ ...@@ -7286,8 +7286,6 @@
var tableStyleInfo = curTablePart && curTablePart.TableStyleInfo ? curTablePart.TableStyleInfo : null; var tableStyleInfo = curTablePart && curTablePart.TableStyleInfo ? curTablePart.TableStyleInfo : null;
cell_info.autoFilterInfo = new asc_CAutoFilterInfo(); cell_info.autoFilterInfo = new asc_CAutoFilterInfo();
cell_info.autoFilterInfo.tableStyleName = tableStyleInfo !== null ? tableStyleInfo.Name : null;
cell_info.autoFilterInfo.tableName = curTablePart ? curTablePart.DisplayName : null;
if ( -2 === tablePartsOptions ) { if ( -2 === tablePartsOptions ) {
cell_info.autoFilterInfo.isAutoFilter = null; cell_info.autoFilterInfo.isAutoFilter = null;
cell_info.autoFilterInfo.isApplyAutoFilter = false; cell_info.autoFilterInfo.isApplyAutoFilter = false;
...@@ -7301,15 +7299,21 @@ ...@@ -7301,15 +7299,21 @@
if(curTablePart !== null) if(curTablePart !== null)
{ {
cell_info.formatTableInfo = new asc.asc_CFormatTableInfo(); cell_info.formatTableInfo = new asc.asc_CFormatTableInfo();
cell_info.formatTableInfo.tableName = curTablePart.DisplayName;
if (tableStyleInfo) { if (tableStyleInfo) {
cell_info.formatTableInfo.isShowColumnStripes = tableStyleInfo.ShowColumnStripes; cell_info.formatTableInfo.tableStyleName = tableStyleInfo.Name;
cell_info.formatTableInfo.isShowFirstColumn = tableStyleInfo.ShowFirstColumn;
cell_info.formatTableInfo.isShowLastColumn = tableStyleInfo.ShowLastColumn; cell_info.formatTableInfo.bandVer = tableStyleInfo.ShowColumnStripes;
cell_info.formatTableInfo.firstCol = tableStyleInfo.ShowFirstColumn;
cell_info.formatTableInfo.lastCol = tableStyleInfo.ShowLastColumn;
cell_info.formatTableInfo.isShowRowStripes = tableStyleInfo.ShowRowStripes; cell_info.formatTableInfo.bandHor = tableStyleInfo.ShowRowStripes;
} }
cell_info.formatTableInfo.isShowTotalRow = curTablePart.TotalsRowCount !== null ? true : false; cell_info.formatTableInfo.lastRow = curTablePart.TotalsRowCount !== null ? true : false;
cell_info.formatTableInfo.isShowHeaderRow = curTablePart.HeaderRowCount !== null ? true : false; cell_info.formatTableInfo.firstRow = curTablePart.HeaderRowCount !== null ? true : false;
//cell_info.formatTableInfo.filterButton = curTablePart.HeaderRowCount !== null ? true : false;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment