提交 dfcaf45c 编写于 作者: 221900223吴良杰's avatar 221900223吴良杰

我的收藏Controller层

上级 fb7c2ebf
package com.nav.controller;
import com.nav.common.api.CommonResult;
import com.nav.service.CollectionListService;
import com.nav.vo.result.CollectionListResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
/**
* @ClassName CollectionListController
* @Description CollectionList的Controller层
* @Date 2022/4/29 18:05
* @Author wlj
*/
@RestController
@RequestMapping("/my/collection")
public class CollectionListController {
@Autowired
CollectionListService collectionListService;
public List<CollectionListResult> getLifePostById(@PathVariable long userId) {
return collectionListService.selectLifePostListById(userId);
}
}
package com.nav.service;
import com.nav.vo.result.CollectionListResult;
import org.springframework.stereotype.Service;
import java.util.List;
......@@ -10,6 +11,7 @@ import java.util.List;
* @Date 2022/4/29 17:46
* @Author wlj
*/
@Service
public class CollectionListServiceImpl implements CollectionListService{
private CollectionListService collectionListService;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册