fix dataTable other fetch params

This commit is contained in:
zuiidea
2017-03-20 10:58:26 +08:00
parent 19d5c3c4bd
commit d8ca570348
2 changed files with 5 additions and 3 deletions
+3 -2
View File
@@ -7,11 +7,12 @@ export default function request (url, options) {
format: 'json',
})
}
const { method = 'get' } = options
return Ajax.ajax({
url,
method: options.method || 'get',
method,
data: options.data || {},
processData: options.method === 'get',
processData: method === 'get',
dataType: 'JSON',
}).done((data) => {
return data