testing search function
This commit is contained in:
parent
79c7af32b3
commit
0b6f25f2ab
include
@ -111,12 +111,18 @@ class Product extends Entity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public function matches($terms, $matchAll=false) {
|
public function matches($terms, $matchAll=false) {
|
||||||
|
print('DEBUG $terms: ');
|
||||||
|
var_dump($terms);
|
||||||
|
print('<br><br>');
|
||||||
$terms = $this->specify_search($terms, array('brand',
|
$terms = $this->specify_search($terms, array('brand',
|
||||||
'name',
|
'name',
|
||||||
'serial',
|
'serial',
|
||||||
'invoice',
|
'invoice',
|
||||||
'status',
|
'status',
|
||||||
'tag'));
|
'tag'));
|
||||||
|
print('DEBUG $terms post translation: ');
|
||||||
|
var_dump($terms);
|
||||||
|
print('<br><br>');
|
||||||
$matches = array();
|
$matches = array();
|
||||||
foreach($terms as $field => $values) {
|
foreach($terms as $field => $values) {
|
||||||
if(property_exists($this, $field)) {
|
if(property_exists($this, $field)) {
|
||||||
|
@ -146,7 +146,9 @@ class SearchPage extends Page {
|
|||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
}
|
}
|
||||||
|
print('DEBUG $sanitizedItem: ');
|
||||||
|
var_dump($out);
|
||||||
|
print('<br><br>');
|
||||||
// foreach($sanitizedItems as $sanitizedItem) {
|
// foreach($sanitizedItems as $sanitizedItem) {
|
||||||
// print('DEBUG $sanitizedItem: ');
|
// print('DEBUG $sanitizedItem: ');
|
||||||
// var_dump($sanitizedItem);
|
// var_dump($sanitizedItem);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user