From 7b6c0acbd908f0a0e9a841f9c40f90aeaa336cb3 Mon Sep 17 00:00:00 2001 From: slypup Date: Mon, 21 May 2001 20:32:17 +0000 Subject: [PATCH] fixes so that hr works properly --- addressbook/add.php | 3 ++- addressbook/edit.php | 3 ++- addressbook/inc/functions.inc.php | 4 ++-- addressbook/templates/default/edit.tpl | 6 ++++++ 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/addressbook/add.php b/addressbook/add.php index 09f2f258e7..0bdc36c470 100755 --- a/addressbook/add.php +++ b/addressbook/add.php @@ -88,8 +88,9 @@ $fields = addressbook_read_last_entry($qfields); $newid = $fields[0]['id']; + $tid = $fields[0]['tid']; Header("Location: " - . $phpgw->link('/addressbook/edit.php',"ab_id=$newid&order=$order&sort=$sort&filter=$filter&start=$start&query=$query&cat_id=$cat_id")); + . $phpgw->link('/addressbook/edit.php',"ab_id=$newid&order=$order&sort=$sort&filter=$filter&start=$start&query=$query&cat_id=$cat_id&tid=$tid")); } else { diff --git a/addressbook/edit.php b/addressbook/edit.php index 2a1e511e76..f3b0bef51e 100755 --- a/addressbook/edit.php +++ b/addressbook/edit.php @@ -81,6 +81,7 @@ $t->set_var('query',$query); $t->set_var('start',$start); $t->set_var('cat_id',$cat_id); + $t->set_var('tid',$tid); $t->set_var('lang_ok',lang('ok')); $t->set_var('lang_clear',lang('clear')); $t->set_var('lang_cancel',lang('cancel')); @@ -212,7 +213,7 @@ $userid = $phpgw_info['user']['account_id']; } - addressbook_update_entry($ab_id,$userid,$fields,$fields['access'],$fields['cat_id']); + addressbook_update_entry($ab_id,$userid,$fields,$fields['access'],$fields['cat_id'],$tid); $referer = urlencode($referer); Header("Location: " . $phpgw->link('/addressbook/view.php',"ab_id=$ab_id&order=$order&sort=$sort&filter=$filter&start=$start&query=$query&cat_id=$cat_id&referer=$referer")); diff --git a/addressbook/inc/functions.inc.php b/addressbook/inc/functions.inc.php index 11c994f6d0..d0428ddbb6 100755 --- a/addressbook/inc/functions.inc.php +++ b/addressbook/inc/functions.inc.php @@ -276,12 +276,12 @@ return $ab_id; } - function addressbook_update_entry($id,$userid,$fields,$access,$cat_id) + function addressbook_update_entry($id,$userid,$fields,$access,$cat_id,$tid) { global $this,$rights; if ($rights & PHPGW_ACL_EDIT) { - $this->update($id,$userid,$fields,$access,$cat_id); + $this->update($id,$userid,$fields,$access,$cat_id,$tid); } return; } diff --git a/addressbook/templates/default/edit.tpl b/addressbook/templates/default/edit.tpl index 23cdb15adc..afca552665 100644 --- a/addressbook/templates/default/edit.tpl +++ b/addressbook/templates/default/edit.tpl @@ -3,6 +3,8 @@ + + @@ -16,6 +18,8 @@ {cancel_link} + + @@ -26,6 +30,8 @@ + +