- Fix inconsistency in participant / owner between planner & weekview

- Change default participant default to selected users
This commit is contained in:
Nathan Gray 2016-01-05 22:54:33 +00:00
parent 4439abc2b1
commit 4d0977f8f9
2 changed files with 12 additions and 3 deletions

View File

@ -393,7 +393,7 @@ class calendar_hooks
'name' => 'default_participant', 'name' => 'default_participant',
'values'=> $default_participants, 'values'=> $default_participants,
'help' => 'Participants automatically added to new events', 'help' => 'Participants automatically added to new events',
'default' => 0, 'default' => 'selected',
'xmlrpc' => False, 'xmlrpc' => False,
'admin' => False 'admin' => False
), ),

View File

@ -84,6 +84,15 @@ class calendar_uiforms extends calendar_ui
if (isset($_GET['owner'])) if (isset($_GET['owner']))
{ {
$owner = $_GET['owner']; $owner = $_GET['owner'];
if(is_array($owner))
{
$extra_participants += $owner;
$owner = count($owner) > 1 ? $this->user : $owner[0];
}
else
{
$extra_participants[] = $owner;
}
} }
else else
{ {