Commit e5586523 by zhangxw

跳转趋势分析修改

1 parent 4b8177ef
......@@ -11,7 +11,7 @@
* 3生产环境
* 4预发布
*/
let index = 3
let index = 2
const accountInfo = wx.getAccountInfoSync()
const systemInfo = wx.getSystemInfoSync()
......
import { env } from '~/config'
import { env, envIndex } from '~/config'
export default {
data: {
menu: [
......@@ -14,7 +14,7 @@ export default {
},
{
name: '趋势分析',
url: 'http://baidu.com',
url: 'dj-car-revenue-analysis',
isH5: true
},
{
......@@ -58,20 +58,46 @@ export default {
})
} else {
if (item.isH5) {
let userInfo = wx.$util.getUserInfo()
let queryParmas = userInfo?.isSuper ? 'isAmin=true' : `isAdmin=false&yqMerchantId=${userInfo?.merchantId}`
const systemInfo = wx.getSystemInfoSync()
let jumpLocation = ''
switch (env) {
case 'develop':
jumpLocation = ''
break
case 'trial':
jumpLocation = ''
break
case 'release':
jumpLocation = ''
break
default:
jumpLocation = ''
break
if (systemInfo.platform != 'devtools') { // 非开发工具本地
switch (env) {
case 'develop': // 开发环境
jumpLocation = `http://192.168.0.39:8962/${item.url}/#/?${queryParmas}`
break
case 'trial': // 测试环境
jumpLocation = `https://dj.test.glsx.com.cn/${item.url}/#/?${queryParmas}`
break
case 'preRelease': // 预发布环境
jumpLocation = ''
break
case 'release': // 线上环境
jumpLocation = `https://dj.glsx.com.cn/${item.url}/#/?${queryParmas}`
break
default:
jumpLocation = `https://dj.glsx.com.cn/${item.url}/#/?${queryParmas}`
break
}
} else {
switch(envIndex) {
case 1: // 开发
jumpLocation = `http://192.168.0.39:8962/${item.url}/#/?${queryParmas}`
break
case 2: // 测试
jumpLocation = `https://dj.test.glsx.com.cn/${item.url}/#/?${queryParmas}`
break
case 3: // 线上
jumpLocation = `https://dj.glsx.com.cn/${item.url}/#/?${queryParmas}`
break
case 4: // 预发布
jumpLocation = ``
break
default:
jumpLocation = `https://dj.glsx.com.cn/${item.url}/#/?${queryParmas}`
break
}
}
wx.$router.jumpH5(jumpLocation)
} else {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!