Merge pull request #22909 from Humml87/16.0_Fix_#22768_MO_List_Filter
Fix #22768 remove "natural_search" on status and fk_parent_line.
This commit is contained in:
commit
e36afdbde9
@ -174,6 +174,9 @@ if (empty($reshook)) {
|
||||
if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha')) { // All tests are required to be compatible with all browsers
|
||||
foreach ($object->fields as $key => $val) {
|
||||
$search[$key] = '';
|
||||
if ($key == 'status') {
|
||||
$search[$key] = -1;
|
||||
}
|
||||
if (preg_match('/^(date|timestamp|datetime)/', $val['type'])) {
|
||||
$search[$key.'_dtstart'] = '';
|
||||
$search[$key.'_dtend'] = '';
|
||||
@ -247,7 +250,7 @@ foreach ($search as $key => $val) {
|
||||
if ($key == 'status' && $search[$key] == -1) {
|
||||
continue;
|
||||
}
|
||||
if ($key == 'fk_parent_line') {
|
||||
if ($key == 'fk_parent_line' && $search[$key] != '') {
|
||||
$sql .= natural_search('moparent.ref', $search[$key], 0);
|
||||
continue;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user