Commit 2ff49bbc authored by Alexander.Trofimov's avatar Alexander.Trofimov

add functions

asc_getManualMax
asc_getManualMin
asc_setManualMax
asc_setManualMin
parent 5456e8d1
...@@ -4596,9 +4596,9 @@ CellArea.prototype = { ...@@ -4596,9 +4596,9 @@ CellArea.prototype = {
this.minAxisType = null; this.minAxisType = null;
this.maxAxisType = null; this.maxAxisType = null;
this.rightToLeft = null; this.rightToLeft = null;
this.manualMax = null;
this.manualMin = null;
this.manualMax = undefined;
this.manualMin = undefined;
this.dateAxis = false; this.dateAxis = false;
// elements // elements
...@@ -4643,6 +4643,8 @@ CellArea.prototype = { ...@@ -4643,6 +4643,8 @@ CellArea.prototype = {
this.minAxisType = Asc.c_oAscSparklineAxisMinMax.Individual; this.minAxisType = Asc.c_oAscSparklineAxisMinMax.Individual;
this.maxAxisType = Asc.c_oAscSparklineAxisMinMax.Individual; this.maxAxisType = Asc.c_oAscSparklineAxisMinMax.Individual;
this.rightToLeft = false; this.rightToLeft = false;
this.manualMax = null;
this.manualMin = null;
// elements // elements
var defaultSeriesColor = 3629202; var defaultSeriesColor = 3629202;
...@@ -4658,8 +4660,6 @@ CellArea.prototype = { ...@@ -4658,8 +4660,6 @@ CellArea.prototype = {
this.colorLow = new AscCommonExcel.RgbColor(defaultOtherColor); this.colorLow = new AscCommonExcel.RgbColor(defaultOtherColor);
}; };
sparklineGroup.prototype.set = function (val) { sparklineGroup.prototype.set = function (val) {
this.manualMax = null !== val.manualMax ? val.manualMax : this.manualMax;
this.manualMin = null !== val.manualMin ? val.manualMin : this.manualMin;
this.lineWeight = null !== val.lineWeight ? val.lineWeight : this.lineWeight; this.lineWeight = null !== val.lineWeight ? val.lineWeight : this.lineWeight;
this.type = null !== val.type ? val.type : this.type; this.type = null !== val.type ? val.type : this.type;
this.dateAxis = null !== val.dateAxis ? val.dateAxis : this.dateAxis; this.dateAxis = null !== val.dateAxis ? val.dateAxis : this.dateAxis;
...@@ -4675,6 +4675,8 @@ CellArea.prototype = { ...@@ -4675,6 +4675,8 @@ CellArea.prototype = {
this.minAxisType = null !== val.minAxisType ? val.minAxisType : this.minAxisType; this.minAxisType = null !== val.minAxisType ? val.minAxisType : this.minAxisType;
this.maxAxisType = null !== val.maxAxisType ? val.maxAxisType : this.maxAxisType; this.maxAxisType = null !== val.maxAxisType ? val.maxAxisType : this.maxAxisType;
this.rightToLeft = null !== val.rightToLeft ? val.rightToLeft : this.rightToLeft; this.rightToLeft = null !== val.rightToLeft ? val.rightToLeft : this.rightToLeft;
this.manualMax = null !== val.manualMax ? val.manualMax : this.manualMax;
this.manualMin = null !== val.manualMin ? val.manualMin : this.manualMin;
var getColor = function (color) { var getColor = function (color) {
return color instanceof Asc.asc_CColor ? AscCommonExcel.CorrectAscColor(color) : color; return color instanceof Asc.asc_CColor ? AscCommonExcel.CorrectAscColor(color) : color;
...@@ -4693,8 +4695,6 @@ CellArea.prototype = { ...@@ -4693,8 +4695,6 @@ CellArea.prototype = {
sparklineGroup.prototype.clone = function (onlyProps) { sparklineGroup.prototype.clone = function (onlyProps) {
var res = new sparklineGroup(!onlyProps); var res = new sparklineGroup(!onlyProps);
res.Id = this.Id; res.Id = this.Id;
res.manualMax = this.manualMax;
res.manualMin = this.manualMin;
res.lineWeight = this.lineWeight; res.lineWeight = this.lineWeight;
res.type = this.type; res.type = this.type;
res.dateAxis = this.dateAxis; res.dateAxis = this.dateAxis;
...@@ -4710,6 +4710,8 @@ CellArea.prototype = { ...@@ -4710,6 +4710,8 @@ CellArea.prototype = {
res.minAxisType = this.minAxisType; res.minAxisType = this.minAxisType;
res.maxAxisType = this.maxAxisType; res.maxAxisType = this.maxAxisType;
res.rightToLeft = this.rightToLeft; res.rightToLeft = this.rightToLeft;
res.manualMax = this.manualMax;
res.manualMin = this.manualMin;
res.colorSeries = this.colorSeries ? this.colorSeries.clone() : null; res.colorSeries = this.colorSeries ? this.colorSeries.clone() : null;
res.colorNegative = this.colorNegative ? this.colorNegative.clone() : null; res.colorNegative = this.colorNegative ? this.colorNegative.clone() : null;
...@@ -4810,6 +4812,12 @@ CellArea.prototype = { ...@@ -4810,6 +4812,12 @@ CellArea.prototype = {
sparklineGroup.prototype.asc_getRightToLeft = function () { sparklineGroup.prototype.asc_getRightToLeft = function () {
return this.rightToLeft; return this.rightToLeft;
}; };
sparklineGroup.prototype.asc_getManualMax = function () {
return this.manualMax;
};
sparklineGroup.prototype.asc_getManualMin = function () {
return this.manualMin;
};
sparklineGroup.prototype.asc_getColorSeries = function () { sparklineGroup.prototype.asc_getColorSeries = function () {
return this.colorSeries ? Asc.colorObjToAscColor(this.colorSeries) : this.colorSeries; return this.colorSeries ? Asc.colorObjToAscColor(this.colorSeries) : this.colorSeries;
}; };
...@@ -4876,6 +4884,12 @@ CellArea.prototype = { ...@@ -4876,6 +4884,12 @@ CellArea.prototype = {
sparklineGroup.prototype.asc_setRightToLeft = function (val) { sparklineGroup.prototype.asc_setRightToLeft = function (val) {
this.rightToLeft = val; this.rightToLeft = val;
}; };
sparklineGroup.prototype.asc_setManualMax = function (val) {
this.manualMax = val;
};
sparklineGroup.prototype.asc_setManualMin = function (val) {
this.manualMin = val;
};
sparklineGroup.prototype.asc_setColorSeries = function (val) { sparklineGroup.prototype.asc_setColorSeries = function (val) {
this.colorSeries = val; this.colorSeries = val;
}; };
...@@ -7259,6 +7273,8 @@ function getCurrencyFormat(opt_cultureInfo, opt_fraction, opt_currency, opt_curr ...@@ -7259,6 +7273,8 @@ function getCurrencyFormat(opt_cultureInfo, opt_fraction, opt_currency, opt_curr
prot["asc_getMinAxisType"] = prot.asc_getMinAxisType; prot["asc_getMinAxisType"] = prot.asc_getMinAxisType;
prot["asc_getMaxAxisType"] = prot.asc_getMaxAxisType; prot["asc_getMaxAxisType"] = prot.asc_getMaxAxisType;
prot["asc_getRightToLeft"] = prot.asc_getRightToLeft; prot["asc_getRightToLeft"] = prot.asc_getRightToLeft;
prot["asc_getManualMax"] = prot.asc_getManualMax;
prot["asc_getManualMin"] = prot.asc_getManualMin;
prot["asc_getColorSeries"] = prot.asc_getColorSeries; prot["asc_getColorSeries"] = prot.asc_getColorSeries;
prot["asc_getColorNegative"] = prot.asc_getColorNegative; prot["asc_getColorNegative"] = prot.asc_getColorNegative;
prot["asc_getColorAxis"] = prot.asc_getColorAxis; prot["asc_getColorAxis"] = prot.asc_getColorAxis;
...@@ -7281,6 +7297,8 @@ function getCurrencyFormat(opt_cultureInfo, opt_fraction, opt_currency, opt_curr ...@@ -7281,6 +7297,8 @@ function getCurrencyFormat(opt_cultureInfo, opt_fraction, opt_currency, opt_curr
prot["asc_setMinAxisType"] = prot.asc_setMinAxisType; prot["asc_setMinAxisType"] = prot.asc_setMinAxisType;
prot["asc_setMaxAxisType"] = prot.asc_setMaxAxisType; prot["asc_setMaxAxisType"] = prot.asc_setMaxAxisType;
prot["asc_setRightToLeft"] = prot.asc_setRightToLeft; prot["asc_setRightToLeft"] = prot.asc_setRightToLeft;
prot["asc_setManualMax"] = prot.asc_setManualMax;
prot["asc_setManualMin"] = prot.asc_setManualMin;
prot["asc_setColorSeries"] = prot.asc_setColorSeries; prot["asc_setColorSeries"] = prot.asc_setColorSeries;
prot["asc_setColorNegative"] = prot.asc_setColorNegative; prot["asc_setColorNegative"] = prot.asc_setColorNegative;
prot["asc_setColorAxis"] = prot.asc_setColorAxis; prot["asc_setColorAxis"] = prot.asc_setColorAxis;
......
...@@ -691,7 +691,7 @@ CSparklineView.prototype.initFromSparkline = function(oSparkline, oSparklineGrou ...@@ -691,7 +691,7 @@ CSparklineView.prototype.initFromSparkline = function(oSparkline, oSparklineGrou
var val_ax_props = new AscCommon.asc_ValAxisSettings(); var val_ax_props = new AscCommon.asc_ValAxisSettings();
if(settings.type !== c_oAscChartTypeSettings.barStackedPer) if(settings.type !== c_oAscChartTypeSettings.barStackedPer)
{ {
if(oSparklineGroup.minAxisType === Asc.c_oAscSparklineAxisMinMax.Custom && oSparklineGroup.manualMin != null) if(oSparklineGroup.minAxisType === Asc.c_oAscSparklineAxisMinMax.Custom && oSparklineGroup.manualMin !== null)
{ {
val_ax_props.putMinValRule(c_oAscValAxisRule.fixed); val_ax_props.putMinValRule(c_oAscValAxisRule.fixed);
val_ax_props.putMinVal(oSparklineGroup.manualMin); val_ax_props.putMinVal(oSparklineGroup.manualMin);
...@@ -700,7 +700,7 @@ CSparklineView.prototype.initFromSparkline = function(oSparkline, oSparklineGrou ...@@ -700,7 +700,7 @@ CSparklineView.prototype.initFromSparkline = function(oSparkline, oSparklineGrou
{ {
val_ax_props.putMinValRule(c_oAscValAxisRule.auto); val_ax_props.putMinValRule(c_oAscValAxisRule.auto);
} }
if(oSparklineGroup.maxAxisType === Asc.c_oAscSparklineAxisMinMax.Custom && oSparklineGroup.manualMax != null) if(oSparklineGroup.maxAxisType === Asc.c_oAscSparklineAxisMinMax.Custom && oSparklineGroup.manualMax !== null)
{ {
val_ax_props.putMinValRule(c_oAscValAxisRule.fixed); val_ax_props.putMinValRule(c_oAscValAxisRule.fixed);
val_ax_props.putMinVal(oSparklineGroup.manualMax); val_ax_props.putMinVal(oSparklineGroup.manualMax);
......
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