diff --git a/www/front_src/src/App.js b/www/front_src/src/App.js index 678f706abd4..d411d57dcb9 100755 --- a/www/front_src/src/App.js +++ b/www/front_src/src/App.js @@ -34,18 +34,19 @@ class App extends Component { } goFull = () => { - window['fullscreenParams'] = window.location.search.split('?')[1] || ''; - setTimeout(()=>{ + const { search, hash } = history.location + window['fullscreenParams'] = (search.split('?')[1] || '') + (hash || '') + setTimeout(() => { this.setState({ isFullscreenEnabled: true }); - },200) + }, 200) } removeFullscreenParams = () => { - if(history.location.pathname == '/centreon/main.php'){ + if (history.location.pathname == '/centreon/main.php') { history.push({ - pathname: '/centreon/main.php', - search: window['fullscreenParams'] - }) + pathname: '/centreon/main.php', + search: window['fullscreenParams'] + }) } delete window['fullscreenParams']; } diff --git a/www/front_src/src/route-components/module/index.js b/www/front_src/src/route-components/module/index.js index 43008f83ad6..c5cdf6a39c8 100755 --- a/www/front_src/src/route-components/module/index.js +++ b/www/front_src/src/route-components/module/index.js @@ -70,14 +70,14 @@ class ModuleRoute extends Component { render() { const { contentHeight, loading } = this.state; const { history } = this.props, - { search } = history.location; - let params; - if(window['fullscreenParams']){ - params = '?'; - params += window['fullscreenParams'] || ''; - }else{ - params = search || ''; - } + { search, hash } = history.location; + let params; + if (window['fullscreenParams']) { + params = '?'; + params += window['fullscreenParams'] || ''; + } else { + params = (search || '') + (hash || ''); + } return ( <> {loading &&