|
|
@@ -4,6 +4,7 @@ import com.fasterxml.jackson.core.JsonProcessingException;
|
|
|
import com.fasterxml.jackson.databind.ObjectMapper;
|
|
|
import com.ruoyi.api.constant.yz.ApiEnum;
|
|
|
import com.ruoyi.api.downstream.YzResult;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
|
import org.springframework.http.ResponseEntity;
|
|
|
import org.springframework.stereotype.Component;
|
|
|
@@ -12,9 +13,13 @@ import java.util.Objects;
|
|
|
|
|
|
@Component
|
|
|
public class YzResultProcessingUtil {
|
|
|
- @Value("${downstream.url}")
|
|
|
private static String url;
|
|
|
|
|
|
+ @Value("${downstream.url}")
|
|
|
+ public void setUrl(String url) {
|
|
|
+ YzResultProcessingUtil.url = url;
|
|
|
+ }
|
|
|
+
|
|
|
private static ObjectMapper objectMapper = new ObjectMapper();
|
|
|
|
|
|
public static YzResult getYzResult(ApiEnum apiEnum, Object bo) throws JsonProcessingException {
|