提交 c4891948 authored 作者: zgy's avatar zgy

优化restful风格显示

上级 ed39f37c
...@@ -138,7 +138,7 @@ public class TbCfStationItemController { ...@@ -138,7 +138,7 @@ public class TbCfStationItemController {
* @return * @return
*/ */
@ApiOperation("商品收藏") @ApiOperation("商品收藏")
@GetMapping("/itemCollection/{userId}/{itemId}") @PutMapping("/itemCollection/{userId}/{itemId}")
public Result itemCollection(@ApiParam(value = "用户ID") @PathVariable("userId") String userId, public Result itemCollection(@ApiParam(value = "用户ID") @PathVariable("userId") String userId,
@ApiParam(value = "商品ID") @PathVariable("itemId") String itemId) { @ApiParam(value = "商品ID") @PathVariable("itemId") String itemId) {
return tbCfStationItemService.itemCollection(userId, itemId); return tbCfStationItemService.itemCollection(userId, itemId);
......
...@@ -101,8 +101,8 @@ public class TbCfStationItemServiceImpl implements TbCfStationItemService { ...@@ -101,8 +101,8 @@ public class TbCfStationItemServiceImpl implements TbCfStationItemService {
List<PageHomeItems> pageHomeItemsList = new ArrayList<>(); List<PageHomeItems> pageHomeItemsList = new ArrayList<>();
try { try {
List<TbCfGoodstypeEntity> categoryList = tbCfGoodstypeDao.queryList(null); List<TbCfGoodstypeEntity> categoryList = tbCfGoodstypeDao.queryList(null);
PageHomeItems pageHomeItems = new PageHomeItems();
for (TbCfGoodstypeEntity category : categoryList) { for (TbCfGoodstypeEntity category : categoryList) {
PageHomeItems pageHomeItems = new PageHomeItems();
pageHomeItems.setCategoryId(category.getGoodstypeId()); pageHomeItems.setCategoryId(category.getGoodstypeId());
pageHomeItems.setCategoryName(category.getGoodstypeTitle()); pageHomeItems.setCategoryName(category.getGoodstypeTitle());
List<TbCfStationItemEntity> itemList = tbCfStationItemDao.getGoodsTypeList(category.getGoodstypeId()); List<TbCfStationItemEntity> itemList = tbCfStationItemDao.getGoodsTypeList(category.getGoodstypeId());
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论