From 0111e60f1d07075c31769091423b7d796423ab86 Mon Sep 17 00:00:00 2001 From: aonomike Date: Wed, 29 May 2019 16:09:34 +0300 Subject: [PATCH] Resolve Upload image rerender and double submit - Make Upload component re-render on failed upload - Resolve double submit of uploaded to the backend when uploading with drag and drop Co-authored-by: @mattWr18 Co-authored-by: @tirrok --- webapp/components/Upload/index.vue | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/webapp/components/Upload/index.vue b/webapp/components/Upload/index.vue index 5fbcff524..e5f91347d 100644 --- a/webapp/components/Upload/index.vue +++ b/webapp/components/Upload/index.vue @@ -8,7 +8,6 @@ :include-styling="false" :style="backgroundImage" @vdropzone-thumbnail="thumbnail" - @vdropzone-drop="vddrop" @vdropzone-error="verror" /> @@ -28,7 +27,7 @@ export default { return { dropzoneOptions: { url: this.vddrop, - maxFilesize: 3.0, + maxFilesize: 5.0, previewTemplate: this.template(), dictDefaultMessage: '', }, @@ -98,8 +97,8 @@ export default { .catch(error => this.$toast.error(error.message)) }, verror(file, message) { - this.error = true if (file.status === 'error') { + this.error = true this.$toast.error(file.status, message) } },