diff options
author | Fatih Acet <acetfatih@gmail.com> | 2017-07-21 00:27:20 +0300 |
---|---|---|
committer | Fatih Acet <acetfatih@gmail.com> | 2017-07-21 22:35:26 +0300 |
commit | 6b80d13e402f6a96c87b9ac762968ea0645c4e39 (patch) | |
tree | 182bf0a383a8899d3d566cd0baac7acbe1bb7159 /app/assets/javascripts/dropzone_input.js | |
parent | cbdbd24617b906f5aeb8c2441f686440b1f35056 (diff) | |
download | gitlab-ce-6b80d13e402f6a96c87b9ac762968ea0645c4e39.tar.gz |
IssueNotesRefactor: Add dropzone required elements and fix dropdown selector.
Diffstat (limited to 'app/assets/javascripts/dropzone_input.js')
-rw-r--r-- | app/assets/javascripts/dropzone_input.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/assets/javascripts/dropzone_input.js b/app/assets/javascripts/dropzone_input.js index 9ebbb22e807..3ec4d9ba318 100644 --- a/app/assets/javascripts/dropzone_input.js +++ b/app/assets/javascripts/dropzone_input.js @@ -129,7 +129,7 @@ window.DropzoneInput = (function() { // removeAllFiles(true) stops uploading files (if any) // and remove them from dropzone files queue. $cancelButton.on('click', (e) => { - const target = e.target.closest('form').querySelector('.div-dropzone'); + const target = e.target.closest('.js-main-target-form').querySelector('.div-dropzone'); e.preventDefault(); e.stopPropagation(); @@ -141,7 +141,7 @@ window.DropzoneInput = (function() { // and add that files to the dropzone files queue again. // addFile() adds file to dropzone files queue and upload it. $retryLink.on('click', (e) => { - const dropzoneInstance = Dropzone.forElement(e.target.closest('form').querySelector('.div-dropzone')); + const dropzoneInstance = Dropzone.forElement(e.target.closest('.js-main-target-form').querySelector('.div-dropzone')); const failedFiles = dropzoneInstance.files; e.preventDefault(); |