* Calendar: taking direct booking permission into account when copying events including resources (my.stylite bug #2839)

This commit is contained in:
Ralf Becker 2012-05-15 11:20:07 +00:00
parent c4b76cf4e3
commit ca6874b89b

View File

@ -494,7 +494,9 @@ class calendar_uiforms extends calendar_ui
{
if($type == 'u' && $id == $event['owner']) continue;
calendar_so::split_status($status, $quantity, $role);
$response = calendar_so::combine_status('U',$quantity,$role);
// if resource defines callback for status of new status (eg. Resources app acknowledges direct booking acl), call it
$status = isset($this->bo->resources[$type]['new_status']) ? ExecMethod($this->bo->resources[$type]['new_status'],$id) : 'U';
$response = calendar_so::combine_status($status,$quantity,$role);
}
}
$preserv['view'] = $preserv['edit_single'] = false;