From f0b8ed8280dfd82d0c96174d5f0ea7f1c622eaf8 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Fri, 3 Mar 2006 18:56:01 +0000 Subject: [PATCH] do not add the planner-default-group to the participants, if add is called from the planner --- calendar/inc/class.uiforms.inc.php | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/calendar/inc/class.uiforms.inc.php b/calendar/inc/class.uiforms.inc.php index aa0db81b21..5489291343 100644 --- a/calendar/inc/class.uiforms.inc.php +++ b/calendar/inc/class.uiforms.inc.php @@ -68,7 +68,15 @@ class uiforms extends uical { $extra_participants = $_GET['participants'] ? explode(',',$_GET['participants']) : array(); - $owner = isset($_GET['owner']) ? $_GET['owner'] : $this->owner; + if (isset($_GET['owner'])) + { + $owner = $_GET['owner']; + } + // dont set the planner start group as owner/participants if called from planner + elseif ($this->view != 'planner' || $this->owner != $this->cal_prefs['planner_start_with_group']) + { + $owner = $this->owner; + } if (!$owner || !is_numeric($owner) || $GLOBALS['egw']->accounts->get_type($owner) != 'u' || !$this->bo->check_perms(EGW_ACL_ADD,0,$owner)) { @@ -78,7 +86,7 @@ class uiforms extends uical } $owner = $this->user; } - //echo "

this->owner=$this->owner, _GET[owner]=$_GET[owner], user=$this->user => owner=$owner

\n"; + //echo "

this->owner=$this->owner, _GET[owner]=$_GET[owner], user=$this->user => owner=$owner, extra_participants=".implode(',',$extra_participants)."

\n"; // by default include the owner as participant (the user can remove him) $extra_participants[] = $owner;