26 lines
630 B
JavaScript
26 lines
630 B
JavaScript
import {uniRequest} from "@/http/main";
|
|
|
|
export default uniRequest.created({
|
|
baseUrl: 'http://172.16.100.93:9052',
|
|
// baseUrl: 'http://192.168.88.122:9021',
|
|
header: {
|
|
Authorization: uni.getStorageSync('token') ?? ''
|
|
},
|
|
interceptor: {
|
|
request(config){
|
|
uni.showLoading({
|
|
title: '加载中...',
|
|
mask: true
|
|
})
|
|
setTimeout(()=>{
|
|
uni.hideLoading()
|
|
},5000)
|
|
return config
|
|
},
|
|
response(response) {
|
|
uni.hideLoading()
|
|
return response.data
|
|
}
|
|
}
|
|
})
|