Parcourir la source

Added api call to cluster detail info

jnfrati il y a 5 ans
Parent
commit
bf3ba95901
1 fichiers modifiés avec 11 ajouts et 0 suppressions
  1. 11 0
      dashboard/src/shared/api.tsx

+ 11 - 0
dashboard/src/shared/api.tsx

@@ -389,6 +389,16 @@ const getClusters = baseApi<{}, { id: number }>("GET", (pathParams) => {
   return `/api/projects/${pathParams.id}/clusters`;
   return `/api/projects/${pathParams.id}/clusters`;
 });
 });
 
 
+const getCluster = baseApi<
+  {},
+  {
+    project_id: number;
+    cluster_id: number;
+  }
+>("GET", (pathParams) => {
+  return `/api/projects/${pathParams.project_id}/clusters/${pathParams.cluster_id}`
+});
+
 const getGitRepoList = baseApi<
 const getGitRepoList = baseApi<
   {},
   {},
   {
   {
@@ -846,6 +856,7 @@ export default {
   getChartControllers,
   getChartControllers,
   getClusterIntegrations,
   getClusterIntegrations,
   getClusters,
   getClusters,
+  getCluster,
   getConfigMap,
   getConfigMap,
   getGitRepoList,
   getGitRepoList,
   getGitRepos,
   getGitRepos,