|
|
@@ -146,7 +146,7 @@ public class DataCountService {
|
|
|
|
|
|
public EnterpriseEconomicCount(List<EnterpriseEconomic> enterpriseEconomicList) {
|
|
|
for (EnterpriseEconomic enterpriseEconomic : enterpriseEconomicList) {
|
|
|
- tax = tax.add(Optional.ofNullable(enterpriseEconomic.getCApprovedOutputValue()).orElse(BigDecimal.ZERO));
|
|
|
+ tax = tax.add(Optional.ofNullable(enterpriseEconomic.getCApprovedTax()).orElse(BigDecimal.ZERO));
|
|
|
product = product.add(Optional.ofNullable(enterpriseEconomic.getCApprovedOutputValue()).orElse(BigDecimal.ZERO));
|
|
|
revenue = revenue.add(Optional.ofNullable(enterpriseEconomic.getCApprovedRevenue()).orElse(BigDecimal.ZERO));
|
|
|
}
|
|
|
@@ -443,11 +443,6 @@ public class DataCountService {
|
|
|
}
|
|
|
|
|
|
}
|
|
|
- List<String> sortedEnterprise = aliveEnterprise.stream().sorted((a, b) -> {
|
|
|
- BigDecimal ar = economicCountBy12Month.get(a).revenue;
|
|
|
- BigDecimal br = economicCountBy12Month.get(b).revenue;
|
|
|
- return ar.compareTo(br) * -1;
|
|
|
- }).limit(10).collect(Collectors.toList());
|
|
|
|
|
|
JSONObject parkDataCount = new JSONObject();
|
|
|
parkDataCount.put("totalTax", allTaxByYtdThisYear);
|
|
|
@@ -463,12 +458,22 @@ public class DataCountService {
|
|
|
parkDataCount.put("enterPriseIndustry", enterPriceIndustryCount);
|
|
|
|
|
|
JSONArray topRevenue = new JSONArray();
|
|
|
+ List<String> sortedEnterprise = aliveEnterprise.stream().sorted((a, b) -> {
|
|
|
+ BigDecimal ar = economicCountBy12Month.get(a).revenue;
|
|
|
+ BigDecimal br = economicCountBy12Month.get(b).revenue;
|
|
|
+ return ar.compareTo(br) * -1;
|
|
|
+ }).limit(10).collect(Collectors.toList());
|
|
|
for (String enterPriseCode : sortedEnterprise) {
|
|
|
JSONObject outPut = new JSONObject();
|
|
|
Enterprise enterPrice = aliveEnterpriseMap.get(enterPriseCode);
|
|
|
+ BigDecimal product = economicCountBy12Month.get(enterPriseCode).product;
|
|
|
outPut.put("enterPriceCode", enterPriseCode);
|
|
|
outPut.put("enterPriceName", enterPrice.getCEnterpriseName());
|
|
|
- outPut.put("enterPriceRevenue", economicCountBy12Month.get(enterPriseCode).revenue);
|
|
|
+ if (product.compareTo(BigDecimal.ZERO)==0){
|
|
|
+ outPut.put("enterPriceRevenue","暂无");
|
|
|
+ }else {
|
|
|
+ outPut.put("enterPriceRevenue",product);
|
|
|
+ }
|
|
|
topRevenue.add(outPut);
|
|
|
}
|
|
|
|