Active
Project:
Ubercart Add to Cart CCK Field
Version:
5.x-1.0
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
10 Dec 2008 at 17:17 UTC
Updated:
10 Dec 2008 at 17:17 UTC
This normaly wouldn't be an issue, but I've got products that list from 10 to 300 and so I get the typical
10
100
125
150
175
20
250
etc...
The solution I found was to edit the DB query on line 426 and add a join on the uc_products table and made the primary sort the ordering column
$result = db_query(db_rewrite_sql("SELECT n.nid, n.title AS node_title, n.type AS node_type FROM {node} n, {uc_products} p WHERE ". $related_clause ." AND p.nid = n.nid ORDER BY p.ordering, n.title, n.type"), $args);
This then made the dropdown respect the desired sort order.