package com.atguigu.tingshu.album; import com.atguigu.tingshu.album.impl.AlbumDegradeFeignClient; import com.atguigu.tingshu.common.result.Result; import com.atguigu.tingshu.model.album.AlbumInfo; import com.atguigu.tingshu.model.album.BaseCategory1; import com.atguigu.tingshu.model.album.BaseCategory3; import com.atguigu.tingshu.model.album.BaseCategoryView; import com.atguigu.tingshu.vo.album.AlbumStatVo; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import java.util.List; /** *

* 专辑模块远程调用Feign接口 *

* * @author atguigu */ @FeignClient(value = "service-album",path = "api/album",fallback = AlbumDegradeFeignClient.class) public interface AlbumFeignClient { /** * 查询所有一级分类列表 * * @return */ @GetMapping("/category/findAllCategory1") public Result> getAllCategory1(); @GetMapping("/albumInfo/getAlbumInfo/{id}") public Result getAlbumInfo(@PathVariable("id") Long id); /** * 根据三级分类ID查询分类信息 * @param category3Id * @return */ @GetMapping("/category/getCategoryView/{category3Id}") public Result getCategoryView(@PathVariable("category3Id") Long category3Id); @GetMapping("/category/findTopBaseCategory3/{category1Id}") public Result> findTopBaseCategory3(@PathVariable("category1Id") Long category1Id); /** * 根据专辑ID查询专辑统计信息 * @param albumId * @return */ @GetMapping("/albumInfo/getAlbumStatVo/{albumId}") public Result getAlbumStatVo(@PathVariable("albumId") Long albumId); }