Commit 117625fb authored by Vitaly Slobodin's avatar Vitaly Slobodin

Remove flash messages

parent bdd752c9
<script>
import { GlButton, GlModal, GlModalDirective } from '@gitlab/ui';
import { extendTrial, reactivateTrial } from 'ee/api/subscriptions_api';
import createFlash, { FLASH_TYPES } from '~/flash';
import createFlash from '~/flash';
import { refreshCurrentPage } from '~/lib/utils/url_utility';
import { sprintf, __ } from '~/locale';
import { i18n, TRIAL_ACTION_EXTEND, TRIAL_ACTIONS } from '../constants';
......@@ -29,7 +30,6 @@ export default {
},
data() {
return {
isButtonVisible: true,
isLoading: false,
};
},
......@@ -65,8 +65,7 @@ export default {
await action(this.namespaceId)
.then(() => {
createFlash({ message: this.i18nContext.flashText, type: FLASH_TYPES.SUCCESS });
this.isButtonVisible = false;
refreshCurrentPage();
})
.catch((error) => {
createFlash({
......
......@@ -18,7 +18,6 @@ export const i18n = Object.freeze({
modalText: s__(
'Billings|By reactivating your trial, you will receive an additional 30 days of %{planName}. Your trial can be only reactivated once.',
),
flashText: s__('Billings|Your trial has been reactivated for an additional 30 days.'),
trialActionError: s__('Billings|An error occurred while reactivating your trial.'),
},
});
......@@ -35,10 +35,6 @@ describe('ExtendReactivateTrialButton', () => {
});
});
it('renders the button visible', () => {
expect(findButton().isVisible()).toBe(true);
});
it('does not have loading icon', () => {
expect(findButton().props('loading')).toBe(false);
});
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment