Ignore:
Timestamp:
2011/09/25 13:15:51 (13 years ago)
Author:
Seasoft
Message:

#1484 (SC_Product#lists の第2引数($arrVal)が実質的に無効)
#1449 (不要な関数・処理の整理)
#1421 (Fix typo.)
#1463 (コーディング規則に従っていない)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_11-dev/data/class/pages/products/LC_Page_Products_Detail.php

    r21230 r21256  
    409409    /* 登録済み関連商品の読み込み */ 
    410410    function lfPreGetRecommendProducts($product_id) { 
    411         $arrRecommend = array(); 
     411        $objProduct = new SC_Product_Ex(); 
    412412        $objQuery =& SC_Query_Ex::getSingletonInstance(); 
     413 
    413414        $objQuery->setOrder("rank DESC"); 
    414415        $arrRecommendData = $objQuery->select("recommend_product_id, comment", "dtb_recommend_products", "product_id = ?", array($product_id)); 
     
    420421        } 
    421422 
    422         $objProduct = new SC_Product_Ex(); 
    423  
    424         $where = ""; 
    425         if (!empty($arrRecommendProductId)) { 
    426             $where = 'product_id IN (' . implode(',', $arrRecommendProductId) . ')'; 
    427         } else { 
    428             return $arrRecommend; 
    429         } 
    430423        $objQuery =& SC_Query_Ex::getSingletonInstance(); 
    431         $objQuery->setWhere($where); 
    432         $arrProducts = $objProduct->lists($objQuery, $arrRecommendProductId); 
     424        $arrProducts = $objProduct->getListByProductIds($objQuery, $arrRecommendProductId); 
    433425 
    434426        //取得している並び順で並び替え 
     
    438430            $arrProducts2[ $item['product_id'] ] = $item; 
    439431        } 
    440         $arrProducts = array(); 
     432 
     433        $arrRecommend = array(); 
    441434        foreach($arrRecommendProductId as $product_id) { 
    442435            $arrProducts2[$product_id]['comment'] = $arrRecommendData[$product_id]; 
Note: See TracChangeset for help on using the changeset viewer.