Commit 5029535f authored by Natalia Tepluhina's avatar Natalia Tepluhina

Merge branch '285458-show-successful-save-message' into 'master'

Show success message on MR approval settings save

See merge request gitlab-org/gitlab!54408
parents 09f676e1 dfb2a4b3
......@@ -34,6 +34,10 @@ export const updateSettings = ({ commit, state }, endpoint) => {
.put(endpoint, payload)
.then(({ data }) => {
commit(types.UPDATE_SETTINGS_SUCCESS, data);
createFlash({
message: __('Merge request approval settings have been updated.'),
type: 'notice',
});
})
.catch(({ response }) => {
const error = response?.data?.message;
......
......@@ -92,7 +92,12 @@ describe('EE approvals group settings module actions', () => {
{ type: types.UPDATE_SETTINGS_SUCCESS, payload: data },
],
[],
);
).then(() => {
expect(createFlash).toHaveBeenCalledWith({
message: 'Merge request approval settings have been updated.',
type: 'notice',
});
});
});
});
......
......@@ -18536,6 +18536,9 @@ msgstr ""
msgid "Merge request (MR) approvals"
msgstr ""
msgid "Merge request approval settings have been updated."
msgstr ""
msgid "Merge request approvals"
msgstr ""
......
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