mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-21 23:43:17 +01:00
Api: Improve handling of accessing multiple shares (Collabora or directory) in new tabs while logged in
This commit is contained in:
parent
657119b389
commit
ba84d3170d
@ -526,6 +526,7 @@ class Sharing
|
||||
}*/
|
||||
if($this->use_collabora())
|
||||
{
|
||||
unset($GLOBALS['egw']->sharing);
|
||||
$ui = new \EGroupware\Collabora\Ui();
|
||||
return $ui->editor($this->share['share_path']);
|
||||
}
|
||||
|
@ -65,7 +65,11 @@ class AnonymousList extends filemanager_ui
|
||||
*/
|
||||
static function get_home_dir()
|
||||
{
|
||||
return $GLOBALS['egw']->sharing->get_root();
|
||||
if(isset($GLOBALS['egw']->sharing))
|
||||
{
|
||||
return $GLOBALS['egw']->sharing->get_root();
|
||||
}
|
||||
return '/';
|
||||
}
|
||||
|
||||
/**
|
||||
@ -79,7 +83,7 @@ class AnonymousList extends filemanager_ui
|
||||
$group = 1;
|
||||
// do not add edit setting action when we are in sharing
|
||||
unset($actions['edit']);
|
||||
if (Vfs::is_writable($GLOBALS['egw']->sharing->get_root()))
|
||||
if (isset($GLOBALS['egw']->sharing) && Vfs::is_writable($GLOBALS['egw']->sharing->get_root()))
|
||||
{
|
||||
return $actions;
|
||||
}
|
||||
|
@ -27,7 +27,7 @@ $GLOBALS['egw_info'] = array(
|
||||
|
||||
include('./header.inc.php');
|
||||
|
||||
if (!isset($GLOBALS['egw']->sharing))
|
||||
if (!isset($GLOBALS['egw']->sharing) || \EGroupware\Api\Sharing::get_token() !== $GLOBALS['egw']->sharing->get_token())
|
||||
{
|
||||
Sharing::create_session(true); // true = mount into existing session
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user