Commit 4db244ba authored by 邓晓峰's avatar 邓晓峰

fix: 修复client标识

parent 329d9dc8
Pipeline #38811 passed with stages
in 13 minutes 7 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 = 'https://panda-water.com'; 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: {
......
...@@ -132,14 +132,14 @@ const initGlobalConfig = () => { ...@@ -132,14 +132,14 @@ const initGlobalConfig = () => {
if (!data.client) { if (!data.client) {
data.client = params.getParams('client') || 'city'; data.client = params.getParams('client') || 'city';
} }
Cookies.set('city', data.client); Cookies.set('city', Cookies.get('city'));
store.dispatch( store.dispatch(
actionCreators.getConfig( actionCreators.getConfig(
Object.assign({}, window.globalConfig, data), Object.assign({}, window.globalConfig, data),
), ),
); );
Cookies.set('city', params.getParams('client')) //Cookies.set('city', params.getParams('client'))
if (data.loginTemplate === '新春 - 智联.html') { if (data.loginTemplate === '新春 - 智联.html') {
updateTheme('#ff9600'); updateTheme('#ff9600');
......
...@@ -102,9 +102,9 @@ const appReducer = (state = initialState, action) => { ...@@ -102,9 +102,9 @@ const appReducer = (state = initialState, action) => {
// eslint-disable-next-line no-case-declarations // eslint-disable-next-line no-case-declarations
const { homepage } = window.globalConfig; const { homepage } = window.globalConfig;
const modulePkg = {}; const modulePkg = {};
window.globalConfig.products.map(item => { window.globalConfig && window.globalConfig.products && Array.isArray(window.globalConfig.products) && window.globalConfig.products.map(item => {
modulePkg[item.PackageName] = item; modulePkg[item.PackageName] = item;
}) });
const generMenu = generRoutes(config.widgets || [], null, 0, modulePkg); const generMenu = generRoutes(config.widgets || [], null, 0, modulePkg);
const flatMenu = generFlatRoutes(generMenu || [], null, null, modulePkg); const flatMenu = generFlatRoutes(generMenu || [], null, null, modulePkg);
......
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