This commit is contained in:
@@ -6,7 +6,7 @@ import Td from '../../../components/Td'
|
||||
import { ShopType, ShopsResponse } from '../types/Types'
|
||||
import moment from 'moment-jalaali'
|
||||
import { Edit } from 'iconsax-react'
|
||||
import { toast } from 'react-toastify'
|
||||
import { toast } from '../../../components/Toast';
|
||||
import Button from '../../../components/Button'
|
||||
import ShopAdminsModal from './components/ShopAdminsModal'
|
||||
import Pagination from '../../../components/Pagination'
|
||||
@@ -56,11 +56,11 @@ const ShopsList: FC = () => {
|
||||
const handleDeleteShop = (shopId: string) => {
|
||||
deleteShop.mutate(shopId, {
|
||||
onSuccess: () => {
|
||||
toast.success('فروشگاه با موفقیت حذف شد')
|
||||
toast('فروشگاه با موفقیت حذف شد', 'success')
|
||||
queryClient.invalidateQueries({ queryKey: ['shops'] })
|
||||
},
|
||||
onError: () => {
|
||||
toast.error('خطا در حذف فروشگاه')
|
||||
toast('خطا در حذف فروشگاه', 'error')
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user