mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
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
This commit is contained in:
parent
7def0b4c20
commit
0111e60f1d
@ -8,7 +8,6 @@
|
||||
:include-styling="false"
|
||||
:style="backgroundImage"
|
||||
@vdropzone-thumbnail="thumbnail"
|
||||
@vdropzone-drop="vddrop"
|
||||
@vdropzone-error="verror"
|
||||
/>
|
||||
</div>
|
||||
@ -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)
|
||||
}
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user