From ac70afa4e394626dc03d82def3df1db886bb7c2e Mon Sep 17 00:00:00 2001 From: 陶杰 <1378534974@qq.com> Date: 星期四, 12 九月 2024 14:43:59 +0800 Subject: [PATCH] 1.活动优惠券-管理端-类型是首页领取的活动优惠券,发布的时候将已经发布的设置为下架,只能留有一个已发布的优惠券 3.活动优惠券-小程序-新增首页弹窗优惠券-如果领取数量没有超过当前优惠券还可以再次领取,超过领取优惠券的话则不返回数据 --- src/main/java/com/mzl/flower/web/customer/CustomerController.java | 16 ++++++++++------ 1 files changed, 10 insertions(+), 6 deletions(-) diff --git a/src/main/java/com/mzl/flower/web/customer/CustomerController.java b/src/main/java/com/mzl/flower/web/customer/CustomerController.java index 6001878..8b870c9 100644 --- a/src/main/java/com/mzl/flower/web/customer/CustomerController.java +++ b/src/main/java/com/mzl/flower/web/customer/CustomerController.java @@ -4,15 +4,11 @@ import com.mzl.flower.base.BaseController; import com.mzl.flower.base.R; import com.mzl.flower.base.ReturnDataDTO; -import com.mzl.flower.config.exception.ValidationException; import com.mzl.flower.config.security.SecurityUtils; import com.mzl.flower.dto.request.customer.BindPartnerDTO; import com.mzl.flower.dto.request.customer.ChangePartnerDTO; import com.mzl.flower.dto.request.customer.QueryCustomerDTO; import com.mzl.flower.dto.request.customer.UpdateCustomerDTO; -import com.mzl.flower.dto.request.supplier.AuditSupplierDTO; -import com.mzl.flower.dto.request.supplier.QuerySupplierDTO; -import com.mzl.flower.dto.request.supplier.UpdateSupplierDTO; import com.mzl.flower.dto.response.customer.CustomerDTO; import com.mzl.flower.dto.response.supplier.SupplierDTO; import com.mzl.flower.service.customer.CustomerService; @@ -24,6 +20,7 @@ import org.springframework.web.bind.annotation.*; import javax.validation.constraints.NotBlank; +import javax.validation.constraints.NotNull; @RestController @RequestMapping("/api/customer") @@ -82,7 +79,14 @@ @GetMapping("/partner/name") @ApiOperation(value = "商户(花店)详情", notes = "商户(花店)详情") - public ResponseEntity<ReturnDataDTO<SupplierDTO>> getPartnerName(@NotBlank(message = "参数不能为空") String partnerUserId) { - return returnData(R.SUCCESS.getCode(),customerService.getPartnerName(partnerUserId)); + public ResponseEntity<ReturnDataDTO<SupplierDTO>> getPartnerName(@NotBlank(message = "参数不能为空") String id) { + return returnData(R.SUCCESS.getCode(),customerService.getPartnerName(id)); + } + + @GetMapping("/page/isEnable") + @ApiOperation(value = "启用/禁用", notes = "启用/禁用商品") + public ResponseEntity<ReturnDataDTO<String>> isEnable(@NotNull(message = "id不能为空") Long id) { + customerService.isEnable(id); + return returnData(R.SUCCESS.getCode(),null); } } -- Gitblit v1.9.3