Define colums_to_search and use search2criteria() to get extra search functionality

This commit is contained in:
Nathan Gray 2010-04-01 20:57:15 +00:00
parent 5e23cfb764
commit 4653674fa9
2 changed files with 4 additions and 1 deletions

View File

@ -69,7 +69,7 @@ class bo_resources
}
}
if ($this->debug) _debug_array($query);
$criteria = array('name' => $query['search'], 'short_description' => $query['search'], 'inventory_number' => $query['search']);
$criteria = $query['search'];
$read_onlys = 'res_id,name,short_description,quantity,useable,bookable,buyable,cat_id,location,storage_info';
$accessory_of = $query['view_accs_of'] ? $query['view_accs_of'] : -1;

View File

@ -24,6 +24,9 @@ class so_resources extends so_sql
$this->customfields = config::get_customfields('resources');
$this->soextra = new so_sql('resources','egw_resources_extra');
$this->columns_to_search = array('name','short_description','inventory_number','long_description','location');
}
/**