Compare commits

..

No commits in common. '3f24bf3f629f04c8864ae47f41a9e5f7c3d0d671' and '8b948056bf5ef67cc03d7757a4fa894245f43d53' have entirely different histories.

  1. 5
      packageOrders/pages/orderList/orderList.vue
  2. 44
      utils/request.js

@ -232,10 +232,7 @@
'1689184331812888576', '1689184331812888576',
'1689185023261741056', '1689185023261741056',
'1782596400854310912', '1782596400854310912',
'1661994395596533760', '1661994395596533760'
'1825776105145946112',
'1802612281797746688',
'1508364963431362560'
] ]
var exportFields = exportList.filter((item) => { var exportFields = exportList.filter((item) => {
return item == uni.getStorageSync('oilSitePriceId'); return item == uni.getStorageSync('oilSitePriceId');

@ -7,9 +7,10 @@ import utils from '@/utils/encode'
//42 洛超 /29 孙志华 /40 阿浩 //42 洛超 /29 孙志华 /40 阿浩
// 测试日日顺时需要连阿浩 // 测试日日顺时需要连阿浩
const testUrl = 'http://192.168.110.77:38080' const testUrl = 'http://192.168.0.26:38080'
// const productionUrl = 'https://www.51xingka.net/oilApp' // 生产,加密 old // const productionUrl = 'https://www.51xingka.net/oilApp' // 生产,加密 old
// const productionUrl = 'https://www.xingoil.com/adminapi' // 生产,加密 new // const productionUrl = 'https://www.xingoil.com/adminapi' // 生产,加密 new
// const productionUrl = 'https://www.xingoil.com/adminapi' // 生产,加密 new
const productionUrl = 'http://uat.xingoil.com/adminapi' const productionUrl = 'http://uat.xingoil.com/adminapi'
// const env = process.env.NODE_ENV // 环境 // const env = process.env.NODE_ENV // 环境
const service = axios.create({ const service = axios.create({
@ -48,7 +49,7 @@ service.interceptors.request.use(
if (env === 'production') { if (env === 'production') {
// 生产环境,加密,不输出任何东西 // 生产环境,加密,不输出任何东西
// 设置jsessionid和token // 设置jsessionid和token
// console.log('这里是生产') console.log('这里是生产')
const JSESSIONID = utils.uuid() const JSESSIONID = utils.uuid()
config.headers['JSESSIONID'] = JSESSIONID config.headers['JSESSIONID'] = JSESSIONID
config.headers['token'] = utils.md5Salt(JSESSIONID) config.headers['token'] = utils.md5Salt(JSESSIONID)
@ -99,13 +100,13 @@ service.interceptors.response.use(
// console.log('生产环境 请求路径', response.config.url, '解密为', res.data) // console.log('生产环境 请求路径', response.config.url, '解密为', res.data)
} }
} else { } else {
// console.log('请求路径', response.config.url, '返回结果未加密', res) console.log('请求路径', response.config.url, '返回结果未加密', res)
// console.log('-------------------------------------------') console.log('-------------------------------------------')
} }
uni.hideLoading() uni.hideLoading()
if (res.code != 20000) { if (res.code != 20000) {
// console.log('这里是登录报错处',res) console.log('这里是登录报错处',res)
if(response.config.url.indexOf('/oil-user/oilCustomerChannelRelation/getByPhone/') != -1){ if(response.config.url.indexOf('/oil-user/oilCustomerChannelRelation/getByPhone/') != -1){
// uni.hideToast() // uni.hideToast()
}else{ }else{
@ -124,11 +125,23 @@ service.interceptors.response.use(
success: function(res) { success: function(res) {
if (res.confirm) { if (res.confirm) {
uni.reLaunch({ uni.reLaunch({
url: '/pages/login/boforeLogin/boforeLogin' url: '/pages/login/boforeLogin/boforeLogin',
success: () => {
console.log('跳转成功')
},
fail: (err) => {
console.log(err)
}
}) })
} else if (res.cancel) { } else if (res.cancel) {
uni.reLaunch({ uni.reLaunch({
url: '/pages/login/boforeLogin/boforeLogin?type=1' url: '/pages/login/boforeLogin/boforeLogin?type=1',
success: () => {
console.log('跳转成功')
},
fail: (err) => {
console.log(err)
}
}) })
} }
} }
@ -141,7 +154,13 @@ service.interceptors.response.use(
icon: "none" icon: "none"
}) })
uni.reLaunch({ uni.reLaunch({
url: '/pages/login/boforeLogin/boforeLogin' url: '/pages/login/boforeLogin/boforeLogin',
success: () => {
console.log('跳转成功')
},
fail: (err) => {
console.log(err)
}
}) })
} }
if(res.code == 42077){ if(res.code == 42077){
@ -150,7 +169,13 @@ service.interceptors.response.use(
icon: "none" icon: "none"
}) })
uni.reLaunch({ uni.reLaunch({
url: '/pages/login/boforeLogin/boforeLogin' url: '/pages/login/boforeLogin/boforeLogin',
success: () => {
console.log('跳转成功')
},
fail: (err) => {
console.log(err)
}
}) })
} }
@ -176,6 +201,7 @@ service.interceptors.response.use(
uni.hideLoading() uni.hideLoading()
uni.getNetworkType({ uni.getNetworkType({
success: function(res) { success: function(res) {
console.log(res.networkType);
if (res.networkType === 'none') { if (res.networkType === 'none') {
uni.showToast({ uni.showToast({
title: '没有网啦!', title: '没有网啦!',

Loading…
Cancel
Save