migrate private resources to page

This commit is contained in:
miloschwartz
2026-07-06 21:48:29 -04:00
parent 0b5b732a48
commit a521db91a2
44 changed files with 4775 additions and 2916 deletions
+8 -6
View File
@@ -1,5 +1,12 @@
import type { LauncherResource } from "@server/routers/launcher/types";
export function getPrivateResourceSettingsHref(
orgId: string,
niceId: string
): string {
return `/${orgId}/settings/resources/private/${niceId}/general`;
}
export function getLauncherResourceAdminHref(
orgId: string,
resource: LauncherResource
@@ -8,10 +15,5 @@ export function getLauncherResourceAdminHref(
return `/${orgId}/settings/resources/public/${resource.niceId}/general`;
}
const qs = new URLSearchParams({ query: resource.niceId });
if (resource.site?.siteId != null) {
qs.set("siteId", String(resource.site.siteId));
}
return `/${orgId}/settings/resources/private?${qs.toString()}`;
return getPrivateResourceSettingsHref(orgId, resource.niceId);
}