Changeset 18714


Ignore:
Timestamp:
2010/06/21 12:04:47 (10 years ago)
Author:
nanasess
bzr:base-revision:
ohkouchi@loop-az.jp-20100621024307-zlsnjvavwufdgeep
bzr:committer:
Kentaro Ohkouchi <ohkouchi@loop-az.jp>
bzr:file-ids:

data/class/pages/admin/order/LC_Page_Admin_Order_Edit.php 15594@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fdata%2Fclass%2Fpages%2Fadmin%2Forder%2FLC_Page_Admin_Order_Edit.php
bzr:mapping-version:
v4
bzr:repository-uuid:
1e3b908f-19a9-db11-a64c-001125224ba8
bzr:revision-id:
ohkouchi@loop-az.jp-20100621030444-pwgzd9jnekuctuc2
bzr:revno:
1922
bzr:revprop:branch-nick:
branches/version-2_4
bzr:root:
branches/version-2_4
bzr:text-parents:

data/class/pages/admin/order/LC_Page_Admin_Order_Edit.php ohkouchi@loop-az.jp-20100621023700-03sldt18320io1i7
bzr:timestamp:
2010-06-21 12:04:44.502000093 +0900
bzr:user-agent:
bzr2.1.1+bzr-svn1.0.2
svn:original-date:
2010-06-21T03:04:44.502000Z
Message:

merged r18683, r18707

  • 在庫がマイナスになりうる場合はエラーとなるよう修正(#719)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_4/data/class/pages/admin/order/LC_Page_Admin_Order_Edit.php

    r18712 r18714  
    497497            // 加算ポイントの計算 
    498498            $totalpoint += SC_Utils_Ex::sfPrePoint($arrVal['price'][$i], $arrVal['point_rate'][$i]) * $arrVal['quantity'][$i]; 
     499 
     500            // 在庫数のチェック 
     501            $productClass = $objDb->sfGetProductsClass(array($arrVal['product_id'][$i], 
     502                                                             $arrVal['classcategory_id1'][$i], 
     503                                                             $arrVal['classcategory_id2'][$i])); 
     504            if ($productClass['stock_unlimited'] != '1' 
     505                && $productClass['stock'] < ($arrVal['quantity'][$i] - $this->arrForm['quantity'][$i])) { 
     506                $className1 = $this->arrForm['classcategory_name1'][$i]; 
     507                $className1 = empty($className1) ? 'なし' : $className1; 
     508                $className2 = $this->arrForm['classcategory_name2'][$i]; 
     509                $className2 = empty($className2) ? 'なし' : $className2; 
     510 
     511                if (!isset($arrErr['quantity'])) $arrErr['quantity'] = ""; 
     512 
     513                $arrErr['quantity'] .= $this->arrForm['product_name'][$i] . '/(' . $className1 . ')/(' . $className2 . ') の在庫が不足しています。 設定できる数量は「' . ($this->arrForm['quantity'][$i] + $productClass['stock']) . '」までです。<br />'; 
     514            } 
    499515        } 
    500516 
Note: See TracChangeset for help on using the changeset viewer.