Skip to content
This repository has been archived by the owner on Sep 5, 2024. It is now read-only.

Commit

Permalink
Revert "Merge pull request #922 from mturley/enable-conversion-hosts-…
Browse files Browse the repository at this point in the history
  • Loading branch information
simaishi committed May 9, 2019
1 parent 0fed6dd commit 95934a1
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 12 deletions.
30 changes: 19 additions & 11 deletions app/javascript/react/screens/App/Settings/Settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,31 @@ const Settings = props => {
<strong>{__('Migration Settings')}</strong>
</Breadcrumb.Item>
</Toolbar>
<div style={{ marginTop: 10 }}>
<Tabs id="settings-tabs" activeKey={match.path} onSelect={key => redirectTo(key)} unmountOnExit>
<Tab eventKey="/settings" title={__('Migration Throttling')}>
<GeneralSettings />
</Tab>
<Tab eventKey="/settings/conversion_hosts" title={__('Conversion Hosts')}>
<ConversionHostsSettings />
</Tab>
</Tabs>
</div>
{props.hideConversionHostSettings ? (
<React.Fragment>
<h2>{__('Migration Throttling')}</h2>
<GeneralSettings />
</React.Fragment>
) : (
<div style={{ marginTop: 10 }}>
<Tabs id="settings-tabs" activeKey={match.path} onSelect={key => redirectTo(key)} unmountOnExit>
<Tab eventKey="/settings" title={__('Migration Throttling')}>
<GeneralSettings />
</Tab>
<Tab eventKey="/settings/conversion_hosts" title={__('Conversion Hosts')}>
<ConversionHostsSettings />
</Tab>
</Tabs>
</div>
)}
</React.Fragment>
);
};

Settings.propTypes = {
match: PropTypes.object,
redirectTo: PropTypes.func
redirectTo: PropTypes.func,
hideConversionHostSettings: PropTypes.bool // TODO remove this when we are ready to release ConversionHostsSettings
};

export default Settings;
4 changes: 3 additions & 1 deletion app/javascript/react/screens/App/Settings/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ import * as RouterActions from '../../../../redux/actions/routerActions';

export const reducers = { settings: reducer };

const mapStateToProps = () => ({});
const mapStateToProps = () => ({
hideConversionHostSettings: true // TODO remove this when we are ready to release ConversionHostsSettings
});

const mergeProps = (stateProps, dispatchProps, ownProps) => Object.assign(stateProps, ownProps.data, dispatchProps);

Expand Down

0 comments on commit 95934a1

Please sign in to comment.