1
This commit is contained in:
parent
bda1e10a92
commit
c5828259f1
@ -90,7 +90,12 @@ const Sider = (props) => {
|
|||||||
/** 回到首页 */
|
/** 回到首页 */
|
||||||
const navToHome = () => {
|
const navToHome = () => {
|
||||||
setActiveMenu(null);
|
setActiveMenu(null);
|
||||||
props.history.push({ pathname: "/home" });
|
if (localStorage.getItem("webOrgId") == '00300000-0000-0000-0000-000000000000' ) {
|
||||||
|
props.history.replace('/grouphome')
|
||||||
|
}else{
|
||||||
|
props.history.replace('/home')
|
||||||
|
}
|
||||||
|
// props.history.push({ pathname: "/home" });
|
||||||
};
|
};
|
||||||
const navToLarge = () => {
|
const navToLarge = () => {
|
||||||
setActiveMenu('largeScreen');
|
setActiveMenu('largeScreen');
|
||||||
|
|||||||
@ -26,7 +26,13 @@ export default {
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
dispatch(routerRedux.push('/home'))
|
if (localStorage.getItem("webOrgId") == '00300000-0000-0000-0000-000000000000') {
|
||||||
|
dispatch(routerRedux.replace('/grouphome'))
|
||||||
|
|
||||||
|
}else{
|
||||||
|
dispatch(routerRedux.replace('/home'))
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@ -155,7 +155,13 @@ export default {
|
|||||||
window.location.replace(config.guideH5Host);
|
window.location.replace(config.guideH5Host);
|
||||||
// dispatch(routerRedux.push("/HomeMobileNew"));
|
// dispatch(routerRedux.push("/HomeMobileNew"));
|
||||||
} else {
|
} else {
|
||||||
dispatch(routerRedux.push("/home"));
|
if (localStorage.getItem("webOrgId") == '00300000-0000-0000-0000-000000000000') {
|
||||||
|
dispatch(routerRedux.replace('/grouphome'))
|
||||||
|
|
||||||
|
}else{
|
||||||
|
dispatch(routerRedux.replace('/home'))
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
// 新开 tab 页面,直接从 login 路径进来,则需要重新检查一下是否登录,未登录则执行登录获取到菜单以及必要数据
|
// 新开 tab 页面,直接从 login 路径进来,则需要重新检查一下是否登录,未登录则执行登录获取到菜单以及必要数据
|
||||||
dispatch({
|
dispatch({
|
||||||
|
|||||||
@ -195,7 +195,12 @@ const Backend = (props) => {
|
|||||||
const [collapsed, setCollapsed] = useState(false)
|
const [collapsed, setCollapsed] = useState(false)
|
||||||
|
|
||||||
const navToHome = () => {
|
const navToHome = () => {
|
||||||
props.history.push({ pathname: '/home' })
|
if (localStorage.getItem("webOrgId") == '00300000-0000-0000-0000-000000000000') {
|
||||||
|
props.history.replace('/grouphome')
|
||||||
|
|
||||||
|
}else{
|
||||||
|
props.history.replace('/home')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
@ -207,10 +207,9 @@ class GroupHome extends React.Component {
|
|||||||
}
|
}
|
||||||
|
|
||||||
componentDidMount() {
|
componentDidMount() {
|
||||||
if (localStorage.getItem("webOrgId") !== '00300000-0000-0000-0000-000000000000') {
|
// if (localStorage.getItem("webOrgId") !== '00300000-0000-0000-0000-000000000000') {
|
||||||
history.replace('/home')
|
// history.replace('/home')
|
||||||
// props.history.push({ pathname: "/grouphome" });
|
// }
|
||||||
}
|
|
||||||
if (window.navigator.userAgent.indexOf("Windows") < 1) {
|
if (window.navigator.userAgent.indexOf("Windows") < 1) {
|
||||||
window.location.replace(config.guideH5Host);
|
window.location.replace(config.guideH5Host);
|
||||||
openNotificationMobile("bottomRight");
|
openNotificationMobile("bottomRight");
|
||||||
|
|||||||
@ -214,11 +214,10 @@ class Home extends React.Component {
|
|||||||
componentDidMount() {
|
componentDidMount() {
|
||||||
this._isMounted = true; // 组件挂载时设为true
|
this._isMounted = true; // 组件挂载时设为true
|
||||||
const currentPath = this.props.location.pathname;
|
const currentPath = this.props.location.pathname;
|
||||||
if (localStorage.getItem("webOrgId") == '00300000-0000-0000-0000-000000000000' && currentPath !== '/grouphome') {
|
// if (localStorage.getItem("webOrgId") == '00300000-0000-0000-0000-000000000000' && currentPath !== '/grouphome') {
|
||||||
this.props.history.replace('/grouphome')
|
// this.props.history.replace('/grouphome')
|
||||||
return
|
// return
|
||||||
// props.history.push({ pathname: "/grouphome" });
|
// }
|
||||||
}
|
|
||||||
if (window.navigator.userAgent.indexOf("Windows") < 1) {
|
if (window.navigator.userAgent.indexOf("Windows") < 1) {
|
||||||
window.location.replace(config.guideH5Host);
|
window.location.replace(config.guideH5Host);
|
||||||
openNotificationMobile("bottomRight");
|
openNotificationMobile("bottomRight");
|
||||||
|
|||||||
@ -277,7 +277,13 @@ class LoginPage extends React.Component {
|
|||||||
window.location.replace(config.guideH5Host)
|
window.location.replace(config.guideH5Host)
|
||||||
// this.props.history.push({ pathname: '/HomeMobileNew' })
|
// this.props.history.push({ pathname: '/HomeMobileNew' })
|
||||||
} else {
|
} else {
|
||||||
this.props.history.push({ pathname: '/home' })
|
if (localStorage.getItem("webOrgId") == '00300000-0000-0000-0000-000000000000' ) {
|
||||||
|
this.props.history.replace('/grouphome')
|
||||||
|
|
||||||
|
}else{
|
||||||
|
this.props.history.replace('/home')
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user