|
@@ -482,7 +482,8 @@ public class IndexZcbServiceImpl implements IndexZcbService {
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
- resultEightCost.setName(entry.getKey()+"-"+mul+"%");
|
|
|
|
|
|
+ resultEightCost.setName(entry.getKey());
|
|
|
|
+ resultEightCost.setProportion(mul);
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultList.add(resultEightCost);
|
|
resultList.add(resultEightCost);
|
|
}
|
|
}
|
|
@@ -516,7 +517,8 @@ public class IndexZcbServiceImpl implements IndexZcbService {
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
- resultEightCost.setName(entry.getKey()+"-"+mul+"%");
|
|
|
|
|
|
+ resultEightCost.setName(entry.getKey());
|
|
|
|
+ resultEightCost.setProportion(mul);
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultList.add(resultEightCost);
|
|
resultList.add(resultEightCost);
|
|
}
|
|
}
|
|
@@ -545,7 +547,8 @@ public class IndexZcbServiceImpl implements IndexZcbService {
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
- resultEightCost.setName(entry.getKey()+"-"+mul+"%");
|
|
|
|
|
|
+ resultEightCost.setName(entry.getKey());
|
|
|
|
+ resultEightCost.setProportion(mul);
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultList.add(resultEightCost);
|
|
resultList.add(resultEightCost);
|
|
}
|
|
}
|
|
@@ -589,7 +592,8 @@ public class IndexZcbServiceImpl implements IndexZcbService {
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
- resultEightCost.setName(entry.getKey()+"-"+mul+"%");
|
|
|
|
|
|
+ resultEightCost.setName(entry.getKey());
|
|
|
|
+ resultEightCost.setProportion(mul);
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultList.add(resultEightCost);
|
|
resultList.add(resultEightCost);
|
|
}
|
|
}
|
|
@@ -615,7 +619,8 @@ public class IndexZcbServiceImpl implements IndexZcbService {
|
|
|
|
|
|
for (Map.Entry<String, BigDecimal> entry : sortedMap.entrySet()) {
|
|
for (Map.Entry<String, BigDecimal> entry : sortedMap.entrySet()) {
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
- resultEightCost.setName(entry.getKey()+"-0%");
|
|
|
|
|
|
+ resultEightCost.setName(entry.getKey());
|
|
|
|
+ resultEightCost.setProportion(BigDecimal.valueOf(0));
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultList.add(resultEightCost);
|
|
resultList.add(resultEightCost);
|
|
}
|
|
}
|
|
@@ -652,7 +657,8 @@ public class IndexZcbServiceImpl implements IndexZcbService {
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
- resultEightCost.setName(entry.getKey()+"-"+mul+"%");
|
|
|
|
|
|
+ resultEightCost.setName(entry.getKey());
|
|
|
|
+ resultEightCost.setProportion(mul);
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultList.add(resultEightCost);
|
|
resultList.add(resultEightCost);
|
|
}
|
|
}
|
|
@@ -685,7 +691,8 @@ public class IndexZcbServiceImpl implements IndexZcbService {
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
- resultEightCost.setName(entry.getKey()+"-"+mul+"%");
|
|
|
|
|
|
+ resultEightCost.setName(entry.getKey());
|
|
|
|
+ resultEightCost.setProportion(mul);
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultList.add(resultEightCost);
|
|
resultList.add(resultEightCost);
|
|
}
|
|
}
|
|
@@ -714,7 +721,8 @@ public class IndexZcbServiceImpl implements IndexZcbService {
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
- resultEightCost.setName(entry.getKey()+"-"+mul+"%");
|
|
|
|
|
|
+ resultEightCost.setName(entry.getKey());
|
|
|
|
+ resultEightCost.setProportion(mul);
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultList.add(resultEightCost);
|
|
resultList.add(resultEightCost);
|
|
}
|
|
}
|
|
@@ -758,7 +766,8 @@ public class IndexZcbServiceImpl implements IndexZcbService {
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal divide = entry.getValue().divide(sumZcb, 2, BigDecimal.ROUND_HALF_UP);
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
BigDecimal mul = divide.multiply(BigDecimal.valueOf(100));
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
- resultEightCost.setName(entry.getKey()+"-"+mul+"%");
|
|
|
|
|
|
+ resultEightCost.setName(entry.getKey());
|
|
|
|
+ resultEightCost.setProportion(mul);
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultList.add(resultEightCost);
|
|
resultList.add(resultEightCost);
|
|
}
|
|
}
|
|
@@ -784,7 +793,8 @@ public class IndexZcbServiceImpl implements IndexZcbService {
|
|
|
|
|
|
for (Map.Entry<String, BigDecimal> entry : sortedMap.entrySet()) {
|
|
for (Map.Entry<String, BigDecimal> entry : sortedMap.entrySet()) {
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
ResultEightCost resultEightCost = new ResultEightCost();
|
|
- resultEightCost.setName(entry.getKey()+"-0%");
|
|
|
|
|
|
+ resultEightCost.setName(entry.getKey());
|
|
|
|
+ resultEightCost.setProportion(BigDecimal.valueOf(0));
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultEightCost.setValue(entry.getValue());
|
|
resultList.add(resultEightCost);
|
|
resultList.add(resultEightCost);
|
|
}
|
|
}
|