Changeset 23407
- Timestamp:
- 2014/05/08 19:12:35 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/version-2_13-dev/data/class/pages/products/LC_Page_Products_List.php
r23378 r23407 236 236 $dtb_product_categories = 'dtb_product_categories'; 237 237 } 238 $col = ' T3.rank * 2147483648 + T2.rank';238 $col = 'MAX(T3.rank * 2147483648 + T2.rank)'; 239 239 $from = "$dtb_product_categories T2 JOIN dtb_category T3 ON T2.category_id = T3.category_id"; 240 240 $where = 'T2.product_id = alldtl.product_id'; 241 $objQuery->setOrder('T3.rank DESC, T2.rank DESC'); 242 $objQuery->setLimit(1); 243 $sub_sql = $objQuery->getSqlWithLimitOffset($col, $from, $where); 241 $sub_sql = $objQuery->getSql($col, $from, $where); 244 242 245 243 $objQuery->setOrder("($sub_sql) DESC ,product_id DESC");
Note: See TracChangeset
for help on using the changeset viewer.