forked from extern/egroupware
fixed not working actions with result of advanced search, nextmatch looped because of the way the extended search content was transfered
This commit is contained in:
parent
077f432d6c
commit
dcce858d3c
@ -679,18 +679,6 @@ class uicontacts extends bocontacts
|
|||||||
if (is_array($query['search'])) unset($query['search']);
|
if (is_array($query['search'])) unset($query['search']);
|
||||||
unset($query['advanced_search']);
|
unset($query['advanced_search']);
|
||||||
}
|
}
|
||||||
elseif (is_array($query['search'])) // new advanced search, store it in the session
|
|
||||||
{
|
|
||||||
$query['advanced_search'] = array_intersect_key($query['search'],array_flip(array_merge($this->get_contact_columns(),array('operator','meth_select'))));
|
|
||||||
foreach ($query['advanced_search'] as $key => $value)
|
|
||||||
{
|
|
||||||
if(!$value) unset($query['advanced_search'][$key]);
|
|
||||||
}
|
|
||||||
$query['start'] = 0;
|
|
||||||
$query['search'] = '';
|
|
||||||
// store the advanced search in the session to call it again
|
|
||||||
$GLOBALS['egw']->session->appsession('advanced_search','addressbook',$query['advanced_search']);
|
|
||||||
}
|
|
||||||
elseif(!$query['search'] && $old_state['advanced_search']) // eg. paging in an advanced search
|
elseif(!$query['search'] && $old_state['advanced_search']) // eg. paging in an advanced search
|
||||||
{
|
{
|
||||||
$query['advanced_search'] = $old_state['advanced_search'];
|
$query['advanced_search'] = $old_state['advanced_search'];
|
||||||
@ -1617,9 +1605,20 @@ $readonlys['button[vcard]'] = true;
|
|||||||
if(!empty($_content)) {
|
if(!empty($_content)) {
|
||||||
$response = new xajaxResponse();
|
$response = new xajaxResponse();
|
||||||
|
|
||||||
$index_nm = $GLOBALS['egw']->session->appsession($do_email ? 'email' : 'index','addressbook');
|
$query = $GLOBALS['egw']->session->appsession($do_email ? 'email' : 'index','addressbook');
|
||||||
$index_nm['search'] = $_content;
|
|
||||||
$GLOBALS['egw']->session->appsession($do_email ? 'email' : 'index','addressbook',$index_nm);
|
$query['advanced_search'] = array_intersect_key($_content,array_flip(array_merge($this->get_contact_columns(),array('operator','meth_select'))));
|
||||||
|
foreach ($query['advanced_search'] as $key => $value)
|
||||||
|
{
|
||||||
|
if(!$value) unset($query['advanced_search'][$key]);
|
||||||
|
}
|
||||||
|
$query['start'] = 0;
|
||||||
|
$query['search'] = '';
|
||||||
|
// store the index state in the session
|
||||||
|
$GLOBALS['egw']->session->appsession($do_email ? 'email' : 'index','addressbook',$query);
|
||||||
|
|
||||||
|
// store the advanced search in the session to call it again
|
||||||
|
$GLOBALS['egw']->session->appsession('advanced_search','addressbook',$query['advanced_search']);
|
||||||
|
|
||||||
$response->addScript("
|
$response->addScript("
|
||||||
var link = opener.location.href;
|
var link = opener.location.href;
|
||||||
@ -1628,7 +1627,6 @@ $readonlys['button[vcard]'] = true;
|
|||||||
xajax_eT_wrapper();
|
xajax_eT_wrapper();
|
||||||
");
|
");
|
||||||
return $response->getXML();
|
return $response->getXML();
|
||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user