Removing the brewbakers part for the pre-owned from here and putting in
the filter for the theme.
}
}
}
- // Check to see if Pre-Owned is not set. If it is not set then only get
- // listings without the Pre-Owned
- if ( !isset( $_REQUEST['pre_owned'] ) ) {
- $queryParts[] = " T.id IN (
- SELECT ref_dest
- FROM " . GLM_MEMBERS_FIELDS_PLUGIN_DB_PREFIX . "custom_field_data
- WHERE field_data != 'Yes'
- AND field_id = (SELECT id
- FROM " . GLM_MEMBERS_FIELDS_PLUGIN_DB_PREFIX . "custom_fields
- WHERE field_name = 'Pre-Owned')
- ) ";
- }
return $queryParts;
});
add_filter('glm-member-db-front-search-query-orderby', function($originalOrderBy){