|
@@ -5,20 +5,15 @@ package com.bizmatics.mhfire.controller.web;
|
|
|
|
|
|
import com.bizmatics.common.core.exception.BusinessException;
|
|
|
import com.bizmatics.common.core.util.HttpUtils;
|
|
|
-
|
|
|
-
|
|
|
import com.bizmatics.common.core.util.StringUtils;
|
|
|
-import com.bizmatics.mhfire.service.vo.AlertStatisticsVO;
|
|
|
-import okhttp3.*;
|
|
|
-
|
|
|
-import org.springframework.web.bind.annotation.*;
|
|
|
-import org.springframework.web.bind.annotation.RequestBody;
|
|
|
+import org.springframework.web.bind.annotation.GetMapping;
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
import java.io.IOException;
|
|
|
import java.util.Date;
|
|
|
import java.util.HashMap;
|
|
|
import java.util.Map;
|
|
|
-import java.util.Optional;
|
|
|
|
|
|
/**
|
|
|
* @author yq
|
|
@@ -44,7 +39,7 @@ public class WeatherControllerWeb {
|
|
|
weather = getWeatherApi();
|
|
|
date = new Date();
|
|
|
}else {
|
|
|
- if ((System.currentTimeMillis() - date.getTime()) >= (1000 * 60 * 60)){
|
|
|
+ if ((System.currentTimeMillis() - date.getTime()) >= (1000 * 60 * 60 * 5)){
|
|
|
weather = getWeatherApi();
|
|
|
date = new Date();
|
|
|
}
|