mirror of
https://github.com/freedbygrace/ActiveDirectoryManager.git
synced 2026-08-19 14:57:03 +00:00
Checkpoint
Replit-Commit-Author: Agent Replit-Commit-Session-Id: 705f2157-ef97-4fbd-89e4-8c7f2ecaea90 Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/7ed01c5f-a82d-405a-b728-b2e3d127c60c/8d2774d3-0a72-4558-9ff6-528629b83b1a.jpg
This commit is contained in:
@@ -172,7 +172,7 @@ export default function SitesPage() {
|
|||||||
isLoading: isLoadingSites,
|
isLoading: isLoadingSites,
|
||||||
refetch: refetchSites,
|
refetch: refetchSites,
|
||||||
} = useQuery<ApiResponse<AdSite>>({
|
} = useQuery<ApiResponse<AdSite>>({
|
||||||
queryKey: ['/api/connections', selectedConnection, '/ad-sites', { page: currentSitePage, top: MAX_ITEMS_PER_PAGE }],
|
queryKey: [`/api/connections/${selectedConnection}/ad-sites?top=${MAX_ITEMS_PER_PAGE}&skip=${(currentSitePage - 1) * MAX_ITEMS_PER_PAGE}`],
|
||||||
enabled: !!selectedConnection,
|
enabled: !!selectedConnection,
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -182,7 +182,7 @@ export default function SitesPage() {
|
|||||||
isLoading: isLoadingSubnets,
|
isLoading: isLoadingSubnets,
|
||||||
refetch: refetchSubnets,
|
refetch: refetchSubnets,
|
||||||
} = useQuery<ApiResponse<AdSubnet>>({
|
} = useQuery<ApiResponse<AdSubnet>>({
|
||||||
queryKey: ['/api/connections', selectedConnection, '/ad-subnets', { page: currentSubnetPage, top: MAX_ITEMS_PER_PAGE }],
|
queryKey: [`/api/connections/${selectedConnection}/ad-subnets?top=${MAX_ITEMS_PER_PAGE}&skip=${(currentSubnetPage - 1) * MAX_ITEMS_PER_PAGE}`],
|
||||||
enabled: !!selectedConnection,
|
enabled: !!selectedConnection,
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -282,7 +282,7 @@ export default function SitesPage() {
|
|||||||
description: "The site has been created successfully.",
|
description: "The site has been created successfully.",
|
||||||
});
|
});
|
||||||
setIsSiteFormOpen(false);
|
setIsSiteFormOpen(false);
|
||||||
queryClient.invalidateQueries({ queryKey: ['/api/connections', selectedConnection, '/ad-sites'] });
|
queryClient.invalidateQueries({ queryKey: [`/api/connections/${selectedConnection}/ad-sites`] });
|
||||||
},
|
},
|
||||||
onError: (error) => {
|
onError: (error) => {
|
||||||
toast({
|
toast({
|
||||||
@@ -318,7 +318,7 @@ export default function SitesPage() {
|
|||||||
});
|
});
|
||||||
setEditingSite(null);
|
setEditingSite(null);
|
||||||
setIsSiteFormOpen(false);
|
setIsSiteFormOpen(false);
|
||||||
queryClient.invalidateQueries({ queryKey: ['/api/connections', selectedConnection, '/ad-sites'] });
|
queryClient.invalidateQueries({ queryKey: [`/api/connections/${selectedConnection}/ad-sites`] });
|
||||||
},
|
},
|
||||||
onError: (error) => {
|
onError: (error) => {
|
||||||
toast({
|
toast({
|
||||||
@@ -348,7 +348,7 @@ export default function SitesPage() {
|
|||||||
title: "Site deleted",
|
title: "Site deleted",
|
||||||
description: "The site has been deleted successfully.",
|
description: "The site has been deleted successfully.",
|
||||||
});
|
});
|
||||||
queryClient.invalidateQueries({ queryKey: ['/api/connections', selectedConnection, '/ad-sites'] });
|
queryClient.invalidateQueries({ queryKey: [`/api/connections/${selectedConnection}/ad-sites`] });
|
||||||
},
|
},
|
||||||
onError: (error) => {
|
onError: (error) => {
|
||||||
toast({
|
toast({
|
||||||
@@ -383,7 +383,7 @@ export default function SitesPage() {
|
|||||||
description: "The subnet has been created successfully.",
|
description: "The subnet has been created successfully.",
|
||||||
});
|
});
|
||||||
setIsSubnetFormOpen(false);
|
setIsSubnetFormOpen(false);
|
||||||
queryClient.invalidateQueries({ queryKey: ['/api/connections', selectedConnection, '/ad-subnets'] });
|
queryClient.invalidateQueries({ queryKey: [`/api/connections/${selectedConnection}/ad-subnets`] });
|
||||||
},
|
},
|
||||||
onError: (error) => {
|
onError: (error) => {
|
||||||
toast({
|
toast({
|
||||||
@@ -419,7 +419,7 @@ export default function SitesPage() {
|
|||||||
});
|
});
|
||||||
setEditingSubnet(null);
|
setEditingSubnet(null);
|
||||||
setIsSubnetFormOpen(false);
|
setIsSubnetFormOpen(false);
|
||||||
queryClient.invalidateQueries({ queryKey: ['/api/connections', selectedConnection, '/ad-subnets'] });
|
queryClient.invalidateQueries({ queryKey: [`/api/connections/${selectedConnection}/ad-subnets`] });
|
||||||
},
|
},
|
||||||
onError: (error) => {
|
onError: (error) => {
|
||||||
toast({
|
toast({
|
||||||
@@ -449,7 +449,7 @@ export default function SitesPage() {
|
|||||||
title: "Subnet deleted",
|
title: "Subnet deleted",
|
||||||
description: "The subnet has been deleted successfully.",
|
description: "The subnet has been deleted successfully.",
|
||||||
});
|
});
|
||||||
queryClient.invalidateQueries({ queryKey: ['/api/connections', selectedConnection, '/ad-subnets'] });
|
queryClient.invalidateQueries({ queryKey: [`/api/connections/${selectedConnection}/ad-subnets`] });
|
||||||
},
|
},
|
||||||
onError: (error) => {
|
onError: (error) => {
|
||||||
toast({
|
toast({
|
||||||
|
|||||||
Reference in New Issue
Block a user