From fc24544f11dee9c9dd5eb553b4e4ef95db842462 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cornelius=20Wei=C3=9F?= Date: Mon, 7 Nov 2005 23:06:16 +0000 Subject: [PATCH] fixed not working work email in advanced search added a more clear WARNING for deletebutton in adv. search --- addressbook/inc/class.socontacts.inc.php | 6 ++-- addressbook/inc/class.uicontacts.inc.php | 38 +++++++++++------------- addressbook/setup/phpgw_de.lang | 2 +- addressbook/setup/phpgw_en.lang | 2 +- 4 files changed, 23 insertions(+), 25 deletions(-) diff --git a/addressbook/inc/class.socontacts.inc.php b/addressbook/inc/class.socontacts.inc.php index 292ae9b41f..4624e03fbc 100755 --- a/addressbook/inc/class.socontacts.inc.php +++ b/addressbook/inc/class.socontacts.inc.php @@ -169,7 +169,7 @@ class socontacts */ function search($criteria,$only_keys=True,$order_by='',$extra_cols='',$wildcard='',$empty=False,$op='AND',$start=false,$filter=null,$join='',$need_full_no_count=false) { - // echo 'socontacts::search->criteria:'; _debug_array($criteria); + //echo 'socontacts::search->criteria:'; _debug_array($criteria); // We just want to deal with generalized vars, to simpyfie porting of this code to so_sql later... $this->main_id = $this->somain->contacts_id; @@ -182,7 +182,7 @@ class socontacts { $extra_crit_key = substr($crit_key,1); $criteria_extra[$extra_crit_key][$this->extra_key] = $extra_crit_key; - $criteria_extra[$extra_crit_key][$this->extra_value] = $extra_crit_val; + $criteria_extra[$extra_crit_key][$this->extra_value] = $crit_val; } unset($criteria[$crit_key]); } @@ -239,7 +239,7 @@ class socontacts $expr .= ',$resultextra['.$i.']'; } eval('$merge = array_merge_recursive('.$expr.');'); - $resultextra = array_unique($merge[$this->extra_id]); + $resultextra = array_unique((array)$merge[$this->extra_id]); } } // _debug_array($resultextra); diff --git a/addressbook/inc/class.uicontacts.inc.php b/addressbook/inc/class.uicontacts.inc.php index 3f48a9ac70..86ae11bbde 100644 --- a/addressbook/inc/class.uicontacts.inc.php +++ b/addressbook/inc/class.uicontacts.inc.php @@ -140,33 +140,31 @@ class uicontacts extends bocontacts 'n_given' => lang('first name'), 'n_family' => lang('last name'), 'email_home' => lang('home email'), - 'email_work' => lang('work email'), + 'email' => lang('work email'), 'tel_home' => lang('tel home'), ); - - $content['advs']['actions'] = array( -// 'email' => array( -// 'type' => 'button', -// 'options' => array( -// 'label' => lang('email'), -// 'no_lang' => true, -// )), - 'delete' => array( + +/* $content['advs']['actions']['email'] = array( + 'type' => 'button', + 'options' => array( + 'label' => lang('email'), + 'no_lang' => true, + )); + $content['advs']['actions']['export'] = array( + 'type' => 'button', + 'options' => array( + 'label' => lang('export'), + 'no_lang' => true, + ));*/ + $content['advs']['actions']['delete'] = array( 'type' => 'button', 'method' => 'addressbook.bocontacts.delete', 'options' => array( 'label' => lang('delete'), 'no_lang' => true, - 'onclick' => 'if(!confirm(\''. lang('Do you really want to delte this contacts?'). '\')) return false;', - )), -// 'export' => array( -// 'type' => 'button', -// 'options' => array( -// 'label' => lang('export'), -// 'no_lang' => true, -// )), - ); - + 'onclick' => 'if(!confirm(\''. lang('WARNING: All contacts found will be deleted!'). '\')) return false;', + )); + for($i = -23; $i<=23; $i++) $tz[$i] = ($i > 0 ? '+' : '').$i; $sel_options['tz'] = $tz + array('' => lang('doesn\'t matter')); diff --git a/addressbook/setup/phpgw_de.lang b/addressbook/setup/phpgw_de.lang index 25bdc3dba4..b0f1828c58 100644 --- a/addressbook/setup/phpgw_de.lang +++ b/addressbook/setup/phpgw_de.lang @@ -55,7 +55,6 @@ debug output in browser addressbook de Debugausgaben in Browser default filter addressbook de Standardfilter delete a single entry by passing the id. addressbook de Löscht einen einzelnen Eintrag durch Übergabe seiner ID. department common de Abteilung -do you really want to delte this contacts? addressbook de Wollen sie diesen Kontakt wirklich löschen? doesn't matter addressbook de egal domestic addressbook de Wohnung download addressbook de Herunterladen @@ -174,6 +173,7 @@ vcards require a last name entry. addressbook de VCards ben video phone addressbook de Bildtelefon voice phone addressbook de Telefon warning!! ldap is valid only if you are not using contacts for accounts storage! admin de WARNUNG!! LDAP darf nur verwendet werden, wenn sie die Benutzerkonten nicht im Adressbuch speichern! +warning: all contacts found will be deleted! addressbook de WARNUNG: Alle gefundenen Kontakte werden gelöscht! work phone addressbook de Tel dienstl. you are not permitted to delete contact %1 addressbook de Sie haben nicht die Berechtigungen um den Kontakt %1 zu löschen you are not permittet to delete this contact addressbook de Sie haben nicht die Berechtigung diesen Kontakt zu löschen diff --git a/addressbook/setup/phpgw_en.lang b/addressbook/setup/phpgw_en.lang index 40e3c93c39..f90652b87f 100644 --- a/addressbook/setup/phpgw_en.lang +++ b/addressbook/setup/phpgw_en.lang @@ -55,7 +55,6 @@ debug output in browser addressbook en Debug output in browser default filter addressbook en Default Filter delete a single entry by passing the id. addressbook en Delete a single entry by passing the id. department common en Department -do you really want to delte this contacts? addressbook en Do you really want to delte this contacts? doesn't matter addressbook en doesn't matter domestic addressbook en Domestic download addressbook en Download @@ -174,6 +173,7 @@ vcards require a last name entry. addressbook en Vcards require a last name entr video phone addressbook en Video Phone voice phone addressbook en Voice Phone warning!! ldap is valid only if you are not using contacts for accounts storage! admin en WARNING!! LDAP is valid only if you are NOT using contacts for accounts storage! +warning: all contacts found will be deleted! addressbook en WARNING: All contacts found will be deleted! work phone addressbook en Work Phone write (update or add) a single entry by passing the fields. addressbook en Write (update or add) a single entry by passing the fields. you are not permitted to delete contact %1 addressbook en You are not permitted to delete contact %1