|
|
@@ -1,10 +1,13 @@
|
|
|
package com.jzg.quotation.summary.controller;
|
|
|
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
import com.jzg.commons.core.page.HttpResult;
|
|
|
import com.jzg.quotation.summary.client.LocalLivingClient;
|
|
|
import com.jzg.quotation.summary.entity.Result;
|
|
|
import com.jzg.quotation.summary.entity.dto.*;
|
|
|
+import com.jzg.quotation.summary.entity.vo.ChannelCategoryVo;
|
|
|
+import com.jzg.quotation.summary.entity.vo.ChannelProductInfoVo;
|
|
|
import com.jzg.quotation.summary.entity.vo.ChannelRightsPackageVO;
|
|
|
import com.jzg.quotation.summary.entity.vo.ChannelRightsVO;
|
|
|
import io.swagger.v3.oas.annotations.Operation;
|
|
|
@@ -74,11 +77,11 @@ public class RightsGrantController {
|
|
|
|
|
|
@Operation(summary = "权益套餐-分页查询")
|
|
|
@PostMapping(value = "package/list")
|
|
|
- public HttpResult<IPage<ChannelRightsPackageVO>> queryRightsPackagePage(@RequestBody ChannelRightsPackageQueryDTO queryDTO) {
|
|
|
+ public HttpResult<Page<ChannelRightsPackageVO>> queryRightsPackagePage(@RequestBody ChannelRightsPackageQueryDTO queryDTO) {
|
|
|
//调生活服务平台
|
|
|
- Result<IPage<ChannelRightsPackageVO>> result = localLivingClient.queryRightsPackagePage(queryDTO);
|
|
|
+ Result<Page<ChannelRightsPackageVO>> result = localLivingClient.queryRightsPackagePage(queryDTO);
|
|
|
//把生活服务平台查询到的数据封装成返回jzg前端HttpResult对象
|
|
|
- HttpResult<IPage<ChannelRightsPackageVO>> rightsPackageResult = new HttpResult<>();
|
|
|
+ HttpResult<Page<ChannelRightsPackageVO>> rightsPackageResult = new HttpResult<>();
|
|
|
|
|
|
rightsPackageResult.setData(result.getResult());
|
|
|
rightsPackageResult.setCode(result.getCode());
|
|
|
@@ -107,14 +110,53 @@ public class RightsGrantController {
|
|
|
*/
|
|
|
@Operation(summary = "权益券-分页查询")
|
|
|
@PostMapping(value = "/rights/list")
|
|
|
- public HttpResult<IPage<ChannelRightsVO>> queryRightsPage(@RequestBody ChannelRightsQueryDTO queryDTO) {
|
|
|
+ public HttpResult<Page<ChannelRightsVO>> queryRightsPage(@RequestBody ChannelRightsQueryDTO queryDTO) {
|
|
|
//调生活服务平台
|
|
|
- Result<IPage<ChannelRightsVO>> result = localLivingClient.queryRightsPage(queryDTO);
|
|
|
+ Result<Page<ChannelRightsVO>> result = localLivingClient.queryRightsPage(queryDTO);
|
|
|
//把生活服务平台查询到的数据封装成返回jzg前端HttpResult对象
|
|
|
- HttpResult<IPage<ChannelRightsVO>> rightsResult = new HttpResult<>();
|
|
|
+ HttpResult<Page<ChannelRightsVO>> rightsResult = new HttpResult<>();
|
|
|
rightsResult.setData(result.getResult());
|
|
|
rightsResult.setCode(result.getCode());
|
|
|
rightsResult.setMsg(result.getMessage());
|
|
|
return rightsResult;
|
|
|
}
|
|
|
+
|
|
|
+ @Operation(summary = "权益券-分类查询")
|
|
|
+ @PostMapping(value = "/get/category/list")
|
|
|
+ public HttpResult<List<ChannelRightsCategoryDto>> getCategoryList() {
|
|
|
+ //调生活服务平台
|
|
|
+ Result<List<ChannelRightsCategoryDto>> result = localLivingClient.queryCategoryList();
|
|
|
+ //把生活服务平台查询到的数据封装成返回jzg前端HttpResult对象
|
|
|
+ HttpResult<List<ChannelRightsCategoryDto>> categoryResult = new HttpResult<>();
|
|
|
+ categoryResult.setData(result.getResult());
|
|
|
+ categoryResult.setCode(result.getCode());
|
|
|
+ categoryResult.setMsg(result.getMessage());
|
|
|
+ return categoryResult;
|
|
|
+ }
|
|
|
+
|
|
|
+ @Operation(summary = "权益券-二级分类查询")
|
|
|
+ @PostMapping(value = "/get/category")
|
|
|
+ public HttpResult<List<ChannelCategoryVo>> getCategory() {
|
|
|
+ //调生活服务平台
|
|
|
+ Result<List<ChannelCategoryVo>> result = localLivingClient.queryCategory();
|
|
|
+ //把生活服务平台查询到的数据封装成返回jzg前端HttpResult对象
|
|
|
+ HttpResult<List<ChannelCategoryVo>> categoryResult = new HttpResult<>();
|
|
|
+ categoryResult.setData(result.getResult());
|
|
|
+ categoryResult.setCode(result.getCode());
|
|
|
+ categoryResult.setMsg(result.getMessage());
|
|
|
+ return categoryResult;
|
|
|
+ }
|
|
|
+
|
|
|
+ @Operation(summary = "权益券商品详情")
|
|
|
+ @PostMapping(value = "/get/product")
|
|
|
+ public HttpResult<List<ChannelProductInfoVo>> getProduct(@RequestBody ChannelProductInfoQueryDTO channelProductInfoQueryDTO) {
|
|
|
+ //调生活服务平台
|
|
|
+ Result<List<ChannelProductInfoVo>> channelApplicableStoresVo = localLivingClient.getProduct(channelProductInfoQueryDTO);
|
|
|
+ //把生活服务平台查询到的数据封装成返回jzg前端HttpResult对象
|
|
|
+ HttpResult<List<ChannelProductInfoVo>> productResult = new HttpResult<>();
|
|
|
+ productResult.setData(channelApplicableStoresVo.getResult());
|
|
|
+ productResult.setCode(channelApplicableStoresVo.getCode());
|
|
|
+ productResult.setMsg(channelApplicableStoresVo.getMessage());
|
|
|
+ return productResult;
|
|
|
+ }
|
|
|
}
|