summaryrefslogtreecommitdiffstats
path: root/ecomp-sdk/epsdk-analytics/src
diff options
context:
space:
mode:
Diffstat (limited to 'ecomp-sdk/epsdk-analytics/src')
-rw-r--r--ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/model/runtime/ChartD3Helper.java2
-rw-r--r--ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/model/runtime/ChartJSON.java9
-rw-r--r--ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/system/fusion/web/RaptorControllerAsync.java10
3 files changed, 19 insertions, 2 deletions
diff --git a/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/model/runtime/ChartD3Helper.java b/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/model/runtime/ChartD3Helper.java
index 22602e03..698d52a5 100644
--- a/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/model/runtime/ChartD3Helper.java
+++ b/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/model/runtime/ChartD3Helper.java
@@ -1074,7 +1074,7 @@ public class ChartD3Helper {
} else {
wholeScript.append(" .rotateLabels(\"0\") \n ");
}
- //wholeScript.append(" .axisLabel('" + legendColumnName + "')");
+ wholeScript.append(" .axisLabel('" + legendColumnName + "')");
if(flagNoDate == 1 || !timeAxis) {
wholeScript.append(";\n");
} else {
diff --git a/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/model/runtime/ChartJSON.java b/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/model/runtime/ChartJSON.java
index 8ec6bc19..66bce17a 100644
--- a/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/model/runtime/ChartJSON.java
+++ b/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/model/runtime/ChartJSON.java
@@ -130,6 +130,8 @@ public class ChartJSON {
this.hasCategoryAxis = hasCategoryAxis;
}
private ArrayList <RangeAxisJSON> rangeAxisList;
+ private ArrayList <RangeAxisJSON> rangeAxisRemoveList;
+
private ArrayList <ArrayList<Row>> wholeList;
private String primaryAxisLabel;
@@ -447,5 +449,12 @@ public class ChartJSON {
else
return "";
}
+ public ArrayList<RangeAxisJSON> getRangeAxisRemoveList() {
+ return rangeAxisRemoveList;
+ }
+ public void setRangeAxisRemoveList(ArrayList<RangeAxisJSON> rangeAxisRemoveList) {
+ this.rangeAxisRemoveList = rangeAxisRemoveList;
+ }
+
}
diff --git a/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/system/fusion/web/RaptorControllerAsync.java b/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/system/fusion/web/RaptorControllerAsync.java
index 0194b52d..48fdbe4c 100644
--- a/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/system/fusion/web/RaptorControllerAsync.java
+++ b/ecomp-sdk/epsdk-analytics/src/main/java/org/openecomp/portalsdk/analytics/system/fusion/web/RaptorControllerAsync.java
@@ -29,6 +29,7 @@ import java.lang.reflect.Method;
import java.util.ArrayList;
import java.util.Enumeration;
import java.util.HashMap;
+import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
@@ -1276,6 +1277,10 @@ public class RaptorControllerAsync extends RestrictedBaseController {
ArrayList<RangeAxisJSON> rangeAxisList = chartJSON.getRangeAxisList();
int r = 0;
+ HashSet<String> removeRangeAxisMap = new HashSet<>();
+ for(RangeAxisJSON rangeAxis:chartJSON.getRangeAxisRemoveList()){
+ removeRangeAxisMap.add(rangeAxis.getRangeAxis());
+ }
for (int i = 0; i < rangeAxisList.size(); i++) {
RangeAxisJSON rangeAxisJSON = rangeAxisList.get(i);
String rangeAxis = rangeAxisJSON.getRangeAxis();
@@ -1287,7 +1292,10 @@ public class RaptorControllerAsync extends RestrictedBaseController {
rangefor: for (Iterator<DataColumnType> iterator = reportCols.iterator(); iterator.hasNext();) {
DataColumnType dct = (DataColumnType) iterator.next();
if (dct.getColId().equals(rangeAxis)) {
- dct.setChartSeq(++r);
+ if(removeRangeAxisMap.contains(rangeAxis))
+ dct.setChartSeq(-1); // if we set it to -1, means this range axis will not be included
+ else
+ dct.setChartSeq(++r);
dct.setColOnChart("0");
dct.setYAxis(rangeYAxis); // +"|"+dct.getColId());
dct.setChartGroup(rangeChartGroup); // +"|"+dct.getColId());