mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-27 00:09:13 +01:00
removed the "all future" field from participants states. Instead added uniform behaviour with existing event handling when editing a single recurrence or all recurrences. The message being displayed when editing a single recurrence read only is just meant as a proposal. Stylite usability PROs, please adjust this to whatever you want to.
This commit is contained in:
parent
35a0323027
commit
5b263e23eb
@ -326,7 +326,7 @@ class calendar_uiforms extends calendar_ui
|
||||
break;
|
||||
|
||||
default: // existing participant row
|
||||
foreach(array('uid','status','status_recurrence','quantity') as $name)
|
||||
foreach(array('uid','status','quantity') as $name)
|
||||
{
|
||||
$$name = $data[$name];
|
||||
}
|
||||
@ -348,7 +348,7 @@ class calendar_uiforms extends calendar_ui
|
||||
}
|
||||
if ($data['old_status'] != $status)
|
||||
{
|
||||
if ($this->bo->set_status($event['id'],$uid,$status,$event['recur_type'] != MCAL_RECUR_NONE && !$status_recurrence ? $content['participants']['status_date'] : 0))
|
||||
if ($this->bo->set_status($event['id'],$uid,$status,isset($content['edit_single']) ? $content['participants']['status_date'] : 0))
|
||||
{
|
||||
// refreshing the calendar-view with the changed participant-status
|
||||
$msg = lang('Status changed');
|
||||
@ -637,7 +637,12 @@ class calendar_uiforms extends calendar_ui
|
||||
{
|
||||
unset($event[$name]);
|
||||
}
|
||||
return lang('Exception created - you can now edit or delete it');
|
||||
if($this->bo->check_perms(EGW_ACL_EDIT,$event))
|
||||
{
|
||||
return lang('Exception created - you can now edit or delete it');
|
||||
} else {
|
||||
return lang('You can now edit your participation status on this single recurrence');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@ -752,7 +757,6 @@ class calendar_uiforms extends calendar_ui
|
||||
'print' => array('label' => 'Print', 'title' => 'Print this event'),
|
||||
'mail' => array('label' => 'Mail all participants', 'title' => 'compose a mail to all participants after the event is saved'),
|
||||
),
|
||||
'status_recurrence' => array('' => 'for this event', 'A' => 'for all future events'),
|
||||
);
|
||||
unset($sel_options['status']['G']);
|
||||
if (!is_array($event))
|
||||
@ -876,7 +880,7 @@ class calendar_uiforms extends calendar_ui
|
||||
'quantity' => substr($status,1),
|
||||
);
|
||||
$readonlys[$row.'[quantity]'] = $type == 'u' || !isset($this->bo->resources[$type]['max_quantity']);
|
||||
$readonlys[$row.'[status]'] = $readonlys[$row.'[status_recurrence]'] = !$this->bo->check_status_perms($uid,$event);
|
||||
$readonlys[$row.'[status]'] = !$this->bo->check_status_perms($uid,$event);
|
||||
$readonlys["delete[$uid]"] = !$this->bo->check_perms(EGW_ACL_EDIT,$event);
|
||||
// todo: make the participants available as links with email as title
|
||||
if ($name == 'accounts')
|
||||
@ -940,7 +944,6 @@ class calendar_uiforms extends calendar_ui
|
||||
}
|
||||
}
|
||||
$content['participants']['status_date'] = $preserv['actual_date'];
|
||||
$content['participants']['hide_status_recurrence'] = $event['recur_type'] == MCAL_RECUR_NONE;
|
||||
$preserv = array_merge($preserv,$content);
|
||||
|
||||
if ($event['alarm'])
|
||||
@ -1050,8 +1053,10 @@ class calendar_uiforms extends calendar_ui
|
||||
//echo "preserv="; _debug_array($preserv);
|
||||
//echo "readonlys="; _debug_array($readonlys);
|
||||
//echo "sel_options="; _debug_array($sel_options);
|
||||
$GLOBALS['egw_info']['flags']['app_header'] = lang('calendar') . ' - ' . (!$event['id'] ? lang('Add') : ($view ? lang('View') :
|
||||
($content['edit_single'] ? lang('Create exception') : ($content['recur_type'] ? lang('Edit series') : lang('Edit')))));
|
||||
$GLOBALS['egw_info']['flags']['app_header'] = lang('calendar') . ' - '
|
||||
. (!$event['id'] ? lang('Add')
|
||||
: ($view ? ($content['edit_single'] ? lang('View exception') : ($content['recur_type'] ? lang('View series') : lang('View')))
|
||||
: ($content['edit_single'] ? lang('Create exception') : ($content['recur_type'] ? lang('Edit series') : lang('Edit')))));
|
||||
$GLOBALS['egw_info']['flags']['java_script'] .= "<script>\n$js\n</script>\n";
|
||||
|
||||
$content['cancel_needs_refresh'] = (bool)$_GET['cancel_needs_refresh'];
|
||||
|
File diff suppressed because one or more lines are too long
@ -69,13 +69,12 @@
|
||||
</rows>
|
||||
</grid>
|
||||
</template>
|
||||
<template id="calendar.edit.participants" template="" lang="" group="0" version="1.3.003">
|
||||
<template id="calendar.edit.participants" template="" lang="" group="0" version="1.3.004">
|
||||
<grid width="100%" height="200" overflow="auto" id="participants">
|
||||
<columns>
|
||||
<column width="95"/>
|
||||
<column/>
|
||||
<column/>
|
||||
<column disabled="@hide_status_recurrence"/>
|
||||
<column/>
|
||||
<column/>
|
||||
</columns>
|
||||
@ -89,7 +88,6 @@
|
||||
<link-entry id="resource" options="@cal_resources"/>
|
||||
</vbox>
|
||||
<int options="1,,3" id="quantity"/>
|
||||
<description/>
|
||||
<button label="Add" id="add"/>
|
||||
<description/>
|
||||
</row>
|
||||
@ -97,7 +95,6 @@
|
||||
<description value="Type"/>
|
||||
<description value="Participants"/>
|
||||
<description value="Quantity"/>
|
||||
<description value="All future"/>
|
||||
<description value="Status"/>
|
||||
<description value="Actions"/>
|
||||
</row>
|
||||
@ -105,7 +102,6 @@
|
||||
<description id="${row}[app]"/>
|
||||
<description rows="1" cols="2" id="${row}[title]" no_lang="1"/>
|
||||
<int id="${row}[quantity]" options="1,,3"/>
|
||||
<checkbox id="${row}[status_recurrence]" align="center"/>
|
||||
<menulist>
|
||||
<menupopup id="${row}[status]" no_lang="1" onchange="1"/>
|
||||
</menulist>
|
||||
|
Loading…
Reference in New Issue
Block a user