package com.ruoyi.other.api.feignClient;
|
|
import com.ruoyi.common.core.constant.ServiceNameConstants;
|
import com.ruoyi.common.core.domain.R;
|
import com.ruoyi.other.api.domain.Goods;
|
import com.ruoyi.other.api.factory.GoodsClientFallbackFactory;
|
import org.springframework.cloud.openfeign.FeignClient;
|
import org.springframework.web.bind.annotation.PostMapping;
|
import org.springframework.web.bind.annotation.RequestParam;
|
|
import java.util.List;
|
|
/**
|
* @author zhibing.pu
|
* @Date 2024/11/27 19:56
|
*/
|
@FeignClient(contextId = "GoodsClient", value = ServiceNameConstants.OTHER_SERVICE, fallbackFactory = GoodsClientFallbackFactory.class)
|
public interface GoodsClient{
|
|
|
/**
|
* 根据类型(1=服务商品,2=单品商品)获取商品数据
|
* @param type
|
* @return
|
*/
|
@PostMapping("/goods/getGoodsByType")
|
R<List<Goods>> getGoodsByType(@RequestParam("type") Integer type);
|
|
}
|