From 970ed0f8df6a19e4e3dae062c4e2e2232a0b97d0 Mon Sep 17 00:00:00 2001 From: huanghongfa <huanghongfa123456> Date: 星期三, 21 四月 2021 11:06:45 +0800 Subject: [PATCH] 删除商家bug修复 --- springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/ShopApi.java | 43 +++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 41 insertions(+), 2 deletions(-) diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/ShopApi.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/ShopApi.java index 9706210..2d9054b 100644 --- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/ShopApi.java +++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/ShopApi.java @@ -8,7 +8,6 @@ import com.panzhihua.common.model.dtos.shop.PageComShopStoreDTO; import com.panzhihua.common.model.vos.R; import com.panzhihua.common.model.vos.shop.AddShopGoodsVO; -import com.panzhihua.service_community.model.dos.ComShopOrderDO; import com.panzhihua.service_community.service.*; import com.panzhihua.common.model.vos.shop.ShopOperLogVO; import com.panzhihua.common.model.vos.shop.ShopStoreVO; @@ -21,6 +20,7 @@ import org.springframework.web.bind.annotation.*; import javax.annotation.Resource; +import java.util.Date; import java.util.List; import javax.validation.constraints.NotNull; @@ -158,6 +158,7 @@ */ @PostMapping("/pageShopGoods") public R pageShopGoods(@RequestBody ComShopGoodsDTO comShopGoodsDTO) { + return comShopGoodsService.pageShopGoods(comShopGoodsDTO); } @@ -179,6 +180,16 @@ @PostMapping("shopCartList") public R shopCartList(@RequestParam("userId") Long userId) { return comShopCartService.shopCartList(userId); + } + + /** + * 查询用户购物车数量 + * @param userId 用户id + * @return 用户购物车商品数量 + */ + @PostMapping("shopCartUserTotal") + public R shopCartUserTotal(@RequestParam("userId") Long userId) { + return comShopCartService.shopCartUserTotal(userId); } /** @@ -360,6 +371,7 @@ * @param id 商铺Id * @return */ + @Transactional(rollbackFor = Exception.class) @PostMapping("editShopGoods/{id}") public R editShopGoods(@PathVariable("id") Long id,@RequestBody AddShopGoodsVO addShopGoodsVO) { return comShopGoodsService.editShopGoods(id, addShopGoodsVO); @@ -376,13 +388,23 @@ } /** - * 删除商品 + * 修改商品状态 * @param id * @return */ @GetMapping("changeShopGoodsStatus") public R changeStatus(@RequestParam("id") Long id,@RequestParam("status")Integer status) { return comShopGoodsService.changeStatus(id,status); + } + + /** + * 商家资金的订单详情 + * @param id + * @return + */ + @GetMapping("capitalDetailByStore") + public R capitalDetailByStore(@RequestParam("id") Long id) { + return comShopOrderService.capitalDetailByStore(id); } /** @@ -457,5 +479,22 @@ return comShopOrderService.pageShopFunds(pageComShopFundsSearchDTO); } + /** + * 微信支付订单回调 + * @param wxPayNotifyOrderDTO 订单支付回调参数 + */ + @PostMapping("/wxOrderPayNotify") + public void wxOrderPayNotify(@RequestBody WxPayNotifyOrderDTO wxPayNotifyOrderDTO){ + comShopOrderService.wxOrderPayNotify(wxPayNotifyOrderDTO); + } + /** + * 点击去支付订单 + * @param orderPayDTO 请求参数 + * @return 支付对象 + */ + @PostMapping("/wxPay") + public R wxPay(@RequestBody OrderPayDTO orderPayDTO){ + return comShopOrderService.wxPay(orderPayDTO); + } } -- Gitblit v1.7.1