This commit is contained in:
zoujiandong
2025-09-01 16:25:46 +08:00
parent 7270482bd9
commit 82e0a5c10d
14 changed files with 3089 additions and 464 deletions
+5 -7
View File
@@ -54,6 +54,7 @@ export const request = (url, data = {}, method = 'post', loading = false, conten
version: '4.0.0',
user_uuid:userInfo.uuid,
client_type: 'A', //client_type,
timestamp:new Date().getTime()
}
postData={
...data,
@@ -65,16 +66,13 @@ export const request = (url, data = {}, method = 'post', loading = false, conten
if(token){
header['Authorization']='Bearer ' +token;
let userInfo= uni.getStorageSync('userInfo')
defaultData = {
defaultData = {
version: '4.0.0',
user_uuid:userInfo.uuid,
client_type: 'A', //client_type,
timestamp:new Date().getTime()
}
defaultData = {
version: '4.0.0',
user_uuid:userInfo.uuid,
client_type: 'A', //client_type,
}
postData={
...data,
...defaultData
@@ -87,7 +85,7 @@ export const request = (url, data = {}, method = 'post', loading = false, conten
return new Promise(function(e, n) {
let timestamp = Date.now();
uni.request({
data: {...data,...defaultData},
data: postData,
url: url.indexOf('http') != -1 ? url : encodeURI(BASE_URL + url),
method: method,
sslVerify: false,