mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-25 16:19:00 +01:00
Filemanager: Fix url as comment on uploaded files
This commit is contained in:
parent
8fb0048c17
commit
d185a53f8e
@ -1558,6 +1558,7 @@ class filemanager_ui
|
|||||||
* @param string $action eg. 'delete', ...
|
* @param string $action eg. 'delete', ...
|
||||||
* @param array $selected selected path(s)
|
* @param array $selected selected path(s)
|
||||||
* @param string $dir=null current directory
|
* @param string $dir=null current directory
|
||||||
|
* @param string[] $props Properties for the file, eg: [comment => 'Latest from Ralf']
|
||||||
* @see static::action()
|
* @see static::action()
|
||||||
*/
|
*/
|
||||||
public static function ajax_action($action, $selected, $dir=null, $props=null)
|
public static function ajax_action($action, $selected, $dir=null, $props=null)
|
||||||
|
@ -306,7 +306,7 @@ var filemanagerAPP = /** @class */ (function (_super) {
|
|||||||
var widget = _event.data;
|
var widget = _event.data;
|
||||||
var value = widget.getValue();
|
var value = widget.getValue();
|
||||||
value.conflict = _conflict;
|
value.conflict = _conflict;
|
||||||
egw.json(_target, ['upload', value, _path, this.egw.window.location.pathname], this._upload_callback, this, true, this).sendRequest();
|
egw.json(_target, ['upload', value, _path, { ui_path: this.egw.window.location.pathname }], this._upload_callback, this, true, this).sendRequest();
|
||||||
widget.set_value('');
|
widget.set_value('');
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -349,7 +349,7 @@ export class filemanagerAPP extends EgwApp
|
|||||||
let widget = _event.data;
|
let widget = _event.data;
|
||||||
let value = widget.getValue();
|
let value = widget.getValue();
|
||||||
value.conflict = _conflict;
|
value.conflict = _conflict;
|
||||||
egw.json(_target, ['upload', value, _path, this.egw.window.location.pathname],
|
egw.json(_target, ['upload', value, _path, {ui_path: this.egw.window.location.pathname}],
|
||||||
this._upload_callback, this, true, this
|
this._upload_callback, this, true, this
|
||||||
).sendRequest();
|
).sendRequest();
|
||||||
widget.set_value('');
|
widget.set_value('');
|
||||||
|
@ -63,7 +63,7 @@ class HiddenUpload extends AnonymousList
|
|||||||
* @param string $action Should be 'upload'
|
* @param string $action Should be 'upload'
|
||||||
* @param $selected Array of file information
|
* @param $selected Array of file information
|
||||||
* @param string $dir Target directory
|
* @param string $dir Target directory
|
||||||
* @param $props path the sharing UI is running eg. "/egroupware/share.php/<token>"
|
* @param string[] $props ui_path=>path the sharing UI is running eg. "/egroupware/share.php/<token>"
|
||||||
* @param string[] $arr Result
|
* @param string[] $arr Result
|
||||||
*
|
*
|
||||||
* @throws Api\Exception\AssertionFailed
|
* @throws Api\Exception\AssertionFailed
|
||||||
@ -72,7 +72,7 @@ class HiddenUpload extends AnonymousList
|
|||||||
{
|
{
|
||||||
Translation::add_app('filemanager');
|
Translation::add_app('filemanager');
|
||||||
$vfs = Vfs::mount();
|
$vfs = Vfs::mount();
|
||||||
$GLOBALS['egw']->sharing[Sharing::get_token($props)]->redo();
|
$GLOBALS['egw']->sharing[Sharing::get_token($props['ui_path'])]->redo();
|
||||||
parent::handle_upload_action($action, $selected, $dir, null, $arr);
|
parent::handle_upload_action($action, $selected, $dir, null, $arr);
|
||||||
if ($arr['files'])
|
if ($arr['files'])
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user