| | |
| | | package com.ruoyi.other.controller; |
| | | |
| | | |
| | | import com.ruoyi.common.core.web.controller.BaseController; |
| | | import com.ruoyi.common.core.web.domain.AjaxResult; |
| | | import com.ruoyi.other.api.domain.Goods; |
| | | import com.ruoyi.other.service.SeckillActivityInfoService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PathVariable; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | * @author luodangjia |
| | | * @since 2024-11-20 |
| | | */ |
| | | @Api(tags = "秒杀活动信息") |
| | | @RestController |
| | | @RequestMapping("/seckill-activity-info") |
| | | public class SeckillActivityInfoController { |
| | | public class SeckillActivityInfoController extends BaseController { |
| | | @Resource |
| | | private SeckillActivityInfoService seckillActivityInfoService; |
| | | |
| | | /** |
| | | * 秒杀活动列表 |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperation(value = "秒杀活动列表",tags = {"小程序-商城-首页-秒杀活动列表"}) |
| | | public AjaxResult list(Goods goods) |
| | | { |
| | | startPage(); |
| | | return AjaxResult.success(seckillActivityInfoService.listSeckillActivity(goods)); |
| | | } |
| | | |
| | | /** |
| | | * 秒杀活动详情 |
| | | */ |
| | | @GetMapping("/detail/{id}") |
| | | @ApiOperation(value = "秒杀活动详情", tags = {"小程序-商城-首页-秒杀活动列表-秒杀活动详情"}) |
| | | public AjaxResult detail(@PathVariable("id") Integer id) |
| | | { |
| | | return AjaxResult.success(seckillActivityInfoService.detail(id)); |
| | | } |
| | | |
| | | } |
| | | |