forked from projects/fipamo
FIX: misnamed sorting attribute for uploaded files
when creating new ui elements for uploaded files, the 'data-source' attribute was being created to store the upload path for the file which is used to save that info in the page doc. that attribute should be 'data-id' as that is what sortablejs looks for when sorting element data into arrays
This commit is contained in:
parent
9f6d1970ce
commit
4520c9b608
1 changed files with 3 additions and 3 deletions
|
@ -143,7 +143,7 @@ export default class FileManager {
|
|||
self.mm
|
||||
.filesUpload(theFile.type, upload, progress)
|
||||
.then(result => {
|
||||
item.setAttribute('data-source', result.filePath);
|
||||
item.setAttribute('data-id', result.filePath);
|
||||
let video = document.createElement('video');
|
||||
let source = document.createElement('source');
|
||||
source.src = f.target.result;
|
||||
|
@ -169,7 +169,7 @@ export default class FileManager {
|
|||
self.mm
|
||||
.filesUpload(theFile.type, upload, progress)
|
||||
.then(result => {
|
||||
item.setAttribute('data-source', result.filePath);
|
||||
item.setAttribute('data-id', result.filePath);
|
||||
let audio = document.createElement('audio');
|
||||
audio.setAttribute('controls', true);
|
||||
let source = document.createElement('source');
|
||||
|
@ -198,7 +198,7 @@ export default class FileManager {
|
|||
self.mm
|
||||
.filesUpload(theFile.type, upload, progress)
|
||||
.then(result => {
|
||||
item.setAttribute('data-source', result.filePath);
|
||||
item.setAttribute('data-id', result.filePath);
|
||||
let link = document.createElement('a');
|
||||
link.href = result.filePath;
|
||||
link.innerHTML = result.fileName;
|
||||
|
|
Loading…
Reference in a new issue