Do not show actions which user has no run permission

This commit is contained in:
Hadi Nategh 2017-04-21 16:21:49 +02:00
parent 4ee931b203
commit c47c6d19f0
2 changed files with 11 additions and 0 deletions

View File

@ -248,6 +248,12 @@ class mail_compose
}
unset($actions['pgp']);
}
// remove vfs actions if the user has no run access to filemanager
if (!$GLOBALS['egw_info']['user']['apps']['filemanager'])
{
unset($actions['save2vfs']);
unset($actions['selectFromVFSForCompose']);
}
return $actions;
}

View File

@ -1300,6 +1300,11 @@ class mail_ui
{
unset($actions['calendar']);
}
// remove vfs actions if the user has no run access to filemanager
if (!$GLOBALS['egw_info']['user']['apps']['filemanager'])
{
unset($actions['save']['children']['save2filemanager']);
}
return $actions;
}