瀏覽代碼

单机性能等级评估修改

wangchangsheng 2 年之前
父節點
當前提交
c1d75d0d1b

+ 4 - 0
web/runeconomy-xk/src/main/java/com/gyee/runeconomy/dto/response/EconHomePagePointRateDTO.java

@@ -362,6 +362,10 @@ public class EconHomePagePointRateDTO {
             a = new BigDecimal(100);
             ;
         }
+
+        if (a.compareTo(BigDecimal.ZERO) == -1) {
+            a = new BigDecimal(0);
+        }
         return a;
 
     }

+ 6 - 1
web/runeconomy-xk/src/main/java/com/gyee/runeconomy/service/auto/impl/ProEconEquipmentInfoDayTopServiceImpl.java

@@ -91,7 +91,9 @@ public class ProEconEquipmentInfoDayTopServiceImpl extends ServiceImpl<ProEconEq
 
 
         List<ProEconEquipmentInfoDayTop> list = baseMapper.selectList(qw);
-
+        list.stream().forEach(i->{
+            i.setNemCode(CacheContext.wtmap.get(i.getWindturbineId()).getAname());
+        });
         return list;
     }
 
@@ -106,6 +108,9 @@ public class ProEconEquipmentInfoDayTopServiceImpl extends ServiceImpl<ProEconEq
             qw.lambda().in(ProEconEquipmentInfoDayTop::getId, ids);
         }
         List<ProEconEquipmentInfoDayTop> list = baseMapper.selectList(qw);
+        list.stream().forEach(i->{
+            i.setNemCode(CacheContext.wtmap.get(i.getWindturbineId()).getAname());
+        });
         resultMap.put("data", list);
 
         List<CompareVo> compareList = new ArrayList<>();