Commit bdf49923 authored by Sergey.Konovalov's avatar Sergey.Konovalov Committed by Alexander.Trofimov

add numtype accounting

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@58749 954022d7-b5bf-4e40-9824-e11837661b57
parent 3ead16e7
......@@ -245,6 +245,7 @@ function NumFormat(bAddMinusIfNes)
this.bCurrency = false;
this.bNumber = false;
this.bInteger = false;
this.bRepeat = false;
this.Color = -1;
this.ComporationOperator = null;
......@@ -510,7 +511,7 @@ NumFormat.prototype =
if(numFormat_Bracket == oCurItem.type && null != oCurItem.color)
this.Color = oCurItem.color;
}
var bRepeat = false;
this.bRepeat = false;
var nFormatLength = this.aRawFormat.length;
//Группируем несколько элемнтов подряд в один спецсимвол
......@@ -520,8 +521,8 @@ NumFormat.prototype =
if(numFormat_Repeat == item.type)
{
//Оставляем только последний numFormat_Repeat
if(false == bRepeat)
bRepeat = true;
if(false == this.bRepeat)
this.bRepeat = true;
else
{
this.aRawFormat.splice(i, 1);
......@@ -1926,8 +1927,12 @@ NumFormat.prototype =
nType = c_oAscNumFormatType.Percent;
else if(this.bScientific)
nType = c_oAscNumFormatType.Scientific;
else if(this.bCurrency)
nType = c_oAscNumFormatType.Currency;
else if(this.bCurrency){
if(this.bRepeat)
nType = c_oAscNumFormatType.Accounting;
else
nType = c_oAscNumFormatType.Currency;
}
else if(this.bSlash)
nType = c_oAscNumFormatType.Fraction;
else if(this.bNumber)
......
......@@ -22,7 +22,8 @@ var c_oAscNumFormatType = {
Date : 7,
Time : 8,
Percent : 9,
Fraction : 10
Fraction : 10,
Accounting : 11
};
var c_oAscDrawingLayerType = {
......
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