|
|
@ -2,7 +2,13 @@ import PropTypes from 'prop-types';
|
|
|
|
import React, { Component } from 'react';
|
|
|
|
import React, { Component } from 'react';
|
|
|
|
import { connect } from 'react-redux';
|
|
|
|
import { connect } from 'react-redux';
|
|
|
|
import { createSelector } from 'reselect';
|
|
|
|
import { createSelector } from 'reselect';
|
|
|
|
import { saveDownloadClient, setDownloadClientFieldValue, setDownloadClientValue, testDownloadClient } from 'Store/Actions/settingsActions';
|
|
|
|
import {
|
|
|
|
|
|
|
|
saveDownloadClient,
|
|
|
|
|
|
|
|
setDownloadClientFieldValue,
|
|
|
|
|
|
|
|
setDownloadClientValue,
|
|
|
|
|
|
|
|
testDownloadClient,
|
|
|
|
|
|
|
|
toggleAdvancedSettings
|
|
|
|
|
|
|
|
} from 'Store/Actions/settingsActions';
|
|
|
|
import createProviderSettingsSelector from 'Store/Selectors/createProviderSettingsSelector';
|
|
|
|
import createProviderSettingsSelector from 'Store/Selectors/createProviderSettingsSelector';
|
|
|
|
import EditDownloadClientModalContent from './EditDownloadClientModalContent';
|
|
|
|
import EditDownloadClientModalContent from './EditDownloadClientModalContent';
|
|
|
|
|
|
|
|
|
|
|
@ -23,7 +29,8 @@ const mapDispatchToProps = {
|
|
|
|
setDownloadClientValue,
|
|
|
|
setDownloadClientValue,
|
|
|
|
setDownloadClientFieldValue,
|
|
|
|
setDownloadClientFieldValue,
|
|
|
|
saveDownloadClient,
|
|
|
|
saveDownloadClient,
|
|
|
|
testDownloadClient
|
|
|
|
testDownloadClient,
|
|
|
|
|
|
|
|
toggleAdvancedSettings
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
class EditDownloadClientModalContentConnector extends Component {
|
|
|
|
class EditDownloadClientModalContentConnector extends Component {
|
|
|
@ -56,6 +63,10 @@ class EditDownloadClientModalContentConnector extends Component {
|
|
|
|
this.props.testDownloadClient({ id: this.props.id });
|
|
|
|
this.props.testDownloadClient({ id: this.props.id });
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
onAdvancedSettingsPress = () => {
|
|
|
|
|
|
|
|
this.props.toggleAdvancedSettings();
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
//
|
|
|
|
//
|
|
|
|
// Render
|
|
|
|
// Render
|
|
|
|
|
|
|
|
|
|
|
@ -65,6 +76,7 @@ class EditDownloadClientModalContentConnector extends Component {
|
|
|
|
{...this.props}
|
|
|
|
{...this.props}
|
|
|
|
onSavePress={this.onSavePress}
|
|
|
|
onSavePress={this.onSavePress}
|
|
|
|
onTestPress={this.onTestPress}
|
|
|
|
onTestPress={this.onTestPress}
|
|
|
|
|
|
|
|
onAdvancedSettingsPress={this.onAdvancedSettingsPress}
|
|
|
|
onInputChange={this.onInputChange}
|
|
|
|
onInputChange={this.onInputChange}
|
|
|
|
onFieldChange={this.onFieldChange}
|
|
|
|
onFieldChange={this.onFieldChange}
|
|
|
|
/>
|
|
|
|
/>
|
|
|
@ -82,6 +94,7 @@ EditDownloadClientModalContentConnector.propTypes = {
|
|
|
|
setDownloadClientFieldValue: PropTypes.func.isRequired,
|
|
|
|
setDownloadClientFieldValue: PropTypes.func.isRequired,
|
|
|
|
saveDownloadClient: PropTypes.func.isRequired,
|
|
|
|
saveDownloadClient: PropTypes.func.isRequired,
|
|
|
|
testDownloadClient: PropTypes.func.isRequired,
|
|
|
|
testDownloadClient: PropTypes.func.isRequired,
|
|
|
|
|
|
|
|
toggleAdvancedSettings: PropTypes.func.isRequired,
|
|
|
|
onModalClose: PropTypes.func.isRequired
|
|
|
|
onModalClose: PropTypes.func.isRequired
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|