I have added some parameters. But in Laravel there is no value being passed here is my vue code of the component.
<dropzone id="fileDropZone" url="api/track/upload" options="{headers:{'Token':{{tokenVal}},'trackCategory':{{track.trackCategory}}}}"></dropzone>
/*Upload File */
public function uploadFile(Request $request){
$file = $request->file('file');
$file->store('tracks/multiv');
$trackCat= $request->trackCategory;
$token= $request->Token;
$fileName=$file->getFilename();
/*Return response */
return response()->json([
'filename' => $fileName,
'trackCategory' => $trackCat,
'token' => $token,
]);
}
Problem is the Headers are not even being passed in the Post.
Any ideas on this issue? Really Struggling with this one.
Hi @kyoukhana
So you'll need to do a couple of things
````
v-bind:use-custom-dropzone-options="true">
````
Hope that helps
Shouldn't options be like this
v-bind:dropzone-options="{{options}}"
@kyoukhana when passing down props using v:bind there is no need to use the {{ }} syntax, take a look at the vue doco for more info.
Most helpful comment
Hi @kyoukhana
So you'll need to do a couple of things
````
v-bind:dropzone-options="options"
v-bind:use-custom-dropzone-options="true">
````
Hope that helps