Ignore:
Timestamp:
2008/07/21 20:31:36 (18 years ago)
Author:
Seasoft
Message:

数量表記の統一。

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/comu-ver2/data/class/SC_CartSession.php

    r16741 r17444  
    188188        // ポイント合計 
    189189        $total = 0; 
    190         $max = $this->getMax(); 
    191         for($i = 0; $i <= $max; $i++) { 
    192             $price = $_SESSION[$this->key][$i]['price']; 
    193             $quantity = $_SESSION[$this->key][$i]['quantity']; 
    194  
    195             if (!isset($_SESSION[$this->key][$i]['point_rate'])) { 
    196                 $_SESSION[$this->key][$i]['point_rate'] = ""; 
    197             } 
    198             $point_rate = $_SESSION[$this->key][$i]['point_rate']; 
    199  
    200             if (!isset($_SESSION[$this->key][$i]['id'][0])) { 
    201                 $_SESSION[$this->key][$i]['id'][0] = ""; 
    202             } 
    203             $id = $_SESSION[$this->key][$i]['id'][0]; 
    204             $point = SC_Utils_Ex::sfPrePoint($price, $point_rate, POINT_RULE, $id); 
    205             $total+= ($point * $quantity); 
     190        if (USE_POINT !== false) { 
     191            $max = $this->getMax(); 
     192            for($i = 0; $i <= $max; $i++) { 
     193                $price = $_SESSION[$this->key][$i]['price']; 
     194                $quantity = $_SESSION[$this->key][$i]['quantity']; 
     195 
     196                if (!isset($_SESSION[$this->key][$i]['point_rate'])) { 
     197                    $_SESSION[$this->key][$i]['point_rate'] = ""; 
     198                } 
     199                $point_rate = $_SESSION[$this->key][$i]['point_rate']; 
     200 
     201                if (!isset($_SESSION[$this->key][$i]['id'][0])) { 
     202                    $_SESSION[$this->key][$i]['id'][0] = ""; 
     203                } 
     204                $id = $_SESSION[$this->key][$i]['id'][0]; 
     205                $point = SC_Utils_Ex::sfPrePoint($price, $point_rate, POINT_RULE, $id); 
     206                $total+= ($point * $quantity); 
     207            } 
    206208        } 
    207209        return $total; 
     
    322324    } 
    323325 
    324     // 個数の増加 
     326    // 数量の増加 
    325327    function upQuantity($cart_no) { 
    326328        $max = $this->getMax(); 
     
    334336    } 
    335337 
    336     // 個数の減少 
     338    // 数量の減少 
    337339    function downQuantity($cart_no) { 
    338340        $max = $this->getMax(); 
Note: See TracChangeset for help on using the changeset viewer.