Commit 87a06f9e authored by 邓晓峰's avatar 邓晓峰

fix: 修复https请求安全降级问题

parent 3a3a955b
Pipeline #39218 passed with stages
in 13 minutes 52 seconds
/* eslint-disable */ /* eslint-disable */
// const proxyURL = process.env.NODE_ENV !== 'production' ? 'http://192.168.10.150:8777' : window.location.origin; // const proxyURL = process.env.NODE_ENV !== 'production' ? 'http://192.168.10.150:8777' : window.location.origin;
const proxyURL = 'http://192.168.10.150:8014'; const proxyURL = 'https://mis.panda-water.cn';
module.exports = { module.exports = {
assetsRoot: process.env.NODE_ENV !== 'production' ? proxyURL : './', assetsRoot: process.env.NODE_ENV !== 'production' ? proxyURL : './',
dev: { dev: {
......
...@@ -125,15 +125,16 @@ const initGlobalConfig = () => { ...@@ -125,15 +125,16 @@ const initGlobalConfig = () => {
// eslint-disable-next-line react-hooks/rules-of-hooks // eslint-disable-next-line react-hooks/rules-of-hooks
appService appService
.queryConfig({ .queryConfig({
client: params.getParams('client') || 'city', client: Cookies.get('city') || params.getParams('client'),
}) })
.then(res => { .then(res => {
if (res) { if (res) {
const data = res; const data = res;
if (!data.client) { if (!data.client) {
data.client = params.getParams('client') || 'city'; data.client = params.getParams('client') || 'city';
} }
Cookies.set('city', Cookies.get('city')); Cookies.set('city', data.client);
store.dispatch( store.dispatch(
actionCreators.getConfig( actionCreators.getConfig(
Object.assign({}, window.globalConfig, data), Object.assign({}, window.globalConfig, data),
......
...@@ -6,6 +6,7 @@ import InfoLogin from './template/infoLogin'; ...@@ -6,6 +6,7 @@ import InfoLogin from './template/infoLogin';
import Yulin from './template/yulin'; import Yulin from './template/yulin';
/* eslint-disable */ /* eslint-disable */
export default () => { export default () => {
debugger
const loginTemplate = window.globalConfig && window.globalConfig.loginTemplate; const loginTemplate = window.globalConfig && window.globalConfig.loginTemplate;
switch(loginTemplate) { switch(loginTemplate) {
case '新春 - 智联.html': case '新春 - 智联.html':
......
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