feat: 支持开奖重开与风险池原子扣减,完善投注部分成功流程
This commit is contained in:
@@ -25,7 +25,7 @@ final class TicketPreviewService
|
||||
if ($draw === null) {
|
||||
throw new TicketOperationException('draw_not_found', ErrorCode::BetInvalidDraw->value);
|
||||
}
|
||||
if ($draw->status !== DrawStatus::Open->value) {
|
||||
if ($draw->status !== DrawStatus::Open->value || ($draw->close_time !== null && now()->greaterThanOrEqualTo($draw->close_time))) {
|
||||
throw new TicketOperationException('draw_closed', ErrorCode::DrawClosed->value);
|
||||
}
|
||||
|
||||
@@ -47,6 +47,7 @@ final class TicketPreviewService
|
||||
'client_line_no' => $index + 1,
|
||||
'play_code' => (string) ($line['play_code'] ?? ''),
|
||||
];
|
||||
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user