Changeset 22246


Ignore:
Timestamp:
2013/01/15 20:56:30 (8 years ago)
Author:
undertree
Message:

#2019 (在庫非表示フラグがONの状態で、在庫数0の商品がおすすめ商品に表示される)
・在庫非表示フラグがONの場合「マイページ>お気に入り一覧」と同様の条件「在庫数>0 or 在庫無制限フラグ=1」を追加。

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_12-dev/data/class/pages/frontparts/bloc/LC_Page_FrontParts_Bloc_Recommend.php

    r22206 r22246  
    9595        $table = 'dtb_best_products as T1 INNER JOIN dtb_products as T2 ON T1.product_id = T2.product_id'; 
    9696        $where = 'T1.del_flg = 0 and T2.status = 1'; 
     97        if (NOSTOCK_HIDDEN) { 
     98            $where .= ' AND EXISTS(SELECT * FROM dtb_products_class WHERE product_id = T1.product_id AND dtb_products_class.del_flg = 0 AND (stock >= 1 OR stock_unlimited = 1))'; 
     99        } 
    97100        $objQuery->setOrder('T1.rank'); 
    98101        $objQuery->setLimit(RECOMMEND_NUM); 
Note: See TracChangeset for help on using the changeset viewer.