Ver Fonte

Added api call to cluster detail info

jnfrati há 5 anos atrás
pai
commit
bf3ba95901
1 ficheiros alterados com 11 adições e 0 exclusões
  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,