From 2ec1a77daf898087ced4c954a9a33db4059f1a25 Mon Sep 17 00:00:00 2001 From: Klaus Leithoff Date: Mon, 10 Mar 2008 12:15:47 +0000 Subject: [PATCH] attempt to fix the problem with the stick org_view problem in addressbook. col_filter is not reseted if org_view criteria is set to all. --- addressbook/inc/class.uicontacts.inc.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/addressbook/inc/class.uicontacts.inc.php b/addressbook/inc/class.uicontacts.inc.php index 8c3bb75e47..d6c5d75674 100644 --- a/addressbook/inc/class.uicontacts.inc.php +++ b/addressbook/inc/class.uicontacts.inc.php @@ -718,6 +718,12 @@ class uicontacts extends bocontacts } else { $old_state = $GLOBALS['egw']->session->appsession($do_email ? 'email' : 'index','addressbook'); } + if (!isset($this->org_views[(string) $query['org_view']])) // we dont have an org view, unset the according col_filters + { + if (isset($query['col_filter']['org_name'])) unset($query['col_filter']['org_name']); + if (isset($query['col_filter']['adr_one_locality'])) unset($query['col_filter']['adr_one_locality']); + if (isset($query['col_filter']['org_unit'])) unset($query['col_filter']['org_unit']); + } if (isset($this->org_views[(string) $query['org_view']])) // we have an org view, reset the advanced search {