From 487ec6cefb30488fe9a1080e18550a3e6a7ba210 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8F=B2=E5=85=B8=E5=8D=93?= Date: Wed, 9 Oct 2024 15:48:24 +0800 Subject: [PATCH] =?UTF-8?q?flat:=20=E4=BF=AE=E6=94=B9=E7=99=BB=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/page/login/userlogin.vue | 52 ++++++++++++++++++------------------ vue.config.js | 2 +- 2 files changed, 27 insertions(+), 27 deletions(-) diff --git a/src/page/login/userlogin.vue b/src/page/login/userlogin.vue index 1c2d8a4..ee651f7 100644 --- a/src/page/login/userlogin.vue +++ b/src/page/login/userlogin.vue @@ -56,21 +56,21 @@ import topLang from "@/page/index/top/top-lang"; // import { info } from "@/api/system/tenant"; import {getCaptcha} from "@/api/user"; -console.log('是否跳转', /(^http)(s?):\/\/([a-z0-9].+)\/manage(\/)?$/i.test(location.href), location.href) -if (/(^http)(s?):\/\/([a-z0-9].+)\/manage(\/)?$/i.test(location.href)) { - window.location.href = process.env.VUE_APP_LOGIN_NEXT -} -if (/(\/login\?)(.*)/ig.test(location.href)) { - const obj = {} - const query = location.href.split('?')[1].replace(/\?/, '').split('&') - query.forEach((item) => { - const a = item.split('='); - obj[a[0]] = a[1] - }) - window.sessionStorage.setItem('query_session', JSON.stringify(obj)) -} else { - window.sessionStorage.removeItem('query_session') -} +// console.log('是否跳转', /(^http)(s?):\/\/([a-z0-9].+)\/manage(\/)?$/i.test(location.href), location.href) +// if (/(^http)(s?):\/\/([a-z0-9].+)\/manage(\/)?$/i.test(location.href)) { +// window.location.href = process.env.VUE_APP_LOGIN_NEXT +// } +// if (/(\/login\?)(.*)/ig.test(location.href)) { +// const obj = {} +// const query = location.href.split('?')[1].replace(/\?/, '').split('&') +// query.forEach((item) => { +// const a = item.split('='); +// obj[a[0]] = a[1] +// }) +// window.sessionStorage.setItem('query_session', JSON.stringify(obj)) +// } else { +// window.sessionStorage.removeItem('query_session') +// } export default { name: "login", @@ -115,17 +115,17 @@ export default { watch: {}, created() { // this.getTenant(); - const {ticket} = JSON.parse(window.sessionStorage.getItem('query_session') || "{}") - window.sessionStorage.removeItem('query_session') - console.log(ticket) - if (ticket) { - this.proLoading = true - this.ticket = ticket - this.handleLogin() - } else { - console.log('刷新1') - this.refreshCode(); - } + // const {ticket} = JSON.parse(window.sessionStorage.getItem('query_session') || "{}") + // window.sessionStorage.removeItem('query_session') + // if (ticket) { + // this.proLoading = true + // this.ticket = ticket + // this.handleLogin() + // } else { + // console.log('刷新1') + // this.refreshCode(); + // } + this.refreshCode(); }, mounted() { }, diff --git a/vue.config.js b/vue.config.js index 74507a2..367db0e 100644 --- a/vue.config.js +++ b/vue.config.js @@ -24,7 +24,7 @@ module.exports = { port: 1888, proxy: { "/api": { - target: 'http://10.165.0.173:8000', + target: 'http://39.98.184.58:8000', ws: true, changeOrigin: true, pathRewrite: {