|
@@ -1,12 +1,18 @@
|
|
|
package com.chelvc.cloud.maintain.controller;
|
|
|
|
|
|
+import javax.validation.Valid;
|
|
|
import javax.validation.constraints.Min;
|
|
|
|
|
|
+import com.chelvc.cloud.maintain.vo.FavoriteVO;
|
|
|
+import com.chelvc.cloud.vehicle.api.constant.FavoriteType;
|
|
|
+import com.chelvc.cloud.vehicle.api.param.FavoritePagingParam;
|
|
|
import com.chelvc.cloud.vehicle.api.service.FavoriteService;
|
|
|
import com.chelvc.framework.base.annotation.ResponseWrapping;
|
|
|
+import com.chelvc.framework.common.model.Pagination;
|
|
|
import org.apache.dubbo.config.annotation.DubboReference;
|
|
|
import org.springframework.validation.annotation.Validated;
|
|
|
import org.springframework.web.bind.annotation.DeleteMapping;
|
|
|
+import org.springframework.web.bind.annotation.GetMapping;
|
|
|
import org.springframework.web.bind.annotation.PathVariable;
|
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
@@ -32,4 +38,19 @@ public class FavoriteController {
|
|
|
public void deleteMineFavorite(@PathVariable("id") @Min(value = 1, message = "收藏ID不能小于1") Long id) {
|
|
|
this.favoriteService.deleteMineFavorite(id);
|
|
|
}
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 查询用户收藏列表
|
|
|
+ *
|
|
|
+ * @param param 查询参数
|
|
|
+ * @return 收藏分页信息
|
|
|
+ */
|
|
|
+ @GetMapping("/favorite/paging")
|
|
|
+ public Pagination<FavoriteVO> getFavoritePaging(@Valid FavoritePagingParam param) {
|
|
|
+ // 查询收藏的店铺
|
|
|
+ if (FavoriteType.MERCHANT.equals(param.getType())) {
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+ return null;
|
|
|
+ }
|
|
|
}
|