Commit bab26dcb authored by 邓超's avatar 邓超

fix: 修复嵌入web5后路由报错问题

parent 9faf6988
Pipeline #67834 passed with stages
......@@ -85,7 +85,7 @@ const BasicLayout = props => {
return (
<>
{sessionStorage.getItem('_omsticket') == 'd438aaf9578f405299ae740c4eb75aae' ? (
<>{renderRoutes(props.route.routes)}</>
<Switch>{renderRoutes(props.route.routes)}</Switch>
) : (
<ProLayout
logo={() => <img src={logo} style={{ width: '32px', height: '32px' }} alt="" />}
......
......@@ -288,7 +288,13 @@ const WorkflowHomePage = () => {
TweenMax.to(`.${styles.flowTable}`, 1, { scrollTo: val.href });
};
return (
<div className={styles.pageContent}>
<div
className={classnames(styles.pageContent,{
[styles.pageOms]:
sessionStorage.getItem('_omsticket') !== 'd438aaf9578f405299ae740c4eb75aae',
[styles.pageEmbed]: sessionStorage.getItem('_omsticket') === 'd438aaf9578f405299ae740c4eb75aae',
})}
>
<div className={styles.headerBox}>
<div className={styles.left}>
<div
......
.pageContent {
margin-top: -12px;
margin-left: -12px;
width: calc(100% + 24px);
height: calc(100% + 24px);
background: url("../../../../assets/images/workFlow/index/bg.png") no-repeat;
background-size: 100% 100%;
display: flex;
......@@ -359,4 +356,16 @@
}
}
}
}
.pageOms {
margin-top: -12px;
margin-left: -12px;
width: calc(100% + 24px);
height: calc(100% + 24px);
}
.pageEmbed {
width: 100%;
height: 100%;
}
\ No newline at end of file
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