<dropzone
id="flightEditUploader"
ref="flightFilesUpload"
:url="asset_upload_url"
:preview-template="template"
:autoProcessQueue="true"
:useFontAwesome="true"
:maxFileSizeInMB="500"
v-on:vdropzone-success="showSuccess"
v-on:vdropzone-removed-file="removeAssetFromFlight">
</dropzone>
This is on modal that when i hit close triggers something like this.$modal.close('modal')
Everytime i hit close i see removeAssetFromFlight triggering removing all assets from my object.
I think this is due to this.$modal.close('modal') triggers the destroy event of Vue on vue2-dropzone, which call the default destroy event of dropzonejs that removes all files
beforeDestroy () {
this.dropzone.destroy();
}
In version 3 I will include a prop that lets people set whether the dropzone will be destroyed or not when the component is removed.
good afternoon, is there a way to stop this event?
Thank you
Any updates on this?
Hi,
For those who are looking for this, you can add the prop destroyDropzone to avoid the call of destroy :
<vue-dropzone :destroy-dropzone="false" ...>
Most helpful comment
In version 3 I will include a prop that lets people set whether the dropzone will be destroyed or not when the component is removed.