mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-22 07:53:39 +01:00
if initial load is done via GET request (idots template or share.php), get_rows cant call app.filemanager.set_readonly
setting now value "initial_path_readonly" in content and use that in app.filemanager.et2_ready() to call set_readonly()
This commit is contained in:
parent
69400d8d3a
commit
00b22e82bf
@ -482,6 +482,10 @@ class filemanager_ui
|
||||
{
|
||||
$tpl->setElementAttribute('nm[buttons][upload]', 'drop_target', 'popupMainDiv');
|
||||
}
|
||||
// if initial load is done via GET request (idots template or share.php)
|
||||
// get_rows cant call app.filemanager.set_readonly, so we need to do that here
|
||||
$content['initial_path_readonly'] = !egw_vfs::is_writable($content['nm']['path']);
|
||||
|
||||
$tpl->exec('filemanager.filemanager_ui.index',$content,$sel_options,$readonlys,array('nm' => $content['nm']));
|
||||
}
|
||||
|
||||
|
@ -83,6 +83,11 @@ app.classes.filemanager = AppJS.extend(
|
||||
// get clipboard from browser localstore and update button tooltips
|
||||
this.clipboard_tooltips();
|
||||
|
||||
// calling set_readonly for initial path
|
||||
if (this.et2.getArrayMgr('content').getEntry('initial_path_readonly'))
|
||||
{
|
||||
this.readonly = [this.et2.getArrayMgr('content').getEntry('nm[path]'), true];
|
||||
}
|
||||
if (typeof this.readonly != 'undefined')
|
||||
{
|
||||
this.set_readonly.apply(this, this.readonly);
|
||||
|
Loading…
Reference in New Issue
Block a user