From ddecf65549366d8b8ea7be6edf38809a7aa9e0c3 Mon Sep 17 00:00:00 2001 From: skeeter Date: Thu, 19 Apr 2001 17:38:42 +0000 Subject: [PATCH] Fix for bug #417366 --- calendar/inc/class.calendar.inc.php | 17 +++++++++-------- calendar/preferences.php | 4 ++-- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/calendar/inc/class.calendar.inc.php b/calendar/inc/class.calendar.inc.php index 99533202af..4e2c4f6241 100755 --- a/calendar/inc/class.calendar.inc.php +++ b/calendar/inc/class.calendar.inc.php @@ -1326,8 +1326,8 @@ class calendar extends calendar_ $p->set_var($var); - $first_hour = (int)$phpgw_info['user']['preferences']['calendar']['workdaystarts'] + 1; - $last_hour = (int)$phpgw_info['user']['preferences']['calendar']['workdayends'] + 1; + $first_hour = (int)$phpgw_info['user']['preferences']['calendar']['workdaystarts']; + $last_hour = (int)$phpgw_info['user']['preferences']['calendar']['workdayends']; $events = Array( CreateObject('calendar.calendar_item') @@ -1634,18 +1634,19 @@ class calendar extends calendar_ } $str = ''; - for($i=0;$iparticipants);$i++) + reset($event->participants); + while (list($key,$value) = each($event->participants)) { - if($i) + if($str) { $str .= '
'; } - $status = $this->get_long_status($event->status[$i]); + $status = $this->get_long_status($event->status[$key]); - $str .= $phpgw->common->grab_owner_name($event->participants[$i]).' ('; + $str .= $phpgw->common->grab_owner_name($event->participants[$key]).' ('; - if($event->participants[$i] == $this->owner && $this->check_perms(PHPGW_ACL_EDIT) == True) + if($event->participants[$key] == $this->owner && $this->check_perms(PHPGW_ACL_EDIT) == True) { $str .= ''.$status.''; } @@ -1653,7 +1654,7 @@ class calendar extends calendar_ { $str .= $status; } - $str .= ')'; + $str .= ')'."\n"; } $var = Array( 'field' => lang('Participants'), diff --git a/calendar/preferences.php b/calendar/preferences.php index 880996e7ba..9335216b72 100644 --- a/calendar/preferences.php +++ b/calendar/preferences.php @@ -127,7 +127,7 @@ for ($i=0; $i<24; $i++) { $str .= ''; + . $phpgw->common->formattime($i,'00') . ''; } $str .= ''; display_item(lang('work day starts on'),$str); @@ -137,7 +137,7 @@ for ($i=0; $i<24; $i++) { $str .= ''; + . $phpgw->common->formattime($i,'00') . ''; } $str .= ''; display_item(lang('work day ends on'),$str);