Changeset 15306


Ignore:
Timestamp:
2007/08/17 16:34:06 (17 years ago)
Author:
adachi
Message:

getCustomerDataFromEmailPass()へ渡す引数の順序が誤っていた不具合を修正

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/rel/data/class/SC_Customer.php

    r12157 r15306  
    1010 */ 
    1111class SC_Customer { 
    12      
     12 
    1313    var $conn; 
    1414    var $email; 
    15     var $customer_data;     // ²ñ°÷¾ðÊó    
    16          
     15    var $customer_data;     // ²ñ°÷¾ðÊó 
     16 
    1717    function SC_Customer( $conn = '', $email = '', $pass = '' ) { 
    1818        // ¥»¥Ã¥·¥ç¥ó³«»Ï 
    1919        /* startSession¤«¤é°ÜÆ° 2005/11/04 ÃæÀî */ 
    2020        sfDomainSessionStart(); 
    21          
     21 
    2222        // DBÀܳ¥ª¥Ö¥¸¥§¥¯¥ÈÀ¸À® 
    2323        $DB_class_name = "SC_DbConn"; 
     
    3030            if (class_exists($DB_class_name)){ 
    3131                //$DB_class_name¤Î¥¤¥ó¥¹¥¿¥ó¥¹¤òºîÀ®¤¹¤ë 
    32                 $this->conn = new SC_DbConn();           
    33             } 
    34         } 
    35              
    36         if ( is_object($this->conn) ) {  
     32                $this->conn = new SC_DbConn(); 
     33            } 
     34        } 
     35 
     36        if ( is_object($this->conn) ) { 
    3737            // Àµ¾ï¤ËDB¤ËÀܳ¤Ç¤­¤ë 
    3838            if ( $email ){ 
     
    4444            exit; 
    4545        } 
    46          
     46 
    4747        if ( strlen($email) > 0 && strlen($pass) > 0 ){ 
    48             $this->getCustomerDataFromEmailPass( $email, $pass ); 
    49         } 
    50     } 
    51      
     48            $this->getCustomerDataFromEmailPass($pass, $email); 
     49        } 
     50    } 
     51 
    5252    function getCustomerDataFromEmailPass( $pass, $email, $mobile = false ) { 
    5353        $sql_mobile = $mobile ? ' OR email_mobile ILIKE ?' : ''; 
     
    6060        $result = $this->conn->getAll($sql, $arrValues); 
    6161        $data = $result[0]; 
    62          
     62 
    6363        // ¥Ñ¥¹¥ï¡¼¥É¤¬¹ç¤Ã¤Æ¤¤¤ì¤Ð¸ÜµÒ¾ðÊó¤òcustomer_data¤Ë¥»¥Ã¥È¤·¤Ætrue¤òÊÖ¤¹ 
    6464        if ( sha1($pass . ":" . AUTH_MAGIC) == $data['password'] ){ 
     
    159159        $this->customer_data['email_mobile'] = $this->customer_data['email']; 
    160160    } 
    161      
     161 
    162162    // ¥Ñ¥¹¥ï¡¼¥É¤ò³Îǧ¤»¤º¤Ë¥í¥°¥¤¥ó 
    163163    function setLogin($email) { 
     
    169169        $this->startSession(); 
    170170    } 
    171      
     171 
    172172    // ¥»¥Ã¥·¥ç¥ó¾ðÊó¤òºÇ¿·¤Î¾ðÊó¤Ë¹¹¿·¤¹¤ë 
    173173    function updateSession() { 
     
    178178        $_SESSION['customer'] = $this->customer_data; 
    179179    } 
    180          
     180 
    181181    // ¥í¥°¥¤¥ó¾ðÊó¤ò¥»¥Ã¥·¥ç¥ó¤ËÅÐÏ¿¤·¡¢¥í¥°¤Ë½ñ¤­¹þ¤à 
    182182    function startSession() { 
     
    194194        gfPrintLog("logout : user=".$this->customer_data['customer_id'] ."\t"."ip=". $_SERVER['REMOTE_HOST'], CUSTOMER_LOG_PATH ); 
    195195    } 
    196      
     196 
    197197    // ¥í¥°¥¤¥ó¤ËÀ®¸ù¤·¤Æ¤¤¤ë¤«È½Äꤹ¤ë¡£ 
    198198    function isLoginSuccess($dont_check_email_mobile = false) { 
     
    213213        return false; 
    214214    } 
    215          
     215 
    216216    // ¥Ñ¥é¥á¡¼¥¿¤Î¼èÆÀ 
    217217    function getValue($keyname) { 
    218218        return $_SESSION['customer'][$keyname]; 
    219219    } 
    220      
     220 
    221221    // ¥Ñ¥é¥á¡¼¥¿¤Î¥»¥Ã¥È 
    222222    function setValue($keyname, $val) { 
     
    228228        return isset($_SESSION['customer'][$keyname]); 
    229229    } 
    230      
     230 
    231231    // ÃÂÀ¸Æü·î¤Ç¤¢¤ë¤«¤É¤¦¤«¤ÎȽÄê 
    232232    function isBirthMonth() { 
     
    234234        $birth_month = intval($arrRet[1]); 
    235235        $now_month = intval(date("m")); 
    236          
     236 
    237237        if($birth_month == $now_month) { 
    238238            return true; 
Note: See TracChangeset for help on using the changeset viewer.