1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
package com.tanpu.community.controller;
import com.tanpu.common.api.CommonResp;
import com.tanpu.community.api.beans.qo.FollowQo;
import com.tanpu.community.api.beans.qo.feign.fatools.UserInfoCorpReq;
import com.tanpu.community.api.beans.req.page.Page;
import com.tanpu.community.api.beans.resp.HotRecommendResp;
import com.tanpu.community.service.HotRecommendService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;
import javax.annotation.Resource;
import java.util.List;
@RestController
@Slf4j
@Api(tags = "首页热门推荐")
public class HotRecommendController {
@Resource
private HotRecommendService hotRecommendService;
@GetMapping(value = "/hotRecommend")
@ApiOperation("首页热门推荐列表v2.2.10")
public CommonResp<List<HotRecommendResp>> hotRecommend() {
return CommonResp.success(hotRecommendService.hotRecommendList());
}
@PostMapping(value = "/hotRecommend/list")
@ApiOperation("首页热门推荐详情列表v2.2.10")
public CommonResp<Page<FollowQo>> hotRecommendList(@RequestBody UserInfoCorpReq req) {
return CommonResp.success(hotRecommendService.hotRecommendDetailList(req));
}
}