瀏覽代碼

Maintenance #1073

feature/souke
Guillaume Bourgeois 1 年之前
父節點
當前提交
2462c03ebe
共有 1 個檔案被更改,包括 2 行新增1 行删除
  1. +2
    -1
      producer/controllers/OrderController.php

+ 2
- 1
producer/controllers/OrderController.php 查看文件

@@ -558,12 +558,13 @@ class OrderController extends ProducerBaseController
{
$orderManager = $this->getOrderManager();
$order = $this->getOrderManager()->findOneOrderById($id);
$orderManager->initOrder($order);

if (!$order) {
throw new \yii\web\NotFoundHttpException('Commande introuvable');
}

$orderManager->initOrder($order);

if (!$orderManager->isOrderStateOpen($order)) {
throw new UserException('Vous ne pouvez plus annuler cette commande.');
}

Loading…
取消
儲存