增加湖南公安项目的配置
This commit is contained in:
@@ -17,7 +17,7 @@ instance.interceptors.request.use(config => {
|
|||||||
config.url = config.url.replace(/(app|auth|admin)\//, "api/")
|
config.url = config.url.replace(/(app|auth|admin)\//, "api/")
|
||||||
} else if (/\/grid\//.test(location.pathname)) {
|
} else if (/\/grid\//.test(location.pathname)) {
|
||||||
config.baseURL = '/wangge'
|
config.baseURL = '/wangge'
|
||||||
} else if (/\/project\/police\//.test(location.pathname)) {
|
} else if (/\/project\/police\//.test(location.pathname)||config.module=='hnjc') {
|
||||||
config.baseURL = '/hnjc'
|
config.baseURL = '/hnjc'
|
||||||
config.url = config.url.replace(/(app|auth|admin)\//, "api/")
|
config.url = config.url.replace(/(app|auth|admin)\//, "api/")
|
||||||
} else if (sessionStorage.getItem("prj") == "saas") {
|
} else if (sessionStorage.getItem("prj") == "saas") {
|
||||||
|
|||||||
@@ -50,7 +50,10 @@ export default {
|
|||||||
handleLogin() {
|
handleLogin() {
|
||||||
this.$refs.loginForm.validate(v => {
|
this.$refs.loginForm.validate(v => {
|
||||||
if (v) {
|
if (v) {
|
||||||
let {name: module} = this.currentApp
|
let {name: module,libPath} = this.currentApp
|
||||||
|
if(/\/project\/police\//.test(libPath)){
|
||||||
|
module = 'hnjc'
|
||||||
|
}
|
||||||
this.getToken({...this.form, module, corpId: 'wpytYEDgAAcpXjmlYkYwKO60JDGDWrXg'}).then(() => {
|
this.getToken({...this.form, module, corpId: 'wpytYEDgAAcpXjmlYkYwKO60JDGDWrXg'}).then(() => {
|
||||||
this.target ? uni.reLaunch({url: this.target}) : uni.navigateBack({})
|
this.target ? uni.reLaunch({url: this.target}) : uni.navigateBack({})
|
||||||
}).catch(() => 0)
|
}).catch(() => 0)
|
||||||
|
|||||||
Reference in New Issue
Block a user