fix(ui) - sessions - stop reloading on site change
This commit is contained in:
parent
089867cf0a
commit
2b18939c5c
2 changed files with 3 additions and 7 deletions
|
|
@ -54,9 +54,7 @@ export default class List extends React.PureComponent {
|
|||
}
|
||||
|
||||
componentDidMount() {
|
||||
if (this.props.list.size === 0) {
|
||||
this.props.applyFilter({ });
|
||||
}
|
||||
this.props.applyFilter({ });
|
||||
}
|
||||
|
||||
check = ({ errorId }) => {
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import { connect } from 'react-redux';
|
||||
import { setSiteId } from 'Duck/site';
|
||||
import { withRouter } from 'react-router-dom';
|
||||
import { hasSiteId, siteChangeAvaliable, isRoute, sessions as sessionsRoute } from 'App/routes';
|
||||
import { hasSiteId, siteChangeAvaliable, isRoute } from 'App/routes';
|
||||
import { STATUS_COLOR_MAP, GREEN } from 'Types/site';
|
||||
import { Icon, SlideModal } from 'UI';
|
||||
import { pushNewSite } from 'Duck/user'
|
||||
|
|
@ -14,8 +14,6 @@ import { fetchList as fetchIntegrationVariables } from 'Duck/customField';
|
|||
import { fetchList as fetchAlerts } from 'Duck/alerts';
|
||||
import { fetchWatchdogStatus } from 'Duck/watchdogs';
|
||||
import { withStore } from 'App/mstore'
|
||||
|
||||
const SESSIONS_PATH = sessionsRoute();
|
||||
@withStore
|
||||
@withRouter
|
||||
@connect(state => ({
|
||||
|
|
@ -52,7 +50,7 @@ export default class SiteDropdown extends React.PureComponent {
|
|||
|
||||
|
||||
this.props.setSiteId(siteId);
|
||||
this.props.clearSearch(isRoute(SESSIONS_PATH, location.pathname));
|
||||
this.props.clearSearch(location.pathname.includes('/sessions'));
|
||||
this.props.fetchIntegrationVariables();
|
||||
this.props.fetchAlerts();
|
||||
this.props.fetchWatchdogStatus();
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue