|
|
@@ -17,6 +17,7 @@ import com.izouma.tcg.repo.card.CardCaseRepo;
|
|
|
import com.izouma.tcg.repo.orderInfo.OrderInfoRepo;
|
|
|
import com.izouma.tcg.repo.orderInfo.TransactionRecordRepo;
|
|
|
import com.izouma.tcg.service.card.CardCaseService;
|
|
|
+import com.izouma.tcg.service.delay.OrderDelayService;
|
|
|
import com.izouma.tcg.utils.*;
|
|
|
import lombok.AllArgsConstructor;
|
|
|
import org.apache.commons.beanutils.ConvertUtils;
|
|
|
@@ -41,6 +42,7 @@ public class OrderInfoService {
|
|
|
private final CardCaseRepo cardCaseRepo;
|
|
|
private final Cache<String, Object> caffeineCache;
|
|
|
private final TransactionRecordRepo transactionRecordRepo;
|
|
|
+ private final OrderDelayService orderDelayService;
|
|
|
|
|
|
public Page<OrderInfo> all(PageQuery pageQuery) {
|
|
|
return orderInfoRepo
|
|
|
@@ -72,7 +74,9 @@ public class OrderInfoService {
|
|
|
cardBox.setOrderInfoId(saved.getId());
|
|
|
cardBoxRepo.save(cardBox);
|
|
|
});
|
|
|
- return orderInfoRepo.findById(saved.getId()).orElseThrow(new BusinessException("未找到"));
|
|
|
+ OrderInfo result = orderInfoRepo.findById(saved.getId()).orElseThrow(new BusinessException("未找到"));
|
|
|
+ orderDelayService.orderDelay(result.getId(), result.getCreatedAt());
|
|
|
+ return result;
|
|
|
}
|
|
|
|
|
|
public boolean checkBox(String boxIdStr, Long caseId) {
|