夏文涛 пре 1 година
родитељ
комит
0fa3fa35b8
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      src/main/java/com/template/controller/WelcomeStudentController.java

+ 1 - 1
src/main/java/com/template/controller/WelcomeStudentController.java

@@ -1477,7 +1477,7 @@ public class WelcomeStudentController implements WelcomeStudentControllerAPI {
         DateTimeFormatter dateTimeFormatter1 = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
         Integer visitorTotal = welcomeVisitorService.countTotal(start, end);
         List<WelcomeSetting> wss = welcomeSettingService.list(null);
-        Integer carTotal = wss != null && wss.size() > 0 ? wss.get(0).getMxhCarNum() : 0;
+        Integer carTotal = wss != null && wss.size() > 0 ? (wss.get(0).getMxhCarNum() == null ? 0 : wss.get(0).getMxhCarNum()) : 0;
 
         StudentOverviewVo vo = new StudentOverviewVo();
         vo.setEnrollmentTotal(6532);