mirror of
https://github.com/moodle/moodle.git
synced 2025-08-09 19:06:41 +02:00
MDL-29766 Add drag and drop upload to filemanager / filepicker elements
This commit is contained in:
parent
0e84b1664d
commit
f08fac7c89
9 changed files with 441 additions and 4 deletions
|
@ -763,5 +763,16 @@ M.form_filemanager.init = function(Y, options) {
|
|||
item.style.display = '';
|
||||
}
|
||||
|
||||
new FileManagerHelper(options);
|
||||
var manager = new FileManagerHelper(options);
|
||||
var dndoptions = {
|
||||
filemanager: manager,
|
||||
acceptedtypes: options.accepted_types,
|
||||
clientid: options.client_id,
|
||||
maxfiles: options.maxfiles,
|
||||
maxbytes: options.maxbytes,
|
||||
itemid: options.itemid,
|
||||
repositories: manager.filepicker_options.repositories,
|
||||
containerprefix: '#filemanager-',
|
||||
};
|
||||
M.form_dndupload.init(Y, dndoptions);
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue