| @@ 320-324 (lines=5) @@ | ||
| 317 | // 新規登録 |
|
| 318 | log_info('商品規格新規登録開始', array($id)); |
|
| 319 | ||
| 320 | if (count($ProductClasses) > 0) { |
|
| 321 | // 既に登録されていれば最初の画面に戻す |
|
| 322 | log_info('商品規格登録済', array($id)); |
|
| 323 | return $app->redirect($app->url('admin_product_product_class', array('id' => $id))); |
|
| 324 | } |
|
| 325 | ||
| 326 | $addProductClasses = array(); |
|
| 327 | ||
| @@ 381-385 (lines=5) @@ | ||
| 378 | // 更新 |
|
| 379 | log_info('商品規格更新開始', array($id)); |
|
| 380 | ||
| 381 | if (count($ProductClasses) == 0) { |
|
| 382 | // 商品規格が0件であれば最初の画面に戻す |
|
| 383 | log_info('商品規格が存在しません', array($id)); |
|
| 384 | return $app->redirect($app->url('admin_product_product_class', array('id' => $id))); |
|
| 385 | } |
|
| 386 | ||
| 387 | $checkProductClasses = array(); |
|
| 388 | $removeProductClasses = array(); |
|
| @@ 486-490 (lines=5) @@ | ||
| 483 | // 削除 |
|
| 484 | log_info('商品規格削除開始', array($id)); |
|
| 485 | ||
| 486 | if (count($ProductClasses) == 0) { |
|
| 487 | // 既に商品が削除されていれば元の画面に戻す |
|
| 488 | log_info('商品規格が存在しません', array($id)); |
|
| 489 | return $app->redirect($app->url('admin_product_product_class', array('id' => $id))); |
|
| 490 | } |
|
| 491 | ||
| 492 | foreach ($ProductClasses as $ProductClass) { |
|
| 493 | // 登録されている商品規格に削除フラグをセット |
|