|
|
@@ -16,7 +16,7 @@ export const botInstallationStep = {
|
|
|
};
|
|
|
|
|
|
const CustomBotWithoutProxySettingsAccordion = ({
|
|
|
- appContainer, activeStep, fetchSlackIntegrationData,
|
|
|
+ appContainer, activeStep, fetchData,
|
|
|
slackSigningSecret, slackSigningSecretEnv, slackBotToken, slackBotTokenEnv,
|
|
|
isRegisterSlackCredentials, isSendTestMessage,
|
|
|
onSetSlackSigningSecret, onSetSlackBotToken, onSetIsSendTestMessage,
|
|
|
@@ -31,6 +31,12 @@ const CustomBotWithoutProxySettingsAccordion = ({
|
|
|
const [testChannel, setTestChannel] = useState('');
|
|
|
const currentBotType = 'customBotWithoutProxy';
|
|
|
|
|
|
+ function fetchSlackIntegrationData() {
|
|
|
+ if (fetchData == null) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ fetchData();
|
|
|
+ }
|
|
|
|
|
|
const updateSecretTokenHandler = async() => {
|
|
|
try {
|
|
|
@@ -39,12 +45,7 @@ const CustomBotWithoutProxySettingsAccordion = ({
|
|
|
slackBotToken,
|
|
|
currentBotType,
|
|
|
});
|
|
|
-
|
|
|
- if (fetchSlackIntegrationData != null) {
|
|
|
- console.log('hoge');
|
|
|
- fetchSlackIntegrationData();
|
|
|
- }
|
|
|
-
|
|
|
+ fetchSlackIntegrationData();
|
|
|
toastSuccess(t('toaster.update_successed', { target: t('admin:slack_integration.custom_bot_without_proxy_settings') }));
|
|
|
}
|
|
|
catch (err) {
|
|
|
@@ -213,7 +214,7 @@ CustomBotWithoutProxySettingsAccordion.propTypes = {
|
|
|
isRegisterSlackCredentials: PropTypes.bool,
|
|
|
isSendTestMessage: PropTypes.bool,
|
|
|
isConnectedToSlack: PropTypes.bool,
|
|
|
- fetchSlackIntegrationData: PropTypes.func,
|
|
|
+ fetchData: PropTypes.func,
|
|
|
onSetSlackSigningSecret: PropTypes.func,
|
|
|
onSetSlackBotToken: PropTypes.func,
|
|
|
onSetIsSendTestMessage: PropTypes.func,
|