From ceab91b902892caa183cb10d7749d15018b040bc Mon Sep 17 00:00:00 2001
From: java110 <928255095@qq.com>
Date: 星期六, 20 八月 2022 17:29:41 +0800
Subject: [PATCH] 优化common

---
 springboot/src/main/java/com/java110/boot/smo/impl/ApiServiceSMOImpl.java |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/springboot/src/main/java/com/java110/boot/smo/impl/ApiServiceSMOImpl.java b/springboot/src/main/java/com/java110/boot/smo/impl/ApiServiceSMOImpl.java
index e8f1825..7139828 100644
--- a/springboot/src/main/java/com/java110/boot/smo/impl/ApiServiceSMOImpl.java
+++ b/springboot/src/main/java/com/java110/boot/smo/impl/ApiServiceSMOImpl.java
@@ -162,7 +162,7 @@
                 || "file.getFile".equals(serviceCode)
                 || "file.getFileByObjId".equals(serviceCode)
                 || "/machine/heartbeat".equals(serviceCode) // 蹇冭烦涔熶笉璁板綍
-        ) {
+                ) {
             return;
         }
 
@@ -453,7 +453,9 @@
                 }
                 responseEntity = outRestTemplate.exchange(requestUrl, HttpMethod.DELETE, httpEntity, String.class);
             } else {
-                responseEntity = outRestTemplate.exchange(service.getUrl(), HttpMethod.POST, httpEntity, String.class);
+
+                String requestUrl = BootReplaceUtil.replaceServiceName(service.getUrl());
+                responseEntity = outRestTemplate.exchange(requestUrl, HttpMethod.POST, httpEntity, String.class);
             }
         } catch (HttpStatusCodeException e) { //杩欓噷spring 妗嗘灦 鍦�4XX 鎴� 5XX 鏃舵姏鍑� HttpServerErrorException 寮傚父锛岄渶瑕侀噸鏂板皝瑁呬竴涓�
             responseEntity = new ResponseEntity<String>(e.getResponseBodyAsString(), e.getStatusCode());

--
Gitblit v1.8.0