From 4c92629166ff9c01bce2815faf9ba9c41a4e03cd Mon Sep 17 00:00:00 2001 From: luodangjia <luodangjia> Date: 星期四, 28 十一月 2024 17:15:20 +0800 Subject: [PATCH] 11.28 --- ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/CouponInfoController.java | 18 ++++++++++++++++++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/CouponInfoController.java b/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/CouponInfoController.java index e63b87b..a8a2b4d 100644 --- a/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/CouponInfoController.java +++ b/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/CouponInfoController.java @@ -1,8 +1,17 @@ package com.ruoyi.other.controller; +import com.ruoyi.common.core.domain.R; +import com.ruoyi.other.api.domain.Banner; +import com.ruoyi.other.api.domain.CouponInfo; +import com.ruoyi.other.service.CouponInfoService; +import io.swagger.annotations.ApiOperation; +import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.RestController; + +import javax.annotation.Resource; /** * <p> @@ -15,6 +24,15 @@ @RestController @RequestMapping("/coupon-info") public class CouponInfoController { + @Resource + private CouponInfoService couponInfoService; + //查看详情 + @PostMapping("/detail") + @ApiOperation(value = "详情", tags = {"后台-优惠劵"}) + public R<CouponInfo> detail(@RequestParam("id") Integer id){ + CouponInfo byId = couponInfoService.getById(id); + return R.ok(byId); + } } -- Gitblit v1.7.1