|
@@ -10,7 +10,7 @@ import CustomBotWithoutProxyIntegrationCard from './CustomBotWithoutProxyIntegra
|
|
|
import DeleteSlackCredentialsModal from './DeleteSlackCredentialsModal';
|
|
import DeleteSlackCredentialsModal from './DeleteSlackCredentialsModal';
|
|
|
|
|
|
|
|
const CustomBotWithoutProxySettings = (props) => {
|
|
const CustomBotWithoutProxySettings = (props) => {
|
|
|
- const { appContainer, isSlackScopeSet } = props;
|
|
|
|
|
|
|
+ const { appContainer, /* isSlackScopeSet, */ isSetupSlackBot } = props;
|
|
|
const { t } = useTranslation();
|
|
const { t } = useTranslation();
|
|
|
|
|
|
|
|
const [siteName, setSiteName] = useState('');
|
|
const [siteName, setSiteName] = useState('');
|
|
@@ -23,6 +23,7 @@ const CustomBotWithoutProxySettings = (props) => {
|
|
|
slackBotToken: '',
|
|
slackBotToken: '',
|
|
|
currentBotType: 'customBotWithoutProxy',
|
|
currentBotType: 'customBotWithoutProxy',
|
|
|
});
|
|
});
|
|
|
|
|
+ props.onSetIsSetupSlackBot(false);
|
|
|
props.fetchSlackIntegrationData();
|
|
props.fetchSlackIntegrationData();
|
|
|
toastSuccess('success');
|
|
toastSuccess('success');
|
|
|
}
|
|
}
|
|
@@ -48,7 +49,7 @@ const CustomBotWithoutProxySettings = (props) => {
|
|
|
|
|
|
|
|
<h2 className="admin-setting-header">{t('admin:slack_integration.custom_bot_without_proxy_settings')}</h2>
|
|
<h2 className="admin-setting-header">{t('admin:slack_integration.custom_bot_without_proxy_settings')}</h2>
|
|
|
|
|
|
|
|
- {isSlackScopeSet && (
|
|
|
|
|
|
|
+ {isSetupSlackBot && (
|
|
|
<button
|
|
<button
|
|
|
className="pull-right btn text-danger border-danger"
|
|
className="pull-right btn text-danger border-danger"
|
|
|
type="button"
|
|
type="button"
|
|
@@ -83,7 +84,9 @@ CustomBotWithoutProxySettings.propTypes = {
|
|
|
isRgisterSlackCredentials: PropTypes.bool,
|
|
isRgisterSlackCredentials: PropTypes.bool,
|
|
|
isConnectedToSlack: PropTypes.bool,
|
|
isConnectedToSlack: PropTypes.bool,
|
|
|
isSlackScopeSet: PropTypes.bool,
|
|
isSlackScopeSet: PropTypes.bool,
|
|
|
|
|
+ isSetupSlackBot: PropTypes.bool,
|
|
|
slackWSNameInWithoutProxy: PropTypes.string,
|
|
slackWSNameInWithoutProxy: PropTypes.string,
|
|
|
|
|
+ onSetIsSetupSlackBot: PropTypes.func,
|
|
|
fetchSlackIntegrationData: PropTypes.func,
|
|
fetchSlackIntegrationData: PropTypes.func,
|
|
|
};
|
|
};
|
|
|
|
|
|