“mitao”
2026-02-26 7e0a3c88a82f16071da480fd2be79ac491dca9e4
xp-robotaxi-operation-boot/src/main/java/com/xiaopeng/operation/controller/XpCouponController.java
@@ -8,12 +8,9 @@
import com.xiaopeng.operation.service.IXpCouponService;
import com.xiaopeng.operation.vo.XpBannerListVo;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.*;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestParam;
import java.util.List;
@@ -25,7 +22,7 @@
 * @author mitao
 * @since 2026-02-03
 */
@Controller
@RestController
@RequestMapping("")
public class XpCouponController {
@@ -47,7 +44,7 @@
     * 优惠券列表
     */
    @PostMapping("/v1/api/xp-coupon/list")
    @ApiOperation(value = "优惠券列表",tags = {"管理后台-优惠券列表"},response = XpCoupon.class)
    @ApiOperation(value = "优惠券列表",tags = {"管理后台-优惠券"},response = XpCoupon.class)
    public R<Page<XpCoupon>> list(@RequestBody XpCouponListQuery query ){
        return R.ok(xpCouponService.getList(query));
    }
@@ -61,7 +58,7 @@
     * @return
     */
    @PostMapping("/v1/api/xp-coupon/add")
    @ApiOperation(value = "添加优惠券",tags = {"管理后台-添加优惠券"},response = XpCoupon.class)
    @ApiOperation(value = "添加优惠券",tags = {"管理后台-优惠券"},response = XpCoupon.class)
    public R<?> add(@RequestBody XpCoupon xpCoupon){
        xpCouponService.save(xpCoupon);
        return R.ok();