From 0c0924738ca15ffd8d46f64f633f6195ffcf0fae Mon Sep 17 00:00:00 2001 From: Lars Kneschke Date: Sun, 1 Jul 2001 17:29:49 +0000 Subject: [PATCH] added some german translations added a way to inlcude plugins into editaccount.php --- admin/editaccount.php | 29 ++++++++++++++++++- admin/inc/hook_edit_account.inc.php | 11 +++++++ admin/setup/phpgw_de.lang | 1 + admin/setup/phpgw_en.lang | 1 + admin/templates/default/account_form.tpl | 24 +++++++++++++-- admin/templates/default/account_form_ldap.tpl | 6 ++++ calendar/setup/phpgw_de.lang | 8 +++++ 7 files changed, 76 insertions(+), 4 deletions(-) create mode 100644 admin/inc/hook_edit_account.inc.php diff --git a/admin/editaccount.php b/admin/editaccount.php index 836031c002..d2f82cec84 100755 --- a/admin/editaccount.php +++ b/admin/editaccount.php @@ -23,7 +23,7 @@ // creates the html for the user data function createPageBody($_account_id,$_userData='',$_errors='') { - global $phpgw, $phpgw_info; + global $phpgw, $phpgw_info, $t; $t = CreateObject('phpgwapi.Template',PHPGW_APP_TPL); $t->set_unknowns('remove'); @@ -39,6 +39,7 @@ $t->set_block('account','form','form'); $t->set_block('account','form_passwordinfo','form_passwordinfo'); $t->set_block('account','form_buttons_','form_buttons_'); + $t->set_block('account','link_row','link_row'); print_debug('Type : '.gettype($_userData).'
_userData(size) = "'.$_userData.'"('.strlen($_userData).')'); if (is_array($_userData)) @@ -230,6 +231,8 @@ 'permissions_list' => $appRightsOutput ); $t->set_var($var); + + $phpgw->common->hook('edit_account'); echo $t->fp('out','form'); } @@ -369,6 +372,30 @@ } } + function display_section($appname,$title,$file) + { + global $phpgw, $phpgw_info, $account_id; + $i = 0; + $color[1] = $phpgw_info['theme']['row_off']; + $color[0] = $phpgw_info['theme']['row_on']; + while(list($text,$url) = each($file)) + { + $url = $phpgw->link($url,"account_id=$account_id"); + section_item($url,lang($text),$color[$i%2]); + $i++; + } + } + + function section_item($pref_link='',$pref_text='', $bgcolor) + { + global $phpgw, $phpgw_info, $t; + + $t->set_var('pref_link',$pref_link); + $t->set_var('pref_text',$pref_text); + $t->set_var('tr_color',$bgcolor); + $t->parse('rows','link_row',True); + } + // todo // not needed if i use the same file for new users too if (! $account_id) diff --git a/admin/inc/hook_edit_account.inc.php b/admin/inc/hook_edit_account.inc.php new file mode 100644 index 0000000000..92acd7b031 --- /dev/null +++ b/admin/inc/hook_edit_account.inc.php @@ -0,0 +1,11 @@ + '/admin/editaccount.php' + ); +//Do not modify below this line + display_section($appname,$title,$file); +} +?> diff --git a/admin/setup/phpgw_de.lang b/admin/setup/phpgw_de.lang index 550f7f8ebf..bea06cc5c1 100644 --- a/admin/setup/phpgw_de.lang +++ b/admin/setup/phpgw_de.lang @@ -78,3 +78,4 @@ view sessions admin de Sitzungen anzeigen you must add at least 1 permission to this account admin de Sie müssen diesem Konto mindestens eine Berechtigung zuteilen you must enter an application name and title. admin de Sie müssen der Anwendung einen Namen und einen Titel geben. you must select a file type admin de Sie müssen einen Filetyp auswählen +userdata admin de Benutzerdaten diff --git a/admin/setup/phpgw_en.lang b/admin/setup/phpgw_en.lang index 54c834694d..c9c64ec1b9 100644 --- a/admin/setup/phpgw_en.lang +++ b/admin/setup/phpgw_en.lang @@ -96,3 +96,4 @@ you must add at least 1 permission or group to this account admin en You must ad you must enter an application name and title. admin en You must enter an application name and title. you must select a file type admin en You must select a file type You will need to remove the subcategories before you can delete the parent category admin en You will need to remove the subcategories before you can delete the parent category ! +userdata admin en userdata diff --git a/admin/templates/default/account_form.tpl b/admin/templates/default/account_form.tpl index 70fa744ea1..ae3e4a1685 100644 --- a/admin/templates/default/account_form.tpl +++ b/admin/templates/default/account_form.tpl @@ -4,7 +4,18 @@
- +
+ + + + +
+ + + + + {rows} +
 
+
+ @@ -38,11 +49,12 @@ {permissions_list} - {gui_hooks} - {form_buttons}
 
+
@@ -71,3 +83,9 @@ {account_lastloginfrom} + + + +   {pref_text} + + diff --git a/admin/templates/default/account_form_ldap.tpl b/admin/templates/default/account_form_ldap.tpl index ea81230e1d..b7448ba6da 100644 --- a/admin/templates/default/account_form_ldap.tpl +++ b/admin/templates/default/account_form_ldap.tpl @@ -72,3 +72,9 @@ {account_lastloginfrom} + + + +   {pref_text} + + diff --git a/calendar/setup/phpgw_de.lang b/calendar/setup/phpgw_de.lang index 9b8ca57c14..f85b4cf6b0 100644 --- a/calendar/setup/phpgw_de.lang +++ b/calendar/setup/phpgw_de.lang @@ -78,3 +78,11 @@ you have not entered a\nbrief description calendar de Sie haben keine a\nKurzbes you have not entered a\nvalid time of day calendar de Sie haben keine a\ngültige Tageszeit eingegeben. you must enter one or more search keywords calendar de Sie müssen einen oder mehrere Suchbegriffe angeben your suggested time of x - x conflicts with the following existing calendar entries: calendar de Der von Ihnen gewählte Zeitraum %1 - %2 führt zu Konflikten mit folgenden bereits existierenden Kalendereinträgen: +Calendar Holiday Management calendar de Feiertage verwalten +Countries calendar de Länder +Holidays calendar de Feiertage +Back calendar de zurück +Holiday calendar de Feiertag +Reset calendar de Zurücksetzen +Occurence calendar de Wiederholung +Observance Rule calendar de Observance Rule