|
@@ -6,6 +6,7 @@ import com.alibaba.fastjson.JSONObject;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
|
+import org.springframework.http.client.SimpleClientHttpRequestFactory;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
import org.springframework.web.client.RestTemplate;
|
|
@@ -55,7 +56,13 @@ public class DismissService {
|
|
|
params.put("hospital_id", SiUtil.INSTITUTION_ID);
|
|
|
params.put("scene_type", "6");
|
|
|
params.put("visit_id", visitId);
|
|
|
- JSONObject response = new RestTemplate().postForObject(url, params, JSONObject.class);
|
|
|
+
|
|
|
+
|
|
|
+ SimpleClientHttpRequestFactory requestFactory = new SimpleClientHttpRequestFactory();
|
|
|
+ requestFactory.setConnectTimeout(5000);
|
|
|
+ requestFactory.setReadTimeout(5000);
|
|
|
+
|
|
|
+ JSONObject response = new RestTemplate(requestFactory).postForObject(url, params, JSONObject.class);
|
|
|
log.info("创智出院预审:【{}】,【{}】", visitId, response);
|
|
|
if (null == response) {
|
|
|
return ResultVoUtil.success();
|