"fixed print without edit rights"

This commit is contained in:
Ralf Becker 2009-10-01 19:21:37 +00:00
parent d77f7998af
commit cc91687826

View File

@ -433,27 +433,19 @@ class calendar_uiforms extends calendar_ui
case 'apply': case 'apply':
if ($event['id'] && !$this->bo->check_perms(EGW_ACL_EDIT,$event)) if ($event['id'] && !$this->bo->check_perms(EGW_ACL_EDIT,$event))
{ {
if ($button == 'mail') // just mail without edit-rights is ok switch ($button)
{ {
case 'mail': // just mail without edit-rights is ok
$js = $this->custom_mail($event,false); $js = $this->custom_mail($event,false);
break; break 2;
} case 'print': // just print without edit-rights is ok
$msg = lang('Permission denied');
break;
}
if ($event['id'] && !$this->bo->check_perms(EGW_ACL_EDIT,$event))
{
if ($button == 'print') // just print without edit-rights is ok
{
$js = $this->custom_print($event,false); $js = $this->custom_print($event,false);
break; break 2;
} }
$msg = lang('Permission denied'); $msg = lang('Permission denied');
$button = ''; $button = '';
break; break;
} }
if ($event['start'] > $event['end']) if ($event['start'] > $event['end'])
{ {
$msg = lang('Error: Starttime has to be before the endtime !!!'); $msg = lang('Error: Starttime has to be before the endtime !!!');