Commit f4ae4f07 authored by Igor.Zotov's avatar Igor.Zotov Committed by Alexander.Trofimov

добавил функции для определения, применен ли к данной ячейке а/ф

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@57564 954022d7-b5bf-4e40-9824-e11837661b57
parent 4d5ee241
......@@ -165,6 +165,7 @@
this.styleName = null;
this.numFormatType = null;
this.angle = null;
this.autoFilter = null;
}
asc_CCellInfo.prototype = {
......@@ -185,7 +186,8 @@
asc_getIsFormatTable: function () { return this.isFormatTable; },
asc_getStyleName: function () { return this.styleName; },
asc_getNumFormatType: function(){ return this.numFormatType; },
asc_getAngle: function () { return this.angle; }
asc_getAngle: function () { return this.angle; },
asc_getAutoFilter: function () { return this.autoFilter; }
};
window["Asc"].asc_CCellInfo = window["Asc"]["asc_CCellInfo"] = asc_CCellInfo;
......@@ -209,5 +211,6 @@
prot["asc_getStyleName"] = prot.asc_getStyleName;
prot["asc_getNumFormatType"] = prot.asc_getNumFormatType;
prot["asc_getAngle"] = prot.asc_getAngle;
prot["asc_getAutoFilter"] = prot.asc_getAutoFilter;
}
)(window);
\ No newline at end of file
......@@ -1603,6 +1603,37 @@ var gUndoInsDelCellsFlag = true;
History.EndTransaction();
if(turnOnHistory)
History.TurnOff();
},
isApplyAutoFilterInCell: function(activeCell)
{
var aWs = this._getCurrentWS();
var tableRange;
if(aWs.TableParts)
{
var tablePart;
for(var i = 0; i < aWs.TableParts.length; i++)
{
tablePart = aWs.TableParts[i];
//если применен фильтр или сортировка
if(tablePart.Ref && ((tablePart.AutoFilter && tablePart.AutoFilter.FilterColumns && tablePart.AutoFilter.FilterColumns.length) || (tablePart && tablePart.SortState && tablePart.SortState.SortConditions && tablePart.SortState.SortConditions[0])))
{
if(tablePart.Ref.containsRange(activeCell))
return true;
}
else
{
if(tablePart.Ref.containsRange(activeCell))
return false;
};
};
};
if(aWs.AutoFilter && ((aWs.AutoFilter.FilterColumns && aWs.AutoFilter.FilterColumns.length) || (aWs.AutoFilter.SortState && aWs.AutoFilter.SortState.SortConditions && aWs.AutoFilter.SortState.SortConditions[0])))
return true;
return false;
},
_checkClickFrozenArea: function(x, y, offsetX, offsetY, frozenObj)
......
......@@ -6507,7 +6507,10 @@
}
}
}
//применен ли а/ф к данной ячейке
cell_info.autoFilter = this.autoFilters.isApplyAutoFilterInCell(activeCell);
return cell_info;
};
......
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