Changeset 16873


Ignore:
Timestamp:
2007/12/03 03:00:51 (16 years ago)
Author:
adachi
Message:

自動アップデート対応

Location:
branches/feature-module-update/data/class/pages/upgrade
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/feature-module-update/data/class/pages/upgrade/LC_Page_Upgrade_Base.php

    r16853 r16873  
    3434     */ 
    3535    function autoUpdateEnable($product_id) { 
    36         $where = 'product_id = ?'; 
     36        $where = 'module_id = ?'; 
    3737        $objQuery = new SC_Query(); 
    3838        $arrRet = $objQuery->select('auto_update_flg', 'dtb_module', $where, array($product_id)); 
  • branches/feature-module-update/data/class/pages/upgrade/LC_Page_Upgrade_Download.php

    r16872 r16873  
    8080        } 
    8181 
     82        $objLog->log('* auto update check start'); 
    8283        if ($mode == 'auto_update' 
    8384        && $this->autoUpdateEnable($this->objForm->getValue('product_id')) !== true) { 
    8485            $objJson->setError(OSTORE_E_C_AUTOUP_DISABLE); 
    8586            $objJson->display(); 
    86             $objLog->error(OSTORE_E_C_INVALID_PARAM, $_POST); 
     87            $objLog->error(OSTORE_E_C_AUTOUP_DISABLE, $_POST); 
    8788            return; 
    8889        } 
     
    111112            'product_id' => $this->objForm->getValue('product_id') 
    112113        ); 
    113         $objReq = $this->request('download', $arrPostData); 
     114        $objReq = $this->request($mode, $arrPostData); 
    114115 
    115116        // リクエストチェック 
     
    201202            // 配信サーバへ通知 
    202203            $objLog->log("* notify to lockon server start"); 
    203             $objReq = $this->notifyDownload($objReq->getResponseCookies()); 
     204            $objReq = $this->notifyDownload($mode, $objReq->getResponseCookies()); 
    204205 
    205206            $objLog->log('* dl commit result:' . serialize($objReq)); 
     
    272273     * @retrun 
    273274     */ 
    274     function notifyDownload($arrCookies) { 
    275         $objReq = $this->request('download_commit', array(), $arrCookies); 
     275    function notifyDownload($mode, $arrCookies) { 
     276        $arrPOSTParams = array( 
     277            'eccube_url' => SITE_URL 
     278        ); 
     279        $objReq = $this->request($mode . '_commit', $arrPOSTParams, $arrCookies); 
    276280        return $objReq; 
    277281    } 
Note: See TracChangeset for help on using the changeset viewer.