'tis a bug. Edit /admin/orders.php, locating this section (starting at line 872 in the as-shipped zc156c version):
Code:
// create search_orders_products filter
$search = '';
$search_distinct = ' ';
$new_table = '';
$new_fields = '';
if (isset($_GET['search_orders_products']) && zen_not_null($_GET['search_orders_products'])) {
$search_distinct = ' distinct ';
$new_table = " left join " . TABLE_ORDERS_PRODUCTS . " op on (op.orders_id = o.orders_id) ";
$keywords = zen_db_input(zen_db_prepare_input($_GET['search_orders_products']));
$search = " and (op.products_model like '%" . $keywords . "%' or op.products_name like '" . $keywords . "%')";
if (substr(strtoupper($_GET['search_orders_products']), 0, 3) == 'ID:') {
$keywords = TRIM(substr($_GET['search_orders_products'], 3));
$search = " and op.products_id ='" . (int)$keywords . "'";
}
} else {
... and change to
Code:
// create search_orders_products filter
$search = '';
$search_distinct = ' ';
$new_table = '';
$new_fields = '';
if (isset($_GET['search_orders_products']) && zen_not_null($_GET['search_orders_products'])) {
$search_distinct = ' distinct ';
$new_table = " left join " . TABLE_ORDERS_PRODUCTS . " op on (op.orders_id = o.orders_id) ";
$keywords = zen_db_input(zen_db_prepare_input($_GET['search_orders_products']));
$search = " and (op.products_model like '%" . $keywords . "%' or op.products_name like '%" . $keywords . "%')";
if (substr(strtoupper($_GET['search_orders_products']), 0, 3) == 'ID:') {
$keywords = TRIM(substr($_GET['search_orders_products'], 3));
$search = " and op.products_id ='" . (int)$keywords . "'";
}
} else {
Bookmarks