|
@@ -453,7 +453,10 @@ public class UserTicketController extends BaseApiController {
|
|
|
* 根据盲票购买订单号查看盲票详情
|
|
|
*/
|
|
|
@PostMapping("/ticket/query")
|
|
|
- @ApiOperation(value = "查看盲票详情", notes = "根据盲票购买订单号,查看盲票详情")
|
|
|
+ @ApiOperation(value = "根据单号查看盲票详情", notes = "根据盲票购买订单号,查看盲票详情")
|
|
|
+ @ApiResponses(
|
|
|
+ @ApiResponse(code = 200, message = "success", response = TicketListVO.class)
|
|
|
+ )
|
|
|
public AjaxResult queryTicket(@RequestBody TicketParam param) {
|
|
|
Long userId = SecurityUtils.getLoginUser().getUserId();
|
|
|
if (StringUtils.isBlank(param.getOrderId())) {
|
|
@@ -462,6 +465,19 @@ public class UserTicketController extends BaseApiController {
|
|
|
|
|
|
TicketListVO ticketListVO = userTicketOrderItemService.queryTicketVO(userId,
|
|
|
param.getOrderId());
|
|
|
+
|
|
|
+ if (ticketListVO != null) {
|
|
|
+ // 设置奖项名
|
|
|
+ if (Objects.nonNull(ticketListVO.getPlainLuckyNum())) {
|
|
|
+ List<TicketDrawNumDTO> drawNumDTOList = JSONObject.parseArray(ticketListVO.getDrawNum(), TicketDrawNumDTO.class);
|
|
|
+ for (TicketDrawNumDTO ticketDrawNumDTO : drawNumDTOList) {
|
|
|
+ if (ticketDrawNumDTO.getNum() == ticketListVO.getPlainLuckyNum()) {
|
|
|
+ ticketListVO.setAwardsName(ticketDrawNumDTO.getName());
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
return AjaxResult.success(ticketListVO);
|
|
|
}
|
|
|
|