mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-15 18:38:57 +01:00
"if negating a search with an exclemation mark, we have to AND the criteria"
This commit is contained in:
parent
cb9daa98ec
commit
c2413db67b
@ -341,7 +341,7 @@ class accounts_sql
|
|||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
case 'both':
|
case 'both':
|
||||||
$filter = "(contact_owner=0 OR contact_owner IS NULL)";
|
$filter = "(egw_addressbook.contact_owner=0 OR egw_addressbook.contact_owner IS NULL)";
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
$criteria = array();
|
$criteria = array();
|
||||||
@ -384,7 +384,7 @@ class accounts_sql
|
|||||||
$accounts = array();
|
$accounts = array();
|
||||||
foreach((array) $GLOBALS['egw']->contacts->search($criteria,"1,n_given,n_family,email,id,created,modified,$this->table.account_id AS account_id",
|
foreach((array) $GLOBALS['egw']->contacts->search($criteria,"1,n_given,n_family,email,id,created,modified,$this->table.account_id AS account_id",
|
||||||
$order,"account_lid,account_type,account_status",
|
$order,"account_lid,account_type,account_status",
|
||||||
$wildcard,false,'OR',$offset ? array($start,$offset) : is_null($start) ? false : $start,
|
$wildcard,false,$query[0] == '!' ? 'AND' : 'OR',$offset ? array($start,$offset) : is_null($start) ? false : $start,
|
||||||
$filter,$this->contacts_join) as $contact)
|
$filter,$this->contacts_join) as $contact)
|
||||||
{
|
{
|
||||||
if ($contact)
|
if ($contact)
|
||||||
|
Loading…
Reference in New Issue
Block a user