argument('ids'); if (!$ids) { dd('请输订单id'); } $idList = explode(',', $ids); foreach ($idList as $id) { $order = Order::find($id); if ($order->lottery_state != LottState::WIN) { dump(sprintf('订单%d的状态不对:%d', $order->id, $order->lottery_state)); continue; } $order->lottery_state = LottState::WAIT; $order->save(); switch ($order->lotteryType->type) { case LottType::JCZQ: ComputeJczqOrderPrize::dispatch($id); return; case LottType::JCLQ: ComputeJclqOrderPrize::dispatch($id); return; case LottType::CTZQ_JQC: ComputeCtzqJqcOrderPrize::dispatch($id); return; case LottType::CTZQ_BQC: ComputeCtzqBqcOrderPrize::dispatch($id); return; case LottType::CTZQ_SFC9: ComputeCtzqSfc9OrderPrize::dispatch($id); return; case LottType::CTZQ_SFC14: ComputeCtzqSfc14OrderPrize::dispatch($id); return; case LottType::BJDC_SFGG: ComputeBjdcSfggOrderPrize::dispatch($id); return; case LottType::BJDC: ComputeBjdcOrderPrize::dispatch($id); return; case LottType::DLT: ComputeDltOrderPrize::dispatch($id); return; case LottType::PLS: ComputePlsOrderPrize::dispatch($id); return; case LottType::PLW: ComputePlwOrderPrize::dispatch($id); return; case LottType::QXC: ComputeQxcOrderPrize::dispatch($id); return; } } } }