lipenghui 3 주 전
부모
커밋
4f9c7a2248
1개의 변경된 파일4개의 추가작업 그리고 1개의 파일을 삭제
  1. 4 1
      yudao-module-pms/yudao-module-pms-biz/src/main/java/cn/iocoder/yudao/module/pms/oa/OaFlow.java

+ 4 - 1
yudao-module-pms/yudao-module-pms-biz/src/main/java/cn/iocoder/yudao/module/pms/oa/OaFlow.java

@@ -25,6 +25,7 @@ import lombok.Data;
 import lombok.NoArgsConstructor;
 import org.apache.commons.lang3.StringUtils;
 import org.springframework.beans.BeanUtils;
+import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Value;
 import org.springframework.http.HttpEntity;
 import org.springframework.http.HttpHeaders;
@@ -225,6 +226,8 @@ public class OaFlow {
         }
     }
 
+    @Autowired
+    private RestTemplate restTemplate;
 
     public void createOutRepairFlow(IotMaintainDO iotMaintainDO) throws Exception {
         String token = getToken();
@@ -279,7 +282,7 @@ public class OaFlow {
         System.out.println("------------"+JSON.toJSONString(outRepairFlows));
         // 3. 组合请求头和请求体
         HttpEntity<MultiValueMap<String, Object>> requestEntityOut = new HttpEntity<>(params, headersOut);
-        RestTemplate restTemplate = SslSkippingRestTemplate.createRestTemplate();
+//        RestTemplate restTemplate = SslSkippingRestTemplate.createRestTemplate();
         String out = restTemplate.postForObject(outMaintainUrl, requestEntityOut, String.class);
         JSONObject outInfo = JSON.parseObject(out);
         //请求成功