Changeset 21589


Ignore:
Timestamp:
2012/03/04 22:25:28 (10 years ago)
Author:
Seasoft
Message:

#1633 (エラーハンドリングの改善)
#1613 (typo修正・ソース整形・ソースコメントの改善)

Location:
branches/version-2_12-dev/data/class
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_12-dev/data/class/SC_Query.php

    r21583 r21589  
    10821082        } 
    10831083 
    1084         $msg .= 'execution time: ' . sprintf("%.2f sec", $timeExecTime) . "\n"; 
     1084        $msg .= 'execution time: ' . sprintf('%.2f sec', $timeExecTime) . "\n"; 
    10851085        GC_Utils_Ex::gfPrintLog($msg, DB_LOG_REALFILE); 
    10861086    } 
  • branches/version-2_12-dev/data/class/SC_View.php

    r21583 r21589  
    5757        $this->_smarty->register_function('sfIsHTTPS', array('SC_Utils_Ex', 'sfIsHTTPS')); 
    5858        $this->_smarty->register_function('sfSetErrorStyle', array('SC_Utils_Ex', 'sfSetErrorStyle')); 
    59         $this->_smarty->register_function('printXMLDeclaration', array('SC_Utils_Ex', 'printXMLDeclaration')); 
     59        $this->_smarty->register_function('printXMLDeclaration', array('GC_Utils_Ex', 'printXMLDeclaration')); 
    6060        $this->_smarty->default_modifiers = array('script_escape'); 
    6161 
  • branches/version-2_12-dev/data/class/helper/SC_Helper_Purchase.php

    r21572 r21589  
    7979        $orderTemp['status'] = $orderStatus; 
    8080        $cartkey = $objCartSession->getKey(); 
    81         $orderId = $this->registerOrderComplete($orderTemp, $objCartSession, $cartkey); 
     81        $order_id = $this->registerOrderComplete($orderTemp, $objCartSession, $cartkey); 
    8282        $isMultiple = SC_Helper_Purchase::isMultiple(); 
    8383        $shippingTemp =& $this->getShippingTemp($isMultiple); 
    8484        foreach ($shippingTemp as $shippingId => $val) { 
    85             $this->registerShipmentItem($orderId, $shippingId, $val['shipment_item']); 
    86         } 
    87  
    88         $this->registerShipping($orderId, $shippingTemp); 
     85            $this->registerShipmentItem($order_id, $shippingId, $val['shipment_item']); 
     86        } 
     87 
     88        $this->registerShipping($order_id, $shippingTemp); 
    8989        $objQuery->commit(); 
    9090 
     
    9494        } 
    9595 
    96         $this->cleanupSession($orderId, $objCartSession, $objCustomer, $cartkey); 
    97  
    98         GC_Utils_Ex::gfFrontLog('order complete. customerId=' . $customerId); 
    99  
     96        $this->cleanupSession($order_id, $objCartSession, $objCustomer, $cartkey); 
     97 
     98        GC_Utils_Ex::gfPrintLog('order complete. order_id=' . $order_id); 
    10099    } 
    101100 
     
    516515    function extractShipping($arrSrc) { 
    517516        $arrKey = array(); 
    518         foreach($this->arrShippingKey as $key) { 
     517        foreach ($this->arrShippingKey as $key) { 
    519518            $arrKey[] = 'shipping_' . $key; 
    520519        } 
  • branches/version-2_12-dev/data/class/util/GC_Utils.php

    r21582 r21589  
    106106            } 
    107107            if (($arrLine['class'] === 'GC_Utils' || $arrLine['class'] === 'GC_Utils_Ex') 
    108                 && $arrLine['function'] === 'gfDebugLog' 
     108                && ($arrLine['function'] === 'gfDebugLog' || $arrLine['function'] === 'gfPrintLog') 
    109109            ) { 
    110110                break 1; 
     
    389389        return defined('INSTALL_FUNCTION') && INSTALL_FUNCTION === true; 
    390390    } 
     391 
     392    /** 
     393     * XML宣言を出力する. 
     394     * 
     395     * XML宣言があると問題が発生する UA は出力しない. 
     396     * 
     397     * @return string XML宣言の文字列 
     398     */ 
     399    function printXMLDeclaration() { 
     400        $ua = $_SERVER['HTTP_USER_AGENT']; 
     401        if (!preg_match('/MSIE/', $ua) || preg_match('/MSIE 7/', $ua)) { 
     402            echo '<?xml version="1.0" encoding="' . CHAR_CODE . '"?>' . "\n"; 
     403        } 
     404    } 
    391405} 
Note: See TracChangeset for help on using the changeset viewer.