解决标签显示
This commit is contained in:
parent
dd4a69872d
commit
3686744a51
|
@ -39,6 +39,7 @@ export default class topNav extends React.Component{
|
|||
}
|
||||
//返回
|
||||
backFn(items){
|
||||
|
||||
this.setState({'pathname2':items[0].path});
|
||||
sessionStorage.setItem('showflag',true)
|
||||
sessionStorage.setItem('pathname2',items[0].path)
|
||||
|
@ -53,6 +54,7 @@ export default class topNav extends React.Component{
|
|||
|
||||
}
|
||||
render(){
|
||||
let history0= window.history.length<=1;
|
||||
let routeflag=sessionStorage.getItem('showflag')
|
||||
let breaknav=JSON.parse(sessionStorage.getItem('breaknav'))
|
||||
let pathnameBreak=sessionStorage.getItem('pathname2')
|
||||
|
@ -62,7 +64,7 @@ export default class topNav extends React.Component{
|
|||
let sedcbreakflag=pathnamestr.includes('plan-create');
|
||||
let planbreakflag = pathnamestr.includes('mytempMould')
|
||||
let editbreakflag = pathnamestr.includes('edittemplate')
|
||||
let breakchange = pathnamestr.includes('exchangecode-add')|| pathnamestr.includes('key-edit')||pathnamestr.includes('product-edit');
|
||||
let breakchange = pathnamestr.includes('exchangecode-add')|| pathnamestr.includes('key-edit')||pathnamestr.includes('product-edit')||pathnamestr.includes('plan-edit');
|
||||
if(breakchange){
|
||||
breaknav=JSON.parse(sessionStorage.getItem('breakchangenav'))
|
||||
}
|
||||
|
@ -109,9 +111,12 @@ export default class topNav extends React.Component{
|
|||
breaknav.map((item,key)=>{
|
||||
return(
|
||||
<div className="nolinkmenu-row" key={key}>
|
||||
<Pop trigger="hover" position="bottom-center" content="返回">
|
||||
{
|
||||
!history0? <Pop trigger="hover" position="bottom-center" content="返回">
|
||||
<img onClick={()=>this.backFn(item.items)} src="https://lsxdemall.oss-cn-beijing.aliyuncs.com/Marketing/back.svg" alt=""/>
|
||||
</Pop>
|
||||
</Pop>:null
|
||||
}
|
||||
|
||||
|
||||
<div className="nonav">
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue