where(['order_no' => $orderNo])->find(); if (empty($order)) throw new Exception("订单不存在"); if ($order['status'] !== 2) throw new Exception("不可发起支付"); if (empty($payImage)) throw new Exception('支付凭证不能为空'); $this->updatePaymentOrder($orderNo, CodeExtend::uniqidDate(20), $payAmount, '单据凭证支付', $payImage); return ['code' => 1, 'info' => '支付凭证上传成功!']; } }