Skip to content

Commit

Permalink
fix: the data and headers parameter transmission format is wrong
Browse files Browse the repository at this point in the history
  • Loading branch information
qiqingfu committed Nov 19, 2020
1 parent d4f8561 commit f363929
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions packages/upload/src/upload.vue
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@ export default {
setup(props) {
const { limit, fileList, onExceed, multiple, autoUpload } = toRefs(props)
const { headers, withCredentials, data, name, action } = toRefs(props)
// eslint-disable-next-line vue/no-setup-props-destructure
const {
onStart,
Expand Down Expand Up @@ -173,12 +172,12 @@ export default {
const post = (rawFile) => {
const { uid } = rawFile
const options = {
headers,
withCredentials: withCredentials.value,
headers: props.headers,
withCredentials: props.withCredentials,
file: rawFile,
data,
filename: name.value,
action: action.value,
data: props.data,
filename: props.name,
action: props.action,
onProgress: (e) => {
onProgress(e, rawFile)
},
Expand Down

0 comments on commit f363929

Please sign in to comment.