Commit 2a998bfc authored by 程卓's avatar 程卓

修改token前缀, 修改登录接口地址,住宅信息菜单的导出全部改access_token并不带前缀

parent 5751b123
......@@ -8,13 +8,13 @@ let BASE_URL = '', MOCK_URL='',
switch (process.env.NODE_ENV) {
case 'devol': // 本地线上部署环境下
// BASE_URL = 'http://search.omniview.pro/api'
BASE_URL = 'http://xuhui.hm.omniview.pro/api'
BASE_URL = 'http://xuhui.hm.omniview.pro/api/v2'
// BASE_URL = 'http://hm.omniview.pro/api'
break
case 'pudong-sit':
BASE_URL = 'http://xuhui.hm.omniview.pro/api',
BASE_URL = 'http://xuhui.hm.omniview.pro/api/v2',
// BASE_URL = 'http://211.136.105.193/apiv2' //浦东
FANGDI_URL = 'http://962121.fgj.sh.gov.cn/wyweb/shanghaiwuye'
......@@ -27,7 +27,7 @@ case 'pudong-prod':
break
case 'xuhui-sit':
BASE_URL = 'http://xuhui.hm.omniview.pro/api' // 徐汇
BASE_URL = 'http://xuhui.hm.omniview.pro/api/v2' // 徐汇
FANGDI_URL = 'http://962121.fgj.sh.gov.cn/wyweb/shanghaiwuye'
break
......@@ -39,7 +39,7 @@ case 'xuhui-prod':
break
case 'huangpu-sit':
BASE_URL = 'http://huangpu.hm.omniview.pro/api', // 徐汇
BASE_URL = 'http://huangpu.hm.omniview.pro/api/v2', // 徐汇
FANGDI_URL = 'http://962121.fgj.sh.gov.cn/wyweb/shanghaiwuye'
break
......@@ -53,7 +53,7 @@ case 'huangpu-prod':
default: // 默认环境下(开发环境)
// BASE_URL = 'http://31.0.161.39/apiv2'
// BASE_URL = 'http://211.136.105.193/apiv2'
BASE_URL = 'http://xuhui.hm.omniview.pro/api'
BASE_URL = 'http://xuhui.hm.omniview.pro/api/v2'
// BASE_URL = 'http://pudong.hm.omniview.pro/api'
// MOCK_URL = 'https://yapi.omniview.pro/mock/278'
......@@ -148,7 +148,7 @@ export default {
// 首页统计列表
GET_RESOURE_LIST: '/service-basicdatasync-ddd/resource/count',
// 首页统计列表
POST_LOGIN: '/service-user/public/login',
POST_LOGIN: '/public/login',
// 居委会列表
GET_NEI_LIST: '/service-basicdatasync-ddd/residentsCommittees',
......
......@@ -745,7 +745,7 @@ export default {
}
}
let token = this.$cookie.get('token') // 获取token 并拼接到 newUrl
newUrl += 'sectType=1&token=' + token
newUrl += 'sectType=1&access_token=' + token.split('bearer ')[1]
window.open (this.$api.BASE_URL+'/service-basicdatasync-ddd/export/'+ newUrl)
},
/**
......@@ -758,7 +758,7 @@ export default {
if(selectedKeys.length>0){
let sectId=selectedKeys.join(',')
// console.log('https://hm.omniview.pro/common/public/qrCodeGenerate?sectId='+sectId+'&token='+token)
window.open (this.$api.GET_EXPORT_EWM+'?sectId='+sectId+'&token='+token)
window.open (this.$api.GET_EXPORT_EWM+'?sectId='+sectId+'&access_token=' + token.split('bearer ')[1] )
}else{
let streetsId = formValue.c.streetId
if(streetsId){
......@@ -768,7 +768,7 @@ export default {
}
let stNameFrst_l = formValue.stNameFrst_l?formValue.stNameFrst_l:''
// console.log(this.$api.GET_EXPORT_EWM+'?streetId='+streetsId+'&stNameFrst_l='+stNameFrst_l+'&token='+token)
window.open (this.$api.GET_EXPORT_EWM+'?streetId='+streetsId+'&stNameFrst_l='+stNameFrst_l+'&token='+token)
window.open (this.$api.GET_EXPORT_EWM+'?streetId='+streetsId+'&stNameFrst_l='+stNameFrst_l+'&access_token=' + token.split('bearer ')[1])
}
},
changeLevel(val) {
......
......@@ -281,7 +281,7 @@ export default {
}
}
let token = this.$cookie.get('token') // 获取token 并拼接到 newUrl
newUrl += 'sectType=1&token=' + token
newUrl += 'sectType=1&access_token=' + token.split('bearer ')[1]
window.open (this.$api.BASE_URL+'/service-basicdatasync-ddd/export/'+ newUrl)
},
},
......
......@@ -355,7 +355,7 @@ export default {
}
}
let token = this.$cookie.get('token') // 获取token 并拼接到 newUrl
newUrl += 'sectType=1&token=' + token
newUrl += 'sectType=1&access_token=' + token.split('bearer ')[1]
window.open (this.$api.BASE_URL+'/service-basicdatasync-ddd/export/'+ newUrl)
},
},
......
......@@ -295,7 +295,7 @@ export default {
}
}
let token = this.$cookie.get('token') // 获取token 并拼接到 newUrl
newUrl += 'sectType=1&token=' + token
newUrl += 'sectType=1&access_token=' + token.split('bearer ')[1]
window.open (this.$api.BASE_URL+'/service-basicdatasync-ddd/export/'+ newUrl)
},
},
......
......@@ -260,7 +260,7 @@ export default {
}
}
let token = this.$cookie.get('token') // 获取token 并拼接到 newUrl
newUrl += 'sectType=1&token=' + token
newUrl += 'sectType=1&access_token=' + token.split('bearer ')[1]
window.open (this.$api.BASE_URL+'/service-basicdatasync-ddd/export/'+ newUrl)
},
},
......
......@@ -321,7 +321,7 @@ export default {
}
}
const token = this.$cookie.get('token') // 获取token 并拼接到 newUrl
newUrl += '&token=' + token
newUrl += '&access_token=' + token.split('bearer ')[1]
window.open (this.$api.BASE_URL+'/service-basicdatasync-ddd/export/'+ newUrl)
},
},
......
......@@ -327,7 +327,7 @@ export default {
}
}
const token = this.$cookie.get('token') // 获取token 并拼接到 newUrl
newUrl += '&token=' + token
newUrl += '&access_token=' + token.split('bearer ')[1]
window.open (this.$api.BASE_URL+'/service-basicdatasync-ddd/export/'+ newUrl)
},
toBul(record){ //到非居门牌幢列表
......
......@@ -431,7 +431,7 @@ export default {
}
}
let token = this.$cookie.get('token') // 获取token 并拼接到 newUrl
newUrl += 'sectType=1&token=' + token
newUrl += 'sectType=1&access_token=' + token.split('bearer ')[1]
window.open (this.$api.BASE_URL+'/service-basicdatasync-ddd/export/'+ newUrl)
},
},
......
......@@ -83,7 +83,7 @@ export default {
if (res.code == 200) {
res.token = this.$com.confirm(res, 'data.content', [])
// console.log(res.token)
this.$cookie.set('token', res.token.access_token)
this.$cookie.set('token', 'bearer ' + res.token.access_token)
this.$cookie.set('userName', res.name) // 存储当前账号的用户名
this.$router.push({
path: '/portal-home'
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment