diff --git a/ai-analytic-center-biz/src/main/java/com/volvo/ai/analytic/center/controller/EGEventSubscriptionController.java b/ai-analytic-center-biz/src/main/java/com/volvo/ai/analytic/center/controller/EGEventSubscriptionController.java index feaf92f..81704e6 100644 --- a/ai-analytic-center-biz/src/main/java/com/volvo/ai/analytic/center/controller/EGEventSubscriptionController.java +++ b/ai-analytic-center-biz/src/main/java/com/volvo/ai/analytic/center/controller/EGEventSubscriptionController.java @@ -5,13 +5,17 @@ import com.huaweicloud.sdk.eg.v1.model.*; import com.volvo.ai.analytic.center.dto.event.ListSubscriptionsRequestDto; import com.volvo.ai.analytic.center.dto.event.SubscriptionCreateReqDto; import com.volvo.ai.analytic.center.dto.event.SubscriptionOperateReqDto; +import com.volvo.ai.analytic.center.dto.resp.CompetingBrrandsDTO; import com.volvo.ai.analytic.center.dto.resp.ResultDTO; +import com.volvo.ai.analytic.center.feign.CompetingBrandsClient; import com.volvo.ai.analytic.center.service.HuaWeiEGService; import io.swagger.v3.oas.annotations.Operation; import lombok.extern.slf4j.Slf4j; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; import javax.annotation.Resource; +import java.util.List; import java.util.concurrent.ExecutionException; /** @@ -25,6 +29,19 @@ public class EGEventSubscriptionController { @Resource HuaWeiEGService huaWeiService; + @Autowired + CompetingBrandsClient CompetingBrandsClient; + + @GetMapping("/getBrand") + public void getBrand(){ + ResultDTO> result = CompetingBrandsClient.getBrand(); + log.info("callback", JSON.toJSONString(result)); + } + @GetMapping("/getSeriesByBrandId") + public void getSeriesByBrandId(String brandId){ + ResultDTO> result = CompetingBrandsClient.getSeriesByBrandId(brandId); + log.info("callback", JSON.toJSONString(result)); + } @PostMapping("/callback") public void callback(@RequestBody Object req){ log.info("callback", JSON.toJSONString(req));