|
@@ -1,8 +1,8 @@
|
|
|
import axios from 'axios'
|
|
import axios from 'axios'
|
|
|
-import { MessageBox, Message } from 'element-ui'
|
|
|
|
|
|
|
+import {MessageBox, Message} from 'element-ui'
|
|
|
import store from '@/store'
|
|
import store from '@/store'
|
|
|
-import { getToken } from '@/utils/auth'
|
|
|
|
|
-import { aesEncrypt_HmacSha256 } from './encryption/utils.js'
|
|
|
|
|
|
|
+import {getToken} from '@/utils/auth'
|
|
|
|
|
+import {aesEncrypt_HmacSha256} from './encryption/utils.js'
|
|
|
import * as queryString from 'query-string'
|
|
import * as queryString from 'query-string'
|
|
|
import moment from 'moment'
|
|
import moment from 'moment'
|
|
|
|
|
|
|
@@ -43,6 +43,10 @@ service.interceptors.request.use(
|
|
|
paramsObject = Object.assign({}, config.params)
|
|
paramsObject = Object.assign({}, config.params)
|
|
|
} else if (config.method === 'post' || config.method === 'put') {
|
|
} else if (config.method === 'post' || config.method === 'put') {
|
|
|
paramsObject = Object.assign({}, config.data)
|
|
paramsObject = Object.assign({}, config.data)
|
|
|
|
|
+ JSONToString(paramsObject)
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ function JSONToString(paramsObject) {
|
|
|
Object.keys(paramsObject).forEach(key => {
|
|
Object.keys(paramsObject).forEach(key => {
|
|
|
var item = paramsObject[key]
|
|
var item = paramsObject[key]
|
|
|
if (item === null || item === undefined) {
|
|
if (item === null || item === undefined) {
|