|
|
@ -1,6 +1,7 @@ |
|
|
|
import Axios from 'axios' |
|
|
|
import Axios from 'axios' |
|
|
|
import VueCookies from 'vue-cookies' |
|
|
|
import VueCookies from 'vue-cookies' |
|
|
|
import router from "@/router"; |
|
|
|
import router from "@/router"; |
|
|
|
|
|
|
|
import {geetestbase} from "@/utils/base/utils"; |
|
|
|
|
|
|
|
|
|
|
|
const Base64 = require('js-base64').Base64; |
|
|
|
const Base64 = require('js-base64').Base64; |
|
|
|
Axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded'; |
|
|
|
Axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded'; |
|
|
@ -78,10 +79,7 @@ export function set_auth_token() { |
|
|
|
|
|
|
|
|
|
|
|
set_auth_token(); |
|
|
|
set_auth_token(); |
|
|
|
|
|
|
|
|
|
|
|
function ErrorMsg(error, load) { |
|
|
|
function ErrorMsg(error) { |
|
|
|
if (!load) { |
|
|
|
|
|
|
|
return |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
if (error && error.response) { |
|
|
|
if (error && error.response) { |
|
|
|
switch (error.response.status) { |
|
|
|
switch (error.response.status) { |
|
|
|
case 400: |
|
|
|
case 400: |
|
|
@ -132,59 +130,54 @@ function ErrorMsg(error, load) { |
|
|
|
router.push({name: 'FirLogin'}); |
|
|
|
router.push({name: 'FirLogin'}); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
if (error.message === 'Network Error') { |
|
|
|
if (error.message === 'Network Error') { |
|
|
|
alert('网络连接失败'); |
|
|
|
window.alert('网络连接失败'); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
alert(error) |
|
|
|
window.alert(error) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
function getData(methods, url, params = {}, callBack, load, isCode = false) { |
|
|
|
function responseMiddleware(data, callBack) { |
|
|
|
|
|
|
|
if (data.code === 999) { |
|
|
|
|
|
|
|
window.alert(data.detail) |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
callBack(data); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function getData(methods, url, params = {}, callBack) { |
|
|
|
|
|
|
|
|
|
|
|
if (methods === "DELETE") { |
|
|
|
if (methods === "DELETE") { |
|
|
|
Axios |
|
|
|
Axios |
|
|
|
.delete(url, {params: params, signal: controller.signal}) |
|
|
|
.delete(url, {params: params, signal: controller.signal}) |
|
|
|
.then(function (response) { |
|
|
|
.then(function (response) { |
|
|
|
if (isCode) { |
|
|
|
responseMiddleware(response.data, callBack); |
|
|
|
callBack(response.data); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
callBack(response.data.data); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
}) |
|
|
|
.catch(function (error) { |
|
|
|
.catch(function (error) { |
|
|
|
ErrorMsg(error, load); |
|
|
|
ErrorMsg(error); |
|
|
|
callBack({"code": -1}); |
|
|
|
// callBack({"code": -1});
|
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
} else if (methods === "PUT") { |
|
|
|
} else if (methods === "PUT") { |
|
|
|
Axios |
|
|
|
Axios |
|
|
|
.put(url, params, {signal: controller.signal}) |
|
|
|
.put(url, params, {signal: controller.signal}) |
|
|
|
.then(function (response) { |
|
|
|
.then(function (response) { |
|
|
|
if (isCode) { |
|
|
|
responseMiddleware(response.data, callBack); |
|
|
|
callBack(response.data); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
callBack(response.data.data); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
}) |
|
|
|
.catch(function (error) { |
|
|
|
.catch(function (error) { |
|
|
|
ErrorMsg(error, load); |
|
|
|
ErrorMsg(error); |
|
|
|
callBack({"code": -1}); |
|
|
|
// callBack({"code": -1});
|
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
} else if (methods === 'POST') { |
|
|
|
} else if (methods === 'POST') { |
|
|
|
Axios |
|
|
|
Axios |
|
|
|
.post(url, params, {signal: controller.signal}) |
|
|
|
.post(url, params, {signal: controller.signal}) |
|
|
|
.then(function (response) { |
|
|
|
.then(function (response) { |
|
|
|
if (isCode) { |
|
|
|
responseMiddleware(response.data, callBack); |
|
|
|
callBack(response.data); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
callBack(response.data.data); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}) |
|
|
|
}) |
|
|
|
.catch(function (error) { |
|
|
|
.catch(function (error) { |
|
|
|
ErrorMsg(error, load); |
|
|
|
ErrorMsg(error); |
|
|
|
callBack({"code": -1}); |
|
|
|
// callBack({"code": -1});
|
|
|
|
}); |
|
|
|
}); |
|
|
|
} else if (methods === 'FILE') { |
|
|
|
} else if (methods === 'FILE') { |
|
|
|
Axios |
|
|
|
Axios |
|
|
@ -193,39 +186,36 @@ function getData(methods, url, params = {}, callBack, load, isCode = false) { |
|
|
|
convertRes2Blob(response) |
|
|
|
convertRes2Blob(response) |
|
|
|
}) |
|
|
|
}) |
|
|
|
.catch(function (error) { |
|
|
|
.catch(function (error) { |
|
|
|
ErrorMsg(error, load); |
|
|
|
ErrorMsg(error); |
|
|
|
callBack({"code": -1}); |
|
|
|
// callBack({"code": -1});
|
|
|
|
}); |
|
|
|
}); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
Axios |
|
|
|
Axios |
|
|
|
.get(url, {params: params, signal: controller.signal}) |
|
|
|
.get(url, {params: params, signal: controller.signal}) |
|
|
|
.then(function (response) { |
|
|
|
.then(function (response) { |
|
|
|
callBack(response.data); |
|
|
|
responseMiddleware(response.data, callBack); |
|
|
|
}) |
|
|
|
}) |
|
|
|
.catch(function (error) { |
|
|
|
.catch(function (error) { |
|
|
|
ErrorMsg(error, load); |
|
|
|
ErrorMsg(error); |
|
|
|
callBack({"code": -1}); |
|
|
|
// callBack({"code": -1});
|
|
|
|
}); |
|
|
|
}); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户登录 */ |
|
|
|
/**用户登录 */ |
|
|
|
export function loginFun(callBack, params, load = true) { |
|
|
|
export function loginFun(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/login', |
|
|
|
USERSEVER + '/login', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**微信公众号关注登录 */ |
|
|
|
/**微信公众号关注登录 */ |
|
|
|
export function wxLoginFun(callBack, params, load = true) { |
|
|
|
export function wxLoginFun(callBack, params) { |
|
|
|
let g_url = 'third.wx.login'; |
|
|
|
let g_url = 'third.wx.login'; |
|
|
|
if (params.methods === 'POST') { |
|
|
|
if (params.methods === 'POST') { |
|
|
|
g_url = 'third.wx.sync' |
|
|
|
g_url = 'third.wx.sync' |
|
|
@ -236,239 +226,191 @@ export function wxLoginFun(callBack, params, load = true) { |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**微信公众号关注绑定 */ |
|
|
|
/**微信公众号关注绑定 */ |
|
|
|
export function wxBindFun(callBack, params, load = true) { |
|
|
|
export function wxBindFun(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/third.wx.bind', |
|
|
|
USERSEVER + '/third.wx.bind', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**微信web扫码授权 */ |
|
|
|
/**微信web扫码授权 */ |
|
|
|
export function wxWebScanFun(callBack, params, load = true) { |
|
|
|
export function wxWebScanFun(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/mp.web.sync', |
|
|
|
USERSEVER + '/mp.web.sync', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**获取验证token */ |
|
|
|
/**获取验证token */ |
|
|
|
export function getAuthTokenFun(callBack, params, load = true) { |
|
|
|
export function getAuthTokenFun(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/auth', |
|
|
|
USERSEVER + '/auth', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**获取信息修改token */ |
|
|
|
/**获取信息修改token */ |
|
|
|
export function getAuthcTokenFun(callBack, params, load = true) { |
|
|
|
export function getAuthcTokenFun(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/authc', |
|
|
|
USERSEVER + '/authc', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户注册 */ |
|
|
|
/**用户注册 */ |
|
|
|
export function registerFun(callBack, params, load = true) { |
|
|
|
export function registerFun(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/register', |
|
|
|
USERSEVER + '/register', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**用户退出 */ |
|
|
|
/**用户退出 */ |
|
|
|
export function logout(callBack, params, load = true) { |
|
|
|
export function logout(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
'DELETE', |
|
|
|
'DELETE', |
|
|
|
USERSEVER + '/logout', |
|
|
|
USERSEVER + '/logout', |
|
|
|
params, |
|
|
|
params, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**api token */ |
|
|
|
/**api token */ |
|
|
|
export function apitoken(callBack, params, load = true) { |
|
|
|
export function apitoken(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/token', |
|
|
|
USERSEVER + '/token', |
|
|
|
params, |
|
|
|
params, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户应用列表 */ |
|
|
|
/**用户应用列表 */ |
|
|
|
export function getapps(callBack, params, load = true) { |
|
|
|
export function getapps(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
'GET', |
|
|
|
'GET', |
|
|
|
USERSEVER + '/apps', |
|
|
|
USERSEVER + '/apps', |
|
|
|
params, |
|
|
|
params, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**app应用操作 */ |
|
|
|
/**app应用操作 */ |
|
|
|
export function apputils(callBack, params, load = true) { |
|
|
|
export function apputils(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/apps/' + params.app_id, |
|
|
|
USERSEVER + '/apps/' + params.app_id, |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**release应用操作 */ |
|
|
|
/**release应用操作 */ |
|
|
|
export function releaseapputils(callBack, params, load = true) { |
|
|
|
export function releaseapputils(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/appinfos/' + params.app_id + '/' + params.release_id, |
|
|
|
USERSEVER + '/appinfos/' + params.app_id + '/' + params.release_id, |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**应用下载token操作 */ |
|
|
|
/**应用下载token操作 */ |
|
|
|
export function appDownloadToken(callBack, params, load = true) { |
|
|
|
export function appDownloadToken(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/download_password/' + params.app_id, |
|
|
|
USERSEVER + '/download_password/' + params.app_id, |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**根据短链接获取应用信息 */ |
|
|
|
/**根据短链接获取应用信息 */ |
|
|
|
export function getShortAppinfo(callBack, params, load = true) { |
|
|
|
export function getShortAppinfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
'GET', |
|
|
|
'GET', |
|
|
|
USERSEVER + '/short/' + params.short, |
|
|
|
USERSEVER + '/short/' + params.short, |
|
|
|
params, |
|
|
|
params, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户app存储配置 */ |
|
|
|
/**用户app存储配置 */ |
|
|
|
export function getStorageinfo(callBack, params, load = true) { |
|
|
|
export function getStorageinfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/storage', |
|
|
|
USERSEVER + '/storage', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户app清理操作 */ |
|
|
|
/**用户app清理操作 */ |
|
|
|
export function cleanStorageData(callBack, params, load = true) { |
|
|
|
export function cleanStorageData(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/storage/clean', |
|
|
|
USERSEVER + '/storage/clean', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户个人信息 */ |
|
|
|
/**用户个人信息 */ |
|
|
|
export function userinfos(callBack, params, load = true) { |
|
|
|
export function userinfos(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/userinfo', |
|
|
|
USERSEVER + '/userinfo', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -490,33 +432,27 @@ export function getuploadurl(domain_name = null) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**分析应用并获取app上传token */ |
|
|
|
/**分析应用并获取app上传token */ |
|
|
|
export function analyseApps(callBack, params, load = true) { |
|
|
|
export function analyseApps(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/analyse', |
|
|
|
USERSEVER + '/analyse', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**获取下载的url */ |
|
|
|
/**获取下载的url */ |
|
|
|
export function getdownloadurl(callBack, params, load = true) { |
|
|
|
export function getdownloadurl(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
'GET', |
|
|
|
'GET', |
|
|
|
USERSEVER + '/install/' + params.app_id, |
|
|
|
USERSEVER + '/install/' + params.app_id, |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -549,360 +485,297 @@ export function uploadstorage(certinfo, file, successCallback, processCallback) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**获取文件上传token */ |
|
|
|
/**获取文件上传token */ |
|
|
|
export function uploadimgs(callBack, params, load = true) { |
|
|
|
export function uploadimgs(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/upload', |
|
|
|
USERSEVER + '/upload', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**获取充值价格信息 */ |
|
|
|
/**获取充值价格信息 */ |
|
|
|
export function get_package_prices(callBack, params, load = true) { |
|
|
|
export function get_package_prices(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
'GET', |
|
|
|
'GET', |
|
|
|
USERSEVER + '/package_prices', |
|
|
|
USERSEVER + '/package_prices', |
|
|
|
params, |
|
|
|
params, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户订单 */ |
|
|
|
/**用户订单 */ |
|
|
|
export function my_order(callBack, params, load = true) { |
|
|
|
export function my_order(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/orders', |
|
|
|
USERSEVER + '/orders', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户订单支付同步 */ |
|
|
|
/**用户订单支付同步 */ |
|
|
|
export function order_sync(callBack, params, load = true) { |
|
|
|
export function order_sync(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/orders.sync', |
|
|
|
USERSEVER + '/orders.sync', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**实名认证 */ |
|
|
|
/**实名认证 */ |
|
|
|
export function user_certification(callBack, params, load = true) { |
|
|
|
export function user_certification(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/certification', |
|
|
|
USERSEVER + '/certification', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户信息修改验证 */ |
|
|
|
/**用户信息修改验证 */ |
|
|
|
export function changeInfoFun(callBack, params, load = true) { |
|
|
|
export function changeInfoFun(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/change', |
|
|
|
USERSEVER + '/change', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户接收者验证 */ |
|
|
|
/**用户接收者验证 */ |
|
|
|
export function NotifyInfoFun(callBack, params, load = true) { |
|
|
|
export function NotifyInfoFun(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/notify/notify', |
|
|
|
USERSEVER + '/notify/notify', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**用户绑定域名*/ |
|
|
|
/**用户绑定域名*/ |
|
|
|
export function domainFun(callBack, params, load = true) { |
|
|
|
export function domainFun(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/cname_domain', |
|
|
|
USERSEVER + '/cname_domain', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**微信用户绑定 */ |
|
|
|
/**微信用户绑定 */ |
|
|
|
export function wxutils(callBack, params, load = true) { |
|
|
|
export function wxutils(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/twx/info', |
|
|
|
USERSEVER + '/twx/info', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**访问域名绑定 */ |
|
|
|
/**访问域名绑定 */ |
|
|
|
export function domaininfo(callBack, params, load = true) { |
|
|
|
export function domaininfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/domain_info', |
|
|
|
USERSEVER + '/domain_info', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**自定义广告 */ |
|
|
|
/**自定义广告 */ |
|
|
|
export function advertinfo(callBack, params, load = true) { |
|
|
|
export function advertinfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/advert', |
|
|
|
USERSEVER + '/advert', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**下载码大屏 */ |
|
|
|
/**下载码大屏 */ |
|
|
|
export function qrcodeinfo(callBack, params, load = true) { |
|
|
|
export function qrcodeinfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/qrcode', |
|
|
|
USERSEVER + '/qrcode', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**应用举报 */ |
|
|
|
/**应用举报 */ |
|
|
|
export function appReport(callBack, params, load = true) { |
|
|
|
export function appReport(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/report', |
|
|
|
USERSEVER + '/report', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**消息接收人配置 */ |
|
|
|
/**消息接收人配置 */ |
|
|
|
export function notifyReceiverInfo(callBack, params, load = true) { |
|
|
|
export function notifyReceiverInfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/notify/receiver', |
|
|
|
USERSEVER + '/notify/receiver', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**消息配置 */ |
|
|
|
/**消息配置 */ |
|
|
|
export function notifyConfigInfo(callBack, params, load = true) { |
|
|
|
export function notifyConfigInfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
USERSEVER + '/notify/config', |
|
|
|
USERSEVER + '/notify/config', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
export function geetest(self, uid, params, callback) { |
|
|
|
|
|
|
|
return geetestbase(loginFun, self, uid, params, callback, res => { |
|
|
|
|
|
|
|
self.$message.error(res.msg) |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** 超级签名************************************************相关api */ |
|
|
|
/** 超级签名************************************************相关api */ |
|
|
|
|
|
|
|
|
|
|
|
let SIGNSEVER = DOMAIN + '/api/v1/fir/xsign'; |
|
|
|
let SIGNSEVER = DOMAIN + '/api/v1/fir/xsign'; |
|
|
|
|
|
|
|
|
|
|
|
/** 超级签名--检测该账户是否可开启超级签名 */ |
|
|
|
/** 超级签名--检测该账户是否可开启超级签名 */ |
|
|
|
export function checkCanSign(callBack, params, load = false) { |
|
|
|
export function checkCanSign(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/cansign', |
|
|
|
SIGNSEVER + '/cansign', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** 苹果签名应用操作 */ |
|
|
|
/** 苹果签名应用操作 */ |
|
|
|
export function appSignInfo(callBack, params, load = true) { |
|
|
|
export function appSignInfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/signinfo/' + params.app_id, |
|
|
|
SIGNSEVER + '/signinfo/' + params.app_id, |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**签名账单 */ |
|
|
|
/**签名账单 */ |
|
|
|
export function DeviceBillInfo(callBack, params, load = true) { |
|
|
|
export function DeviceBillInfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/bill', |
|
|
|
SIGNSEVER + '/bill', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**设备流转账单 */ |
|
|
|
/**设备流转账单 */ |
|
|
|
export function DeviceTransferBillInfo(callBack, params, load = true) { |
|
|
|
export function DeviceTransferBillInfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/devicebill', |
|
|
|
SIGNSEVER + '/devicebill', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**签名下载排行 */ |
|
|
|
/**签名下载排行 */ |
|
|
|
export function DeviceRankInfo(callBack, params, load = true) { |
|
|
|
export function DeviceRankInfo(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/rank', |
|
|
|
SIGNSEVER + '/rank', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**开发绑定应用*/ |
|
|
|
/**开发绑定应用*/ |
|
|
|
export function developerBindAppFun(callBack, params, load = true) { |
|
|
|
export function developerBindAppFun(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/bind', |
|
|
|
SIGNSEVER + '/bind', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**超级签名 苹果开发者信息 */ |
|
|
|
/**超级签名 苹果开发者信息 */ |
|
|
|
export function iosdeveloper(callBack, params, load = true) { |
|
|
|
export function iosdeveloper(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/developer', |
|
|
|
SIGNSEVER + '/developer', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**超级签名 设备消耗信息 */ |
|
|
|
/**超级签名 设备消耗信息 */ |
|
|
|
export function iosdevices(callBack, params, load = true) { |
|
|
|
export function iosdevices(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/devices', |
|
|
|
SIGNSEVER + '/devices', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**超级签名 设备udid信息 */ |
|
|
|
/**超级签名 设备udid信息 */ |
|
|
|
export function iosdevicesudid(callBack, params, load = true) { |
|
|
|
export function iosdevicesudid(callBack, params) { |
|
|
|
// eslint-disable-next-line no-console
|
|
|
|
// eslint-disable-next-line no-console
|
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
@ -910,15 +783,12 @@ export function iosdevicesudid(callBack, params, load = true) { |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**超级签名 苹果开发设备udid信息 */ |
|
|
|
/**超级签名 苹果开发设备udid信息 */ |
|
|
|
export function iosudevices(callBack, params, load = true) { |
|
|
|
export function iosudevices(callBack, params) { |
|
|
|
// eslint-disable-next-line no-console
|
|
|
|
// eslint-disable-next-line no-console
|
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
@ -926,55 +796,43 @@ export function iosudevices(callBack, params, load = true) { |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**签名证书 */ |
|
|
|
/**签名证书 */ |
|
|
|
export function developercert(callBack, params, load = true) { |
|
|
|
export function developercert(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/cert', |
|
|
|
SIGNSEVER + '/cert', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**签名证书 */ |
|
|
|
/**签名证书 */ |
|
|
|
export function signoperatemessage(callBack, params, load = true) { |
|
|
|
export function signoperatemessage(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/message', |
|
|
|
SIGNSEVER + '/message', |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/**获取签名任务状态 */ |
|
|
|
/**获取签名任务状态 */ |
|
|
|
export function gettask(callBack, params, load = true) { |
|
|
|
export function gettask(callBack, params) { |
|
|
|
getData( |
|
|
|
getData( |
|
|
|
params.methods, |
|
|
|
params.methods, |
|
|
|
SIGNSEVER + '/task/' + params.short, |
|
|
|
SIGNSEVER + '/task/' + params.short, |
|
|
|
params.data, |
|
|
|
params.data, |
|
|
|
data => { |
|
|
|
data => { |
|
|
|
callBack(data); |
|
|
|
callBack(data); |
|
|
|
}, |
|
|
|
} |
|
|
|
load, |
|
|
|
|
|
|
|
true, |
|
|
|
|
|
|
|
true |
|
|
|
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|