Changeset 22497


Ignore:
Timestamp:
2013/02/04 20:23:57 (7 years ago)
Author:
h_yoshimoto
Message:

#1958 関数名を修正

Location:
branches/version-2_12_3
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_12_3/data/class/helper/SC_Helper_Address.php

    r22206 r22497  
    3737     * @return array() 
    3838     */ 
    39     function save($sqlval) { 
     39    function registAddress($sqlval) { 
    4040        $objQuery =& SC_Query_Ex::getSingletonInstance(); 
    4141        $customer_id = $sqlval['customer_id']; 
     
    7777     * @return array() 
    7878     */ 
    79     function get($other_deliv_id) { 
     79    function getAddress($other_deliv_id) { 
    8080        $objQuery =& SC_Query_Ex::getSingletonInstance(); 
    8181        $address = $objQuery->select('*', 'dtb_other_deliv', 'other_deliv_id = ?', array($other_deliv_id)); 
     
    106106     * @return void 
    107107     */ 
    108     function delete($other_deliv_id) { 
     108    function deleteAddress($other_deliv_id) { 
    109109        $where      = 'other_deliv_id = ?'; 
    110110        $objQuery   =& SC_Query_Ex::getSingletonInstance(); 
  • branches/version-2_12_3/data/class/pages/mypage/LC_Page_Mypage_Delivery.php

    r22206 r22497  
    8585                } 
    8686 
    87                 $objAddress->delete($objFormParam->getValue('other_deliv_id')); 
     87                $objAddress->deleteAddress($objFormParam->getValue('other_deliv_id')); 
    8888                break; 
    8989 
  • branches/version-2_12_3/data/class/pages/mypage/LC_Page_Mypage_DeliveryAddr.php

    r22206 r22497  
    136136 
    137137                if ($_GET['other_deliv_id'] != '') { 
    138                     $arrOtherDeliv = $objAddress->get($_SESSION['other_deliv_id']); 
     138                    $arrOtherDeliv = $objAddress->getAddress($_SESSION['other_deliv_id']); 
    139139 
    140140                    //不正アクセス判定 
     
    174174        $sqlval['customer_id'] = $customer_id; 
    175175 
    176         $objAddress->save($sqlval); 
     176        $objAddress->registAddress($sqlval); 
    177177    } 
    178178 
  • branches/version-2_12_3/data/class/pages/shopping/LC_Page_Shopping_Deliv.php

    r22206 r22497  
    110110            // 削除 
    111111            case 'delete': 
    112                 $objAddress->delete($arrForm['other_deliv_id']); 
     112                $objAddress->deleteAddress($arrForm['other_deliv_id']); 
    113113                break; 
    114114 
     
    228228        // 別のお届け先がチェックされている場合 
    229229        else { 
    230             $arrOtherDeliv = $objAddress->get($other_deliv_id); 
     230            $arrOtherDeliv = $objAddress->getAddress($other_deliv_id); 
    231231            if (!$arrOtherDeliv) { 
    232232                return false; 
  • branches/version-2_12_3/data/class/pages/shopping/LC_Page_Shopping_Multiple.php

    r22206 r22497  
    307307            if ($objCustomer->isLoginSuccess(true)) { 
    308308                if ($other_deliv_id != 0) { 
    309                     $otherDeliv = $objAddress->get($other_deliv_id); 
     309                    $otherDeliv = $objAddress->getAddress($other_deliv_id); 
    310310                    foreach ($otherDeliv as $key => $val) { 
    311311                        $arrValues[$other_deliv_id]['shipping_' . $key] = $val; 
  • branches/version-2_12_3/test/class/helper/SC_Helper_Address_Test.php

    r22079 r22497  
    5757    } 
    5858 
    59     function testSave() { 
     59    function testRegistAddress() { 
    6060        // ダミーの住所を登録 
    6161        $sqlval = $this->dummy; 
     
    6363        // 検証用の住所02 
    6464        $sqlval['addr02'] = $create_test = 'create test ' . time(); 
    65         $this->objAddress->save($sqlval); 
     65        $this->objAddress->registAddress($sqlval); 
    6666 
    6767        // 住所02が検証用のものと同じか確認 
     
    7373        // 更新の検証のために住所02を変更 
    7474        $sqlval['addr02'] = $update_test = 'update test ' . time(); 
    75         $this->objAddress->save($sqlval); 
     75        $this->objAddress->registAddress($sqlval); 
    7676 
    7777        // 住所02が検証用のものと同じか検証 
     
    8484     * @depends testSave 
    8585     */ 
    86     function testGet() { 
     86    function testGetAddress() { 
    8787        // testSave のテストが通っていること前提 
    8888        $sqlval = $this->dummy; 
    8989        $sqlval['customer_id'] = $this->customer_id; 
    9090        $sqlval['addr02'] = 'get test'; 
    91         $this->objAddress->save($sqlval); 
     91        $this->objAddress->registAddress($sqlval); 
    9292        $this->objQuery->setOrder('other_deliv_id DESC'); 
    9393        $other_deliv_id = $this->objQuery->getOne('SELECT other_deliv_id FROM dtb_other_deliv WHERE customer_id = ?', array($this->customer_id)); 
    9494        // DBに正しく記録され、取得できているか確認 
    95         $address = $this->objAddress->get($other_deliv_id); 
     95        $address = $this->objAddress->getAddress($other_deliv_id); 
    9696        $result = TRUE; 
    9797        foreach ($sqlval as $key => $value) { 
     
    111111        $sqlval['customer_id'] = $this->customer_id; 
    112112        $sqlval['addr02'] = 'getList test'; 
    113         $this->objAddress->save($sqlval); 
     113        $this->objAddress->registAddress($sqlval); 
    114114        $list = $this->objAddress->getList($this->customer_id); 
    115115        $found = FALSE; 
     
    132132     * @depends testSave 
    133133     */ 
    134     function testDelete() { 
     134    function testDeleteAddress() { 
    135135        // testSave のテストが通っていること前提 
    136136        $sqlval = $this->dummy; 
    137137        $sqlval['customer_id'] = $this->customer_id; 
    138138        $sqlval['addr02'] = 'delete test'; 
    139         $this->objAddress->save($sqlval); 
     139        $this->objAddress->registAddress($sqlval); 
    140140        $this->objQuery->setOrder('other_deliv_id DESC'); 
    141141        $other_deliv_id = $this->objQuery->getOne('SELECT other_deliv_id FROM dtb_other_deliv WHERE customer_id = ?', array($this->customer_id)); 
    142         $this->objAddress->delete($other_deliv_id); 
     142        $this->objAddress->deleteAddress($other_deliv_id); 
    143143        $result = $this->objQuery->getRow('*', 'dtb_other_deliv', 'customer_id = ? and other_deliv_id = ?', array($this->customer_id, $other_deliv_id)); 
    144144        $this->assertNull($result); 
Note: See TracChangeset for help on using the changeset viewer.