package com.xcong.excoin.modules.home.controller; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RestController; import com.xcong.excoin.common.response.Result; import com.xcong.excoin.modules.home.dto.MemberQuickBuySaleCommitDto; import com.xcong.excoin.modules.home.dto.MemberQuickBuySaleDto; import com.xcong.excoin.modules.home.service.MemberQuickBuySaleService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; @RestController @RequestMapping(value = "/api/quick") @Api(value = "USDT快捷买卖类", tags = "USDT快捷买卖类") public class MemberQuickBuySaleController { @Autowired MemberQuickBuySaleService memberQuickBuySaleService; @ApiOperation(value = "USDT快速充值", notes = "USDT快速充值") @RequestMapping(value = "/recharge", method = RequestMethod.POST) public Result recharge(@RequestBody MemberQuickBuySaleDto memberQuickBuySaleDto) { return memberQuickBuySaleService.recharge(memberQuickBuySaleDto); } @ApiOperation(value = "USDT充值支付确认", notes = "USDT充值支付确认") @RequestMapping(value = "/commitPay", method = RequestMethod.POST) public Result commitPay(@RequestBody MemberQuickBuySaleCommitDto memberQuickBuySaleCommitDto) { return memberQuickBuySaleService.commitPay(memberQuickBuySaleCommitDto); } @ApiOperation(value = "查询单个买卖记录", notes = "查询单个买卖记录") @GetMapping(value = "/selectById/{id}") public Result selectById(@PathVariable(value = "id") Long id) { return memberQuickBuySaleService.selectById(id); } /** * 充值撤销 * * @param memberChargeUsdt * @param page * @param rows * @return */ @ApiOperation(value = "充值撤销", notes = "充值撤销") @GetMapping(value = "/cancel/{id}") public Result cancel(@PathVariable(value = "id") Long id) { return memberQuickBuySaleService.cancelRecharge(id); } }