Commit f1aae51e authored by Dmitry.Shahtanov's avatar Dmitry.Shahtanov

fix: Bug 20489 - Не учитывается текст в ячейке при расчете функции AVERAGEA

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@49842 954022d7-b5bf-4e40-9824-e11837661b57
parent d8daade4
...@@ -149,6 +149,12 @@ cFormulaFunction.Statistical = { ...@@ -149,6 +149,12 @@ cFormulaFunction.Statistical = {
sum = _func[sum.type][_argV.type]( sum, _argV, "+" ); sum = _func[sum.type][_argV.type]( sum, _argV, "+" );
count++; count++;
} }
else if( _argV instanceof cString ){
if( parseNum(_argV.getValue()) ){
sum = _func[sum.type][_argV.type]( sum, _argV.tocNumber(), "+" );
}
count++;
}
} }
else if ( _arg instanceof cArea || _arg instanceof cArea3D ) { else if ( _arg instanceof cArea || _arg instanceof cArea3D ) {
var _argAreaValue = _arg.getValue(); var _argAreaValue = _arg.getValue();
...@@ -158,6 +164,12 @@ cFormulaFunction.Statistical = { ...@@ -158,6 +164,12 @@ cFormulaFunction.Statistical = {
sum = _func[sum.type][__arg.type]( sum, __arg, "+" ); sum = _func[sum.type][__arg.type]( sum, __arg, "+" );
count++; count++;
} }
else if( __arg instanceof cString ){
if( parseNum(__arg.getValue()) ){
sum = _func[sum.type][__arg.type]( sum, __arg.tocNumber(), "+" );
}
count++;
}
} }
} }
else if ( _arg instanceof cArray ) { else if ( _arg instanceof cArray ) {
......
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