TP-51166 | toast success for remove member
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import { useReducer } from 'react';
|
||||
import { useDispatch } from 'react-redux';
|
||||
import { toast } from '@navi/web-ui/lib/primitives/Toast';
|
||||
import AlertIcon from '@src/assets/AlertIcon';
|
||||
import { AppDispatch } from '@src/store';
|
||||
import { ApiService } from '@src/services/api';
|
||||
import { fetchTeamDetails, fetchTeams } from '@src/slices/team1Slice';
|
||||
@@ -61,9 +60,7 @@ const useTeamApis = (): useTeamApiProps => {
|
||||
ApiService.delete(endpoint)
|
||||
.then(response => {
|
||||
if (response.status === 200) {
|
||||
toast(response.data.data, {
|
||||
icon: <AlertIcon color="var(--navi-color-orange-base)" />,
|
||||
});
|
||||
toast.success(response.data.data);
|
||||
dispatch(fetchTeamDetails(teamId?.toString() || ''));
|
||||
dispatch(fetchTeams());
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user