Commit ed743225 authored by 李成峰's avatar 李成峰

perf:站点切换支持外部更改

parent ec4ad640
Pipeline #96719 passed with stages
...@@ -118,8 +118,8 @@ ...@@ -118,8 +118,8 @@
"@wisdom-map/arcgismap":"^2.0.101", "@wisdom-map/arcgismap":"^2.0.101",
"@wisdom-map/basemap":"^2.0.8", "@wisdom-map/basemap":"^2.0.8",
"@wisdom-map/util":"1.2.9", "@wisdom-map/util":"1.2.9",
"@wisdom-map/gis-utils": "^1.0.43", "@wisdom-map/gis-utils": "^1.0.47",
"@wisdom-map/pd-map": "^1.0.144", "@wisdom-map/pd-map": "^1.0.148",
"@wisdom-utils/components": "0.1.376", "@wisdom-utils/components": "0.1.376",
"@wisdom-utils/runtime": "0.0.51", "@wisdom-utils/runtime": "0.0.51",
"@wisdom-utils/utils": "0.1.412", "@wisdom-utils/utils": "0.1.412",
......
...@@ -252,6 +252,24 @@ const GlobalHeaderRight = props => { ...@@ -252,6 +252,24 @@ const GlobalHeaderRight = props => {
},200) },200)
resetMenu() resetMenu()
}; };
useEffect(() => {
const dispatchChangeGlobMenuStation = ({stationAlias, stationName, callBack})=>{
callBack?.();
currentStationChange(stationAlias || stationName, stationName);
}
if(window.share && window.share.event && window.share.event.emit) {
window.share.event.on('dispatchChangeGlobMenuStation', dispatchChangeGlobMenuStation);
}
return ()=>{
if(window.share && window.share.event && window.share.event.emit) {
window.share.event.removeListener('dispatchChangeGlobMenuStation', dispatchChangeGlobMenuStation)
}
};
},[stationvalue]);
useEffect(() => { useEffect(() => {
if (global.userInfo) { if (global.userInfo) {
if(window._changeStation){ if(window._changeStation){
......
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