Changeset 22232


Ignore:
Timestamp:
2013/01/11 18:06:38 (8 years ago)
Author:
undertree
Message:

#2017 お気に入り一覧の取得条件に「dtb_products.status = 1」を追加。

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_12-dev/data/class/pages/mypage/LC_Page_Mypage_Favorite.php

    r22206 r22232  
    125125        $objProduct     = new SC_Product_Ex(); 
    126126 
    127         $objQuery->setOrder('create_date DESC'); 
    128         $where = 'customer_id = ?'; 
     127        $objQuery->setOrder('f.create_date DESC'); 
     128        $where = 'f.customer_id = ? and p.status = 1'; 
    129129        if (NOSTOCK_HIDDEN) { 
    130130            $where .= ' AND EXISTS(SELECT * FROM dtb_products_class WHERE product_id = dtb_customer_favorite_products.product_id AND del_flg = 0 AND (stock >= 1 OR stock_unlimited = 1))'; 
    131131        } 
    132         $arrProductId  = $objQuery->getCol('product_id', 'dtb_customer_favorite_products', $where, array($customer_id)); 
     132        $arrProductId  = $objQuery->getCol('f.product_id', 'dtb_customer_favorite_products f inner join dtb_products p using (product_id)', $where, array($customer_id)); 
    133133 
    134134        $objQuery       =& SC_Query_Ex::getSingletonInstance(); 
Note: See TracChangeset for help on using the changeset viewer.