Changeset 19731


Ignore:
Timestamp:
2010/12/16 23:21:59 (11 years ago)
Author:
Seasoft
Message:

#855(SC_Query の #select, #getRow, #getCol, #get, #min, #max の引数順を統一する)

  • SC_Query#getRow を改訂
Location:
branches/version-2_5-dev
Files:
6 edited

Legend:

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

    r19730 r19731  
    582582     * @return array array('カラム名' => '値', ...)の連想配列 
    583583     */ 
    584     function getRow($table, $col, $where = "", $arrVal = array(), $fetchmode = MDB2_FETCHMODE_ASSOC) { 
     584    function getRow($col, $table, $where = "", $arrVal = array(), $fetchmode = MDB2_FETCHMODE_ASSOC) { 
    585585 
    586586        $sql = $this->getSql($col, $table, $where); 
  • branches/version-2_5-dev/data/class/helper/SC_Helper_DB.php

    r19730 r19731  
    18901890        $objQuery =& SC_Query::getSingletonInstance(); 
    18911891 
    1892         $arrOrderOld = $objQuery->getRow('dtb_order', 'status, add_point, use_point, customer_id', 'order_id = ?', array($orderId)); 
     1892        $arrOrderOld = $objQuery->getRow('status, add_point, use_point, customer_id', 'dtb_order', 'order_id = ?', array($orderId)); 
    18931893 
    18941894        // 対応状況が変更無しの場合、DB値を引き継ぐ 
  • branches/version-2_5-dev/data/class/helper/SC_Helper_Mobile.php

    r19729 r19731  
    392392 
    393393        $arrRow = $objQuery->getRow( 
    394              'dtb_mobile_kara_mail' 
    395             ,'session_id, next_url, email' 
     394             'session_id, next_url, email' 
     395            ,'dtb_mobile_kara_mail' 
    396396            ,'token = ? AND email IS NOT NULL AND receive_date >= ?' 
    397397            ,array($token, date('Y-m-d H:i:s', time() - MOBILE_SESSION_LIFETIME)) 
  • branches/version-2_5-dev/data/class/helper/SC_Helper_Purchase.php

    r19670 r19731  
    8686    function getOrderTemp($uniqId) { 
    8787        $objQuery =& SC_Query::getSingletonInstance(); 
    88         return $objQuery->getRow("dtb_order_temp", "*", "order_temp_id = ?", 
     88        return $objQuery->getRow("*", "dtb_order_temp", "order_temp_id = ?", 
    8989                                 array($uniqId)); 
    9090    } 
  • branches/version-2_5-dev/data/class/pages/admin/products/LC_Page_Admin_Products_ProductClass.php

    r19711 r19731  
    248248                // 更新の場合は規格組み合わせを検索し, 削除しておく 
    249249                $class_combination_id = $exists[$arrList["product_class_id:".$i]]['class_combination_id']; 
    250                 $existsCombi = $objQuery->getRow("dtb_class_combination", 
    251                                                  "*", "class_combination_id = ?", 
    252                                                  array($class_combination_id)); 
     250                $existsCombi = $objQuery->getRow( 
     251                    "*", 
     252                    "dtb_class_combination", 
     253                    "class_combination_id = ?", 
     254                    array($class_combination_id) 
     255                ); 
    253256 
    254257                $objQuery->delete("dtb_class_combination", 
     
    614617    function getProductsClass($product_id) { 
    615618        $objQuery =& SC_Query::getSingletonInstance(); 
    616         return $objQuery->getRow("dtb_products_class", "*", "product_id = ?", array($product_id)); 
     619        return $objQuery->getRow("*", "dtb_products_class", "product_id = ?", array($product_id)); 
    617620    } 
    618621 
  • branches/version-2_5-dev/test/class/SC_Query_Test.php

    r19730 r19731  
    140140 
    141141        $this->expected = array("column1" => 1, "column2" => 1); 
    142         $this->actual = $this->objQuery->getRow("test_table", "column1, column2", "id = ?", array(1)); 
     142        $this->actual = $this->objQuery->getRow("column1, column2", "test_table", "id = ?", array(1)); 
    143143        $this->verify(); 
    144144    } 
Note: See TracChangeset for help on using the changeset viewer.