Commit b67e62aa authored by 张帆's avatar 张帆

修改站点切换未判断站点名称问题

parent c7d05665
Pipeline #78989 passed with stages
...@@ -255,7 +255,7 @@ const GlobalHeaderRight = props => { ...@@ -255,7 +255,7 @@ const GlobalHeaderRight = props => {
if(global.mapsettings&&global.mapsettings.layers){ if(global.mapsettings&&global.mapsettings.layers){
global.mapsettings.layers.forEach((item)=>{ global.mapsettings.layers.forEach((item)=>{
if(item.layerType=="PipenetLayer"){ if(item.layerType=="PipenetLayer"){
let roalarr = item.roleNames.split(",") let roalarr = item.roleNames?item.roleNames.split(","):[]
if(roalarr.length){ if(roalarr.length){
roalarr.forEach((result)=>{ roalarr.forEach((result)=>{
if(result.includes('站点_')){ if(result.includes('站点_')){
...@@ -282,6 +282,7 @@ const GlobalHeaderRight = props => { ...@@ -282,6 +282,7 @@ const GlobalHeaderRight = props => {
<div className={className}> <div className={className}>
{renderTopMenu()} {renderTopMenu()}
{ {
roleStationArr.current.length>1&&(
<div className={styles.curentPersonStationWriper}> <div className={styles.curentPersonStationWriper}>
<span>站点:</span> <span>站点:</span>
<div className={styles.currentPersonStationSlect}> <div className={styles.currentPersonStationSlect}>
...@@ -327,6 +328,7 @@ const GlobalHeaderRight = props => { ...@@ -327,6 +328,7 @@ const GlobalHeaderRight = props => {
</Select> </Select>
</div> </div>
</div> </div>
)
} }
<Avatar menu config={props.global} updateCurrentIndex={props.updateCurrentIndex} updateConfig={props.updateConfig} logout={logout} /> <Avatar menu config={props.global} updateCurrentIndex={props.updateCurrentIndex} updateConfig={props.updateConfig} logout={logout} />
</div> </div>
......
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