mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-15 19:16:22 +00:00
Add eslint rule and fix as many issues as possible
This commit is contained in:
@@ -7,4 +7,4 @@ export {
|
||||
useGetServiceAccountProjectLevelPermissions,
|
||||
useGetServiceAccounts,
|
||||
useRenameServiceAccount
|
||||
} from './queries';
|
||||
} from "./queries";
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useMutation, useQuery, useQueryClient } from '@tanstack/react-query';
|
||||
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
|
||||
|
||||
import { apiRequest } from '@app/config/request';
|
||||
import { apiRequest } from "@app/config/request";
|
||||
|
||||
import {
|
||||
CreateServiceAccountDTO,
|
||||
@@ -10,12 +10,12 @@ import {
|
||||
RenameServiceAccountDTO,
|
||||
ServiceAccount,
|
||||
ServiceAccountWorkspacePermission
|
||||
} from './types';
|
||||
} from "./types";
|
||||
|
||||
const serviceAccountKeys = {
|
||||
getServiceAccountById: (serviceAccountId: string) => [{ serviceAccountId }, 'service-account'] as const,
|
||||
getServiceAccounts: (organizationID: string) => [{ organizationID }, 'service-accounts'] as const,
|
||||
getServiceAccountProjectLevelPermissions: (serviceAccountId: string) => [{ serviceAccountId }, 'service-account-project-level-permissions'] as const
|
||||
getServiceAccountById: (serviceAccountId: string) => [{ serviceAccountId }, "service-account"] as const,
|
||||
getServiceAccounts: (organizationID: string) => [{ organizationID }, "service-accounts"] as const,
|
||||
getServiceAccountProjectLevelPermissions: (serviceAccountId: string) => [{ serviceAccountId }, "service-account-project-level-permissions"] as const
|
||||
}
|
||||
|
||||
const fetchServiceAccounts = async (organizationID: string) => {
|
||||
@@ -54,7 +54,7 @@ export const useCreateServiceAccount = () => {
|
||||
|
||||
return useMutation<CreateServiceAccountRes, {}, CreateServiceAccountDTO>({
|
||||
mutationFn: async (body) => {
|
||||
const { data } = await apiRequest.post('/api/v2/service-accounts/', body);
|
||||
const { data } = await apiRequest.post("/api/v2/service-accounts/", body);
|
||||
return data;
|
||||
},
|
||||
onSuccess: ({ serviceAccount }) => {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Workspace } from '../workspace/types';
|
||||
import { Workspace } from "../workspace/types";
|
||||
|
||||
export type ServiceAccount = {
|
||||
_id: string;
|
||||
|
||||
Reference in New Issue
Block a user