upload iview upload components
problem description
there is no problem with other interfaces. Cross-domain header has been set up on the server side and other ajax request interfaces are running normally, but the upload of upload component files will prompt cross-domain problems
related code error prompt
Access to XMLHttpRequest at" http://149.60.61.206/api/v1/u..." from origin" http://localhost:8081" has been blocked by CORS policy: Response to preflight request doesn"t pass access control check: Redirect is not allowed for a preflight request.
Code
<Upload
type="drag"
name="imgs"
:action="uploadUri"
:on-success="handleUploadSuccess"
:with-credentials="true"
:headers=headers
:format="["jpg","jpeg","png","gif"]"
>
<div style="padding: 20px 0">
<Icon type="ios-cloud-upload" size="52" style="color: -sharp3399ff"></Icon>
</div>
</Upload>
uploadUri:this.$baseUri+"api/v1/uploader/imageUpload/",
headers:{"Access-Control-Allow-Origin":"*"},