mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-09 19:28:33 +00:00
feat: ran lint and review comments addressed
This commit is contained in:
@@ -5,6 +5,9 @@ import { registerAccessApprovalRequestRouter } from "./access-approval-request-r
|
|||||||
import { registerAssumePrivilegeRouter } from "./assume-privilege-router";
|
import { registerAssumePrivilegeRouter } from "./assume-privilege-router";
|
||||||
import { AUDIT_LOG_STREAM_REGISTER_ROUTER_MAP, registerAuditLogStreamRouter } from "./audit-log-stream-routers";
|
import { AUDIT_LOG_STREAM_REGISTER_ROUTER_MAP, registerAuditLogStreamRouter } from "./audit-log-stream-routers";
|
||||||
import { registerCaCrlRouter } from "./certificate-authority-crl-router";
|
import { registerCaCrlRouter } from "./certificate-authority-crl-router";
|
||||||
|
import { registerDepreciatedProjectRoleRouter } from "./depreciated-project-role-router";
|
||||||
|
import { registerDepreciatedProjectRouter } from "./depreciated-project-router";
|
||||||
|
import { registerDepreciatedSecretApprovalPolicyRouter } from "./depreciated-secret-approval-policy-router";
|
||||||
import { registerDynamicSecretLeaseRouter } from "./dynamic-secret-lease-router";
|
import { registerDynamicSecretLeaseRouter } from "./dynamic-secret-lease-router";
|
||||||
import { registerKubernetesDynamicSecretLeaseRouter } from "./dynamic-secret-lease-routers/kubernetes-lease-router";
|
import { registerKubernetesDynamicSecretLeaseRouter } from "./dynamic-secret-lease-routers/kubernetes-lease-router";
|
||||||
import { registerDynamicSecretRouter } from "./dynamic-secret-router";
|
import { registerDynamicSecretRouter } from "./dynamic-secret-router";
|
||||||
@@ -22,14 +25,11 @@ import { registerOidcRouter } from "./oidc-router";
|
|||||||
import { registerOrgRoleRouter } from "./org-role-router";
|
import { registerOrgRoleRouter } from "./org-role-router";
|
||||||
import { registerPITRouter } from "./pit-router";
|
import { registerPITRouter } from "./pit-router";
|
||||||
import { registerProjectRoleRouter } from "./project-role-router";
|
import { registerProjectRoleRouter } from "./project-role-router";
|
||||||
import { registerDepreciatedProjectRoleRouter } from "./depreciated-project-role-router";
|
|
||||||
import { registerProjectRouter } from "./project-router";
|
import { registerProjectRouter } from "./project-router";
|
||||||
import { registerDepreciatedProjectRouter } from "./depreciated-project-router";
|
|
||||||
import { registerRateLimitRouter } from "./rate-limit-router";
|
import { registerRateLimitRouter } from "./rate-limit-router";
|
||||||
import { registerRelayRouter } from "./relay-router";
|
import { registerRelayRouter } from "./relay-router";
|
||||||
import { registerSamlRouter } from "./saml-router";
|
import { registerSamlRouter } from "./saml-router";
|
||||||
import { registerScimRouter } from "./scim-router";
|
import { registerScimRouter } from "./scim-router";
|
||||||
import { registerDepreciatedSecretApprovalPolicyRouter } from "./depreciated-secret-approval-policy-router";
|
|
||||||
import { registerSecretApprovalRequestRouter } from "./secret-approval-request-router";
|
import { registerSecretApprovalRequestRouter } from "./secret-approval-request-router";
|
||||||
import { registerSecretRotationProviderRouter } from "./secret-rotation-provider-router";
|
import { registerSecretRotationProviderRouter } from "./secret-rotation-provider-router";
|
||||||
import { registerSecretRotationRouter } from "./secret-rotation-router";
|
import { registerSecretRotationRouter } from "./secret-rotation-router";
|
||||||
|
|||||||
@@ -7,9 +7,9 @@ import {
|
|||||||
SECRET_SCANNING_REGISTER_ROUTER_MAP
|
SECRET_SCANNING_REGISTER_ROUTER_MAP
|
||||||
} from "@app/ee/routes/v2/secret-scanning-v2-routers";
|
} from "@app/ee/routes/v2/secret-scanning-v2-routers";
|
||||||
|
|
||||||
|
import { registerDepreciatedProjectRoleRouter } from "./depreciated-project-role-router";
|
||||||
import { registerGatewayV2Router } from "./gateway-router";
|
import { registerGatewayV2Router } from "./gateway-router";
|
||||||
import { registerIdentityProjectAdditionalPrivilegeRouter } from "./identity-project-additional-privilege-router";
|
import { registerIdentityProjectAdditionalPrivilegeRouter } from "./identity-project-additional-privilege-router";
|
||||||
import { registerDepreciatedProjectRoleRouter } from "./depreciated-project-role-router";
|
|
||||||
import { registerSecretApprovalPolicyRouter } from "./secret-approval-policy-router";
|
import { registerSecretApprovalPolicyRouter } from "./secret-approval-policy-router";
|
||||||
|
|
||||||
export const registerV2EERoutes = async (server: FastifyZodProvider) => {
|
export const registerV2EERoutes = async (server: FastifyZodProvider) => {
|
||||||
|
|||||||
@@ -16,6 +16,8 @@ import { registerCertificateTemplateRouter } from "./certificate-template-router
|
|||||||
import { registerDepreciatedProjectEnvRouter } from "./depreciated-project-env-router";
|
import { registerDepreciatedProjectEnvRouter } from "./depreciated-project-env-router";
|
||||||
import { registerDepreciatedProjectMembershipRouter } from "./depreciated-project-membership-router";
|
import { registerDepreciatedProjectMembershipRouter } from "./depreciated-project-membership-router";
|
||||||
import { registerDepreciatedProjectRouter } from "./depreciated-project-router";
|
import { registerDepreciatedProjectRouter } from "./depreciated-project-router";
|
||||||
|
import { registerDepreciatedSecretFolderRouter } from "./depreciated-secret-folder-router";
|
||||||
|
import { registerDepreciatedSecretImportRouter } from "./depreciated-secret-import-router";
|
||||||
import { registerDepreciatedSecretTagRouter } from "./depreciated-secret-tag-router";
|
import { registerDepreciatedSecretTagRouter } from "./depreciated-secret-tag-router";
|
||||||
import { registerEventRouter } from "./event-router";
|
import { registerEventRouter } from "./event-router";
|
||||||
import { registerExternalGroupOrgRoleMappingRouter } from "./external-group-org-role-mapping-router";
|
import { registerExternalGroupOrgRoleMappingRouter } from "./external-group-org-role-mapping-router";
|
||||||
@@ -30,6 +32,7 @@ import { registerIdentityKubernetesRouter } from "./identity-kubernetes-auth-rou
|
|||||||
import { registerIdentityLdapAuthRouter } from "./identity-ldap-auth-router";
|
import { registerIdentityLdapAuthRouter } from "./identity-ldap-auth-router";
|
||||||
import { registerIdentityOciAuthRouter } from "./identity-oci-auth-router";
|
import { registerIdentityOciAuthRouter } from "./identity-oci-auth-router";
|
||||||
import { registerIdentityOidcAuthRouter } from "./identity-oidc-auth-router";
|
import { registerIdentityOidcAuthRouter } from "./identity-oidc-auth-router";
|
||||||
|
import { registerIdentityProjectRouter } from "./identity-project-router";
|
||||||
import { registerIdentityRouter } from "./identity-router";
|
import { registerIdentityRouter } from "./identity-router";
|
||||||
import { registerIdentityTlsCertAuthRouter } from "./identity-tls-cert-auth-router";
|
import { registerIdentityTlsCertAuthRouter } from "./identity-tls-cert-auth-router";
|
||||||
import { registerIdentityTokenAuthRouter } from "./identity-token-auth-router";
|
import { registerIdentityTokenAuthRouter } from "./identity-token-auth-router";
|
||||||
@@ -50,8 +53,6 @@ import { registerProjectKeyRouter } from "./project-key-router";
|
|||||||
import { registerProjectMembershipRouter } from "./project-membership-router";
|
import { registerProjectMembershipRouter } from "./project-membership-router";
|
||||||
import { registerProjectRouter } from "./project-router";
|
import { registerProjectRouter } from "./project-router";
|
||||||
import { SECRET_REMINDER_REGISTER_ROUTER_MAP } from "./reminder-routers";
|
import { SECRET_REMINDER_REGISTER_ROUTER_MAP } from "./reminder-routers";
|
||||||
import { registerDepreciatedSecretFolderRouter } from "./depreciated-secret-folder-router";
|
|
||||||
import { registerDepreciatedSecretImportRouter } from "./depreciated-secret-import-router";
|
|
||||||
import { registerSecretRequestsRouter } from "./secret-requests-router";
|
import { registerSecretRequestsRouter } from "./secret-requests-router";
|
||||||
import { registerSecretSharingRouter } from "./secret-sharing-router";
|
import { registerSecretSharingRouter } from "./secret-sharing-router";
|
||||||
import { registerSecretTagRouter } from "./secret-tag-router";
|
import { registerSecretTagRouter } from "./secret-tag-router";
|
||||||
@@ -62,7 +63,6 @@ import { registerUserEngagementRouter } from "./user-engagement-router";
|
|||||||
import { registerUserRouter } from "./user-router";
|
import { registerUserRouter } from "./user-router";
|
||||||
import { registerWebhookRouter } from "./webhook-router";
|
import { registerWebhookRouter } from "./webhook-router";
|
||||||
import { registerWorkflowIntegrationRouter } from "./workflow-integration-router";
|
import { registerWorkflowIntegrationRouter } from "./workflow-integration-router";
|
||||||
import { registerIdentityProjectRouter } from "./identity-project-router";
|
|
||||||
|
|
||||||
export const registerV1Routes = async (server: FastifyZodProvider) => {
|
export const registerV1Routes = async (server: FastifyZodProvider) => {
|
||||||
await server.register(registerSsoRouter, { prefix: "/sso" });
|
await server.register(registerSsoRouter, { prefix: "/sso" });
|
||||||
|
|||||||
@@ -85,7 +85,7 @@ export const registerProjectEnvRouter = async (server: FastifyZodProvider) => {
|
|||||||
response: {
|
response: {
|
||||||
200: z.object({
|
200: z.object({
|
||||||
message: z.string(),
|
message: z.string(),
|
||||||
workspace: z.string(),
|
projectId: z.string(),
|
||||||
environment: ProjectEnvironmentsSchema
|
environment: ProjectEnvironmentsSchema
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -114,7 +114,7 @@ export const registerProjectEnvRouter = async (server: FastifyZodProvider) => {
|
|||||||
});
|
});
|
||||||
return {
|
return {
|
||||||
message: "Successfully created new environment",
|
message: "Successfully created new environment",
|
||||||
workspace: req.params.projectId,
|
projectId: req.params.projectId,
|
||||||
environment
|
environment
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@@ -147,7 +147,7 @@ export const registerProjectEnvRouter = async (server: FastifyZodProvider) => {
|
|||||||
response: {
|
response: {
|
||||||
200: z.object({
|
200: z.object({
|
||||||
message: z.string(),
|
message: z.string(),
|
||||||
workspace: z.string(),
|
projectId: z.string(),
|
||||||
environment: ProjectEnvironmentsSchema
|
environment: ProjectEnvironmentsSchema
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -182,7 +182,7 @@ export const registerProjectEnvRouter = async (server: FastifyZodProvider) => {
|
|||||||
|
|
||||||
return {
|
return {
|
||||||
message: "Successfully updated environment",
|
message: "Successfully updated environment",
|
||||||
workspace: req.params.projectId,
|
projectId: req.params.projectId,
|
||||||
environment
|
environment
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@@ -210,7 +210,7 @@ export const registerProjectEnvRouter = async (server: FastifyZodProvider) => {
|
|||||||
response: {
|
response: {
|
||||||
200: z.object({
|
200: z.object({
|
||||||
message: z.string(),
|
message: z.string(),
|
||||||
workspace: z.string(),
|
projectId: z.string(),
|
||||||
environment: ProjectEnvironmentsSchema
|
environment: ProjectEnvironmentsSchema
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -240,7 +240,7 @@ export const registerProjectEnvRouter = async (server: FastifyZodProvider) => {
|
|||||||
|
|
||||||
return {
|
return {
|
||||||
message: "Successfully deleted environment",
|
message: "Successfully deleted environment",
|
||||||
workspace: req.params.projectId,
|
projectId: req.params.projectId,
|
||||||
environment
|
environment
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -137,7 +137,6 @@ export const registerProjectMembershipRouter = async (server: FastifyZodProvider
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// TODO(depri): ask this usage again
|
|
||||||
server.route({
|
server.route({
|
||||||
method: "POST",
|
method: "POST",
|
||||||
url: "/:projectId/memberships/details",
|
url: "/:projectId/memberships/details",
|
||||||
|
|||||||
@@ -19,15 +19,28 @@ import {
|
|||||||
} from "@app/db/schemas";
|
} from "@app/db/schemas";
|
||||||
import { ProjectMicrosoftTeamsConfigsSchema } from "@app/db/schemas/project-microsoft-teams-configs";
|
import { ProjectMicrosoftTeamsConfigsSchema } from "@app/db/schemas/project-microsoft-teams-configs";
|
||||||
import { EventType } from "@app/ee/services/audit-log/audit-log-types";
|
import { EventType } from "@app/ee/services/audit-log/audit-log-types";
|
||||||
|
import { InfisicalProjectTemplate } from "@app/ee/services/project-template/project-template-types";
|
||||||
|
import { sanitizedSshCa } from "@app/ee/services/ssh/ssh-certificate-authority-schema";
|
||||||
|
import { sanitizedSshCertificate } from "@app/ee/services/ssh-certificate/ssh-certificate-schema";
|
||||||
|
import { sanitizedSshCertificateTemplate } from "@app/ee/services/ssh-certificate-template/ssh-certificate-template-schema";
|
||||||
|
import { loginMappingSchema, sanitizedSshHost } from "@app/ee/services/ssh-host/ssh-host-schema";
|
||||||
|
import { LoginMappingSource } from "@app/ee/services/ssh-host/ssh-host-types";
|
||||||
|
import { sanitizedSshHostGroup } from "@app/ee/services/ssh-host-group/ssh-host-group-schema";
|
||||||
import { ApiDocsTags, PROJECTS } from "@app/lib/api-docs";
|
import { ApiDocsTags, PROJECTS } from "@app/lib/api-docs";
|
||||||
import { CharacterType, characterValidator } from "@app/lib/validator/validate-string";
|
import { CharacterType, characterValidator } from "@app/lib/validator/validate-string";
|
||||||
import { re2Validator } from "@app/lib/zod";
|
import { re2Validator } from "@app/lib/zod";
|
||||||
import { readLimit, requestAccessLimit, writeLimit } from "@app/server/config/rateLimiter";
|
import { readLimit, requestAccessLimit, writeLimit } from "@app/server/config/rateLimiter";
|
||||||
|
import { slugSchema } from "@app/server/lib/schemas";
|
||||||
|
import { getTelemetryDistinctId } from "@app/server/lib/telemetry";
|
||||||
import { verifyAuth } from "@app/server/plugins/auth/verify-auth";
|
import { verifyAuth } from "@app/server/plugins/auth/verify-auth";
|
||||||
import { ActorType, AuthMode } from "@app/services/auth/auth-type";
|
import { ActorType, AuthMode } from "@app/services/auth/auth-type";
|
||||||
|
import { CaStatus } from "@app/services/certificate-authority/certificate-authority-enums";
|
||||||
|
import { sanitizedCertificateTemplate } from "@app/services/certificate-template/certificate-template-schema";
|
||||||
import { validateMicrosoftTeamsChannelsSchema } from "@app/services/microsoft-teams/microsoft-teams-fns";
|
import { validateMicrosoftTeamsChannelsSchema } from "@app/services/microsoft-teams/microsoft-teams-fns";
|
||||||
|
import { sanitizedPkiSubscriber } from "@app/services/pki-subscriber/pki-subscriber-schema";
|
||||||
import { ProjectFilterType, SearchProjectSortBy } from "@app/services/project/project-types";
|
import { ProjectFilterType, SearchProjectSortBy } from "@app/services/project/project-types";
|
||||||
import { validateSlackChannelsField } from "@app/services/slack/slack-auth-validators";
|
import { validateSlackChannelsField } from "@app/services/slack/slack-auth-validators";
|
||||||
|
import { PostHogEventTypes } from "@app/services/telemetry/telemetry-types";
|
||||||
import { WorkflowIntegration } from "@app/services/workflow-integration/workflow-integration-types";
|
import { WorkflowIntegration } from "@app/services/workflow-integration/workflow-integration-types";
|
||||||
|
|
||||||
import {
|
import {
|
||||||
@@ -36,19 +49,6 @@ import {
|
|||||||
SanitizedProjectSchema
|
SanitizedProjectSchema
|
||||||
} from "../sanitizedSchemas";
|
} from "../sanitizedSchemas";
|
||||||
import { sanitizedServiceTokenSchema } from "../v2/service-token-router";
|
import { sanitizedServiceTokenSchema } from "../v2/service-token-router";
|
||||||
import { slugSchema } from "@app/server/lib/schemas";
|
|
||||||
import { CaStatus } from "@app/services/certificate-authority/certificate-authority-enums";
|
|
||||||
import { sanitizedCertificateTemplate } from "@app/services/certificate-template/certificate-template-schema";
|
|
||||||
import { sanitizedSshCertificate } from "@app/ee/services/ssh-certificate/ssh-certificate-schema";
|
|
||||||
import { sanitizedSshCertificateTemplate } from "@app/ee/services/ssh-certificate-template/ssh-certificate-template-schema";
|
|
||||||
import { sanitizedSshCa } from "@app/ee/services/ssh/ssh-certificate-authority-schema";
|
|
||||||
import { loginMappingSchema, sanitizedSshHost } from "@app/ee/services/ssh-host/ssh-host-schema";
|
|
||||||
import { LoginMappingSource } from "@app/ee/services/ssh-host/ssh-host-types";
|
|
||||||
import { sanitizedSshHostGroup } from "@app/ee/services/ssh-host-group/ssh-host-group-schema";
|
|
||||||
import { InfisicalProjectTemplate } from "@app/ee/services/project-template/project-template-types";
|
|
||||||
import { PostHogEventTypes } from "@app/services/telemetry/telemetry-types";
|
|
||||||
import { getTelemetryDistinctId } from "@app/server/lib/telemetry";
|
|
||||||
import { sanitizedPkiSubscriber } from "@app/services/pki-subscriber/pki-subscriber-schema";
|
|
||||||
|
|
||||||
const projectWithEnv = SanitizedProjectSchema.merge(
|
const projectWithEnv = SanitizedProjectSchema.merge(
|
||||||
z.object({
|
z.object({
|
||||||
@@ -292,7 +292,6 @@ export const registerProjectRouter = async (server: FastifyZodProvider) => {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// TODO(depri): confirm with the team
|
|
||||||
server.route({
|
server.route({
|
||||||
method: "GET",
|
method: "GET",
|
||||||
url: "/slug/:slug",
|
url: "/slug/:slug",
|
||||||
|
|||||||
@@ -1,17 +1,17 @@
|
|||||||
import { registerCaRouter } from "./certificate-authority-router";
|
import { registerCaRouter } from "./certificate-authority-router";
|
||||||
import { registerDepreciatedGroupProjectRouter } from "./depreciated-group-project-router";
|
import { registerDepreciatedGroupProjectRouter } from "./depreciated-group-project-router";
|
||||||
import { registerIdentityOrgRouter } from "./identity-org-router";
|
|
||||||
import { registerDepreciatedIdentityProjectRouter } from "./depreciated-identity-project-router";
|
import { registerDepreciatedIdentityProjectRouter } from "./depreciated-identity-project-router";
|
||||||
|
import { registerDepreciatedProjectMembershipRouter } from "./depreciated-project-membership-router";
|
||||||
|
import { registerDepreciatedProjectRouter } from "./depreciated-project-router";
|
||||||
|
import { registerIdentityOrgRouter } from "./identity-org-router";
|
||||||
import { registerMfaRouter } from "./mfa-router";
|
import { registerMfaRouter } from "./mfa-router";
|
||||||
import { registerOrgRouter } from "./organization-router";
|
import { registerOrgRouter } from "./organization-router";
|
||||||
import { registerPasswordRouter } from "./password-router";
|
import { registerPasswordRouter } from "./password-router";
|
||||||
import { registerPkiTemplatesRouter } from "./pki-templates-router";
|
import { registerPkiTemplatesRouter } from "./pki-templates-router";
|
||||||
import { registerDepreciatedProjectMembershipRouter } from "./depreciated-project-membership-router";
|
|
||||||
import { registerDepreciatedProjectRouter } from "./depreciated-project-router";
|
|
||||||
import { registerServiceTokenRouter } from "./service-token-router";
|
|
||||||
import { registerUserRouter } from "./user-router";
|
|
||||||
import { registerSecretFolderRouter } from "./secret-folder-router";
|
import { registerSecretFolderRouter } from "./secret-folder-router";
|
||||||
import { registerSecretImportRouter } from "./secret-import-router";
|
import { registerSecretImportRouter } from "./secret-import-router";
|
||||||
|
import { registerServiceTokenRouter } from "./service-token-router";
|
||||||
|
import { registerUserRouter } from "./user-router";
|
||||||
|
|
||||||
export const registerV2Routes = async (server: FastifyZodProvider) => {
|
export const registerV2Routes = async (server: FastifyZodProvider) => {
|
||||||
await server.register(registerMfaRouter, { prefix: "/auth" });
|
await server.register(registerMfaRouter, { prefix: "/auth" });
|
||||||
|
|||||||
@@ -298,7 +298,7 @@ export const registerDepreciatedSecretRouter = async (server: FastifyZodProvider
|
|||||||
workspaceId = projectId;
|
workspaceId = projectId;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!workspaceId || !environment) throw new BadRequestError({ message: "Missing workspace id or environment" });
|
if (!workspaceId || !environment) throw new BadRequestError({ message: "Missing project id or environment" });
|
||||||
|
|
||||||
const { secrets, imports } = await server.services.secret.getSecretsRaw({
|
const { secrets, imports } = await server.services.secret.getSecretsRaw({
|
||||||
actorId: req.permission.id,
|
actorId: req.permission.id,
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
|
import { registerDepreciatedSecretRouter } from "./depreciated-secret-router";
|
||||||
import { registerExternalMigrationRouter } from "./external-migration-router";
|
import { registerExternalMigrationRouter } from "./external-migration-router";
|
||||||
import { registerLoginRouter } from "./login-router";
|
import { registerLoginRouter } from "./login-router";
|
||||||
import { registerDepreciatedSecretRouter } from "./depreciated-secret-router";
|
|
||||||
import { registerSignupRouter } from "./signup-router";
|
import { registerSignupRouter } from "./signup-router";
|
||||||
import { registerUserRouter } from "./user-router";
|
import { registerUserRouter } from "./user-router";
|
||||||
|
|
||||||
|
|||||||
@@ -172,7 +172,7 @@ export const registerSecretRouter = async (server: FastifyZodProvider) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!projectId || !environment) throw new BadRequestError({ message: "Missing workspace id or environment" });
|
if (!projectId || !environment) throw new BadRequestError({ message: "Missing project id or environment" });
|
||||||
|
|
||||||
const { secrets, imports } = await server.services.secret.getSecretsRaw({
|
const { secrets, imports } = await server.services.secret.getSecretsRaw({
|
||||||
actorId: req.permission.id,
|
actorId: req.permission.id,
|
||||||
@@ -225,7 +225,7 @@ export const registerSecretRouter = async (server: FastifyZodProvider) => {
|
|||||||
|
|
||||||
server.route({
|
server.route({
|
||||||
method: "GET",
|
method: "GET",
|
||||||
url: "/raw/id/:secretId",
|
url: "/id/:secretId",
|
||||||
config: {
|
config: {
|
||||||
rateLimit: secretsLimit
|
rateLimit: secretsLimit
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -36,8 +36,8 @@ import {
|
|||||||
import { getProjectHomePage, getProjectLottieIcon } from "@app/helpers/project";
|
import { getProjectHomePage, getProjectLottieIcon } from "@app/helpers/project";
|
||||||
import { useCreateWorkspace, useGetExternalKmsList, useGetUserProjects } from "@app/hooks/api";
|
import { useCreateWorkspace, useGetExternalKmsList, useGetUserProjects } from "@app/hooks/api";
|
||||||
import { INTERNAL_KMS_KEY_ID } from "@app/hooks/api/kms/types";
|
import { INTERNAL_KMS_KEY_ID } from "@app/hooks/api/kms/types";
|
||||||
import { InfisicalProjectTemplate, useListProjectTemplates } from "@app/hooks/api/projectTemplates";
|
|
||||||
import { ProjectType } from "@app/hooks/api/projects/types";
|
import { ProjectType } from "@app/hooks/api/projects/types";
|
||||||
|
import { InfisicalProjectTemplate, useListProjectTemplates } from "@app/hooks/api/projectTemplates";
|
||||||
|
|
||||||
const formSchema = z.object({
|
const formSchema = z.object({
|
||||||
name: z.string().trim().min(1, "Required").max(64, "Too long, maximum length is 64 characters"),
|
name: z.string().trim().min(1, "Required").max(64, "Too long, maximum length is 64 characters"),
|
||||||
|
|||||||
@@ -6,8 +6,8 @@ import { SecretRotationV2Form } from "@app/components/secret-rotations-v2/forms"
|
|||||||
import { SecretRotationV2ModalHeader } from "@app/components/secret-rotations-v2/SecretRotationV2ModalHeader";
|
import { SecretRotationV2ModalHeader } from "@app/components/secret-rotations-v2/SecretRotationV2ModalHeader";
|
||||||
import { SecretRotationV2Select } from "@app/components/secret-rotations-v2/SecretRotationV2Select";
|
import { SecretRotationV2Select } from "@app/components/secret-rotations-v2/SecretRotationV2Select";
|
||||||
import { Modal, ModalContent } from "@app/components/v2";
|
import { Modal, ModalContent } from "@app/components/v2";
|
||||||
import { SecretRotation, TSecretRotationV2 } from "@app/hooks/api/secretRotationsV2";
|
|
||||||
import { ProjectEnv } from "@app/hooks/api/projects/types";
|
import { ProjectEnv } from "@app/hooks/api/projects/types";
|
||||||
|
import { SecretRotation, TSecretRotationV2 } from "@app/hooks/api/secretRotationsV2";
|
||||||
|
|
||||||
type SharedProps = {
|
type SharedProps = {
|
||||||
secretPath: string;
|
secretPath: string;
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ import { SecretRotationV2SecretsMappingFields } from "@app/components/secret-rot
|
|||||||
import { Button } from "@app/components/v2";
|
import { Button } from "@app/components/v2";
|
||||||
import { useProject } from "@app/context";
|
import { useProject } from "@app/context";
|
||||||
import { IS_ROTATION_DUAL_CREDENTIALS, SECRET_ROTATION_MAP } from "@app/helpers/secretRotationsV2";
|
import { IS_ROTATION_DUAL_CREDENTIALS, SECRET_ROTATION_MAP } from "@app/helpers/secretRotationsV2";
|
||||||
|
import { ProjectEnv } from "@app/hooks/api/projects/types";
|
||||||
import {
|
import {
|
||||||
SecretRotation,
|
SecretRotation,
|
||||||
TSecretRotationV2,
|
TSecretRotationV2,
|
||||||
@@ -22,7 +23,6 @@ import {
|
|||||||
useCreateSecretRotationV2,
|
useCreateSecretRotationV2,
|
||||||
useUpdateSecretRotationV2
|
useUpdateSecretRotationV2
|
||||||
} from "@app/hooks/api/secretRotationsV2/mutations";
|
} from "@app/hooks/api/secretRotationsV2/mutations";
|
||||||
import { ProjectEnv } from "@app/hooks/api/projects/types";
|
|
||||||
|
|
||||||
import { SecretRotationV2FormSchema, TSecretRotationV2Form } from "./schemas";
|
import { SecretRotationV2FormSchema, TSecretRotationV2Form } from "./schemas";
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ import { subject } from "@casl/ability";
|
|||||||
|
|
||||||
import { FilterableSelect, FormControl } from "@app/components/v2";
|
import { FilterableSelect, FormControl } from "@app/components/v2";
|
||||||
import { SecretPathInput } from "@app/components/v2/SecretPathInput";
|
import { SecretPathInput } from "@app/components/v2/SecretPathInput";
|
||||||
import { useProjectPermission, useProject } from "@app/context";
|
import { useProject, useProjectPermission } from "@app/context";
|
||||||
import {
|
import {
|
||||||
ProjectPermissionSecretSyncActions,
|
ProjectPermissionSecretSyncActions,
|
||||||
ProjectPermissionSub
|
ProjectPermissionSub
|
||||||
|
|||||||
@@ -133,7 +133,7 @@ export const InfisicalSecretInput = forwardRef<HTMLTextAreaElement, Props>(
|
|||||||
const { data: folders } = useGetProjectFolders({
|
const { data: folders } = useGetProjectFolders({
|
||||||
environment: suggestionSource.environment || "",
|
environment: suggestionSource.environment || "",
|
||||||
path: suggestionSource.secretPath || "",
|
path: suggestionSource.secretPath || "",
|
||||||
projectId: projectId,
|
projectId,
|
||||||
options: {
|
options: {
|
||||||
enabled: isPopupOpen
|
enabled: isPopupOpen
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,11 +36,11 @@ export const SecretPathInput = ({
|
|||||||
const [debouncedInputValue] = useDebounce(inputValue, 200);
|
const [debouncedInputValue] = useDebounce(inputValue, 200);
|
||||||
|
|
||||||
const { currentProject } = useProject();
|
const { currentProject } = useProject();
|
||||||
const workspaceId = currentProject?.id || "";
|
const projectId = currentProject?.id || "";
|
||||||
const { folderNames: folders } = useGetFoldersByEnv({
|
const { folderNames: folders } = useGetFoldersByEnv({
|
||||||
path: secretPath,
|
path: secretPath,
|
||||||
environments: [environment || currentProject?.environments?.[0].slug || ""],
|
environments: [environment || currentProject?.environments?.[0].slug || ""],
|
||||||
projectId: workspaceId
|
projectId
|
||||||
});
|
});
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { apiRequest } from "@app/config/request";
|
import { apiRequest } from "@app/config/request";
|
||||||
import { createWorkspace } from "@app/hooks/api/projects/queries";
|
import { createWorkspace } from "@app/hooks/api/projects/queries";
|
||||||
import { ProjectType, ProjectEnv } from "@app/hooks/api/projects/types";
|
import { ProjectEnv, ProjectType } from "@app/hooks/api/projects/types";
|
||||||
|
|
||||||
const secretsToBeAdded = [
|
const secretsToBeAdded = [
|
||||||
{
|
{
|
||||||
@@ -47,8 +47,8 @@ export const initProjectHelper = async ({ projectName }: { projectName: string }
|
|||||||
});
|
});
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const { data } = await apiRequest.post("/api/v3/secrets/batch/raw", {
|
const { data } = await apiRequest.post("/api/v4/secrets/batch", {
|
||||||
workspaceId: project.id,
|
projectId: project.id,
|
||||||
environment: "dev",
|
environment: "dev",
|
||||||
secretPath: "/",
|
secretPath: "/",
|
||||||
secrets: secretsToBeAdded
|
secrets: secretsToBeAdded
|
||||||
|
|||||||
@@ -16,8 +16,8 @@ import {
|
|||||||
export const accessApprovalKeys = {
|
export const accessApprovalKeys = {
|
||||||
getAccessApprovalPolicies: (projectSlug: string) =>
|
getAccessApprovalPolicies: (projectSlug: string) =>
|
||||||
[{ projectSlug }, "access-approval-policies"] as const,
|
[{ projectSlug }, "access-approval-policies"] as const,
|
||||||
getAccessApprovalPolicyOfABoard: (workspaceId: string, environment: string) =>
|
getAccessApprovalPolicyOfABoard: (projectId: string, environment: string) =>
|
||||||
[{ workspaceId, environment }, "access-approval-policy"] as const,
|
[{ projectId, environment }, "access-approval-policy"] as const,
|
||||||
|
|
||||||
getAccessApprovalRequests: (
|
getAccessApprovalRequests: (
|
||||||
projectSlug: string,
|
projectSlug: string,
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { EnforcementLevel, PolicyType } from "../policies/enums";
|
import { EnforcementLevel, PolicyType } from "../policies/enums";
|
||||||
|
import { ProjectEnv } from "../projects/types";
|
||||||
import { TProjectPermission } from "../roles/types";
|
import { TProjectPermission } from "../roles/types";
|
||||||
import { ApprovalStatus } from "../secretApprovalRequest/types";
|
import { ApprovalStatus } from "../secretApprovalRequest/types";
|
||||||
import { ProjectEnv } from "../projects/types";
|
|
||||||
|
|
||||||
export type TAccessApprovalPolicy = {
|
export type TAccessApprovalPolicy = {
|
||||||
id: string;
|
id: string;
|
||||||
|
|||||||
@@ -5,8 +5,8 @@ import { apiRequest } from "@app/config/request";
|
|||||||
import { SessionStorageKeys } from "@app/const";
|
import { SessionStorageKeys } from "@app/const";
|
||||||
|
|
||||||
import { organizationKeys } from "../organization/queries";
|
import { organizationKeys } from "../organization/queries";
|
||||||
import { setAuthToken } from "../reactQuery";
|
|
||||||
import { projectKeys } from "../projects";
|
import { projectKeys } from "../projects";
|
||||||
|
import { setAuthToken } from "../reactQuery";
|
||||||
import {
|
import {
|
||||||
CompleteAccountDTO,
|
CompleteAccountDTO,
|
||||||
CompleteAccountSignupDTO,
|
CompleteAccountSignupDTO,
|
||||||
|
|||||||
@@ -87,7 +87,7 @@ const fetchFolderCommitHistory = async (
|
|||||||
params: {
|
params: {
|
||||||
environment,
|
environment,
|
||||||
path: directory,
|
path: directory,
|
||||||
projectId: projectId,
|
projectId,
|
||||||
offset,
|
offset,
|
||||||
limit,
|
limit,
|
||||||
search,
|
search,
|
||||||
@@ -102,7 +102,7 @@ export const fetchCommitDetails = async (projectId: string, commitId: string) =>
|
|||||||
`/api/v1/pit/commits/${commitId}/changes`,
|
`/api/v1/pit/commits/${commitId}/changes`,
|
||||||
{
|
{
|
||||||
params: {
|
params: {
|
||||||
projectId: projectId
|
projectId
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
@@ -125,7 +125,7 @@ export const fetchRollbackPreview = async (
|
|||||||
environment: envSlug,
|
environment: envSlug,
|
||||||
deepRollback,
|
deepRollback,
|
||||||
secretPath,
|
secretPath,
|
||||||
projectId: projectId
|
projectId
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
@@ -157,7 +157,7 @@ const fetchRevert = async (commitId: string, projectId: string) => {
|
|||||||
const { data } = await apiRequest.post<{ success: boolean; message: string }>(
|
const { data } = await apiRequest.post<{ success: boolean; message: string }>(
|
||||||
`/api/v1/pit/commits/${commitId}/revert`,
|
`/api/v1/pit/commits/${commitId}/revert`,
|
||||||
{
|
{
|
||||||
projectId: projectId
|
projectId
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
return data;
|
return data;
|
||||||
@@ -235,7 +235,7 @@ export const useGetFolderCommitsCount = ({
|
|||||||
}) =>
|
}) =>
|
||||||
useQuery({
|
useQuery({
|
||||||
enabled: Boolean(projectId && environment) && !isPaused,
|
enabled: Boolean(projectId && environment) && !isPaused,
|
||||||
queryKey: commitKeys.count({ projectId: projectId, environment, directory }),
|
queryKey: commitKeys.count({ projectId, environment, directory }),
|
||||||
queryFn: () => fetchFolderCommitsCount({ projectId, environment, directory })
|
queryFn: () => fetchFolderCommitsCount({ projectId, environment, directory })
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { OrderByDirection } from "../generic/types";
|
import { OrderByDirection } from "../generic/types";
|
||||||
import { OrgIdentityOrderBy } from "../organization/types";
|
import { OrgIdentityOrderBy } from "../organization/types";
|
||||||
|
import { Project, ProjectUserMembershipTemporaryMode } from "../projects/types";
|
||||||
import { TOrgRole } from "../roles/types";
|
import { TOrgRole } from "../roles/types";
|
||||||
import { ProjectUserMembershipTemporaryMode, Project } from "../projects/types";
|
|
||||||
import { IdentityAuthMethod, IdentityJwtConfigurationType } from "./enums";
|
import { IdentityAuthMethod, IdentityJwtConfigurationType } from "./enums";
|
||||||
|
|
||||||
export type IdentityTrustedIp = {
|
export type IdentityTrustedIp = {
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
export * from "./admin";
|
|
||||||
export * from "./accessApproval";
|
export * from "./accessApproval";
|
||||||
|
export * from "./admin";
|
||||||
export * from "./apiKeys";
|
export * from "./apiKeys";
|
||||||
export * from "./assumePrivileges";
|
export * from "./assumePrivileges";
|
||||||
export * from "./auditLogs";
|
export * from "./auditLogs";
|
||||||
@@ -28,6 +28,7 @@ export * from "./organization";
|
|||||||
export * from "./pkiAlerts";
|
export * from "./pkiAlerts";
|
||||||
export * from "./pkiCollections";
|
export * from "./pkiCollections";
|
||||||
export * from "./pkiSubscriber";
|
export * from "./pkiSubscriber";
|
||||||
|
export * from "./projects";
|
||||||
export * from "./projectUserAdditionalPrivilege";
|
export * from "./projectUserAdditionalPrivilege";
|
||||||
export * from "./rateLimit";
|
export * from "./rateLimit";
|
||||||
export * from "./roles";
|
export * from "./roles";
|
||||||
@@ -53,4 +54,3 @@ export * from "./trustedIps";
|
|||||||
export * from "./users";
|
export * from "./users";
|
||||||
export * from "./webhooks";
|
export * from "./webhooks";
|
||||||
export * from "./workflowIntegrations";
|
export * from "./workflowIntegrations";
|
||||||
export * from "./projects";
|
|
||||||
|
|||||||
@@ -17,8 +17,8 @@ export {
|
|||||||
useDeleteWsEnvironment,
|
useDeleteWsEnvironment,
|
||||||
useGetProjectSshConfig,
|
useGetProjectSshConfig,
|
||||||
useGetUpgradeProjectStatus,
|
useGetUpgradeProjectStatus,
|
||||||
useGetUserWorkspaceMemberships,
|
|
||||||
useGetUserProjects,
|
useGetUserProjects,
|
||||||
|
useGetUserWorkspaceMemberships,
|
||||||
useGetWorkspaceAuthorizations,
|
useGetWorkspaceAuthorizations,
|
||||||
useGetWorkspaceById,
|
useGetWorkspaceById,
|
||||||
useGetWorkspaceIdentityMembershipDetails,
|
useGetWorkspaceIdentityMembershipDetails,
|
||||||
|
|||||||
@@ -31,6 +31,8 @@ import {
|
|||||||
CreateWorkspaceDTO,
|
CreateWorkspaceDTO,
|
||||||
DeleteEnvironmentDTO,
|
DeleteEnvironmentDTO,
|
||||||
DeleteWorkspaceDTO,
|
DeleteWorkspaceDTO,
|
||||||
|
Project,
|
||||||
|
ProjectEnv,
|
||||||
ProjectIdentityOrderBy,
|
ProjectIdentityOrderBy,
|
||||||
ProjectType,
|
ProjectType,
|
||||||
TGetUpgradeProjectStatusDTO,
|
TGetUpgradeProjectStatusDTO,
|
||||||
@@ -41,9 +43,7 @@ import {
|
|||||||
TUpdateWorkspaceUserRoleDTO,
|
TUpdateWorkspaceUserRoleDTO,
|
||||||
UpdateAuditLogsRetentionDTO,
|
UpdateAuditLogsRetentionDTO,
|
||||||
UpdateEnvironmentDTO,
|
UpdateEnvironmentDTO,
|
||||||
UpdateProjectDTO,
|
UpdateProjectDTO
|
||||||
Project,
|
|
||||||
ProjectEnv
|
|
||||||
} from "./types";
|
} from "./types";
|
||||||
|
|
||||||
export const fetchProjectById = async (projectId: string) => {
|
export const fetchProjectById = async (projectId: string) => {
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
import { TListProjectIdentitiesDTO, TSearchProjectsDTO } from "./types";
|
|
||||||
|
|
||||||
import type { CaStatus } from "../ca";
|
import type { CaStatus } from "../ca";
|
||||||
import { WorkflowIntegrationPlatform } from "../workflowIntegrations/types";
|
import { WorkflowIntegrationPlatform } from "../workflowIntegrations/types";
|
||||||
|
import { TListProjectIdentitiesDTO, TSearchProjectsDTO } from "./types";
|
||||||
|
|
||||||
export const projectKeys = {
|
export const projectKeys = {
|
||||||
getProjectById: (projectId: string) => ["projects", { projectId }] as const,
|
getProjectById: (projectId: string) => ["projects", { projectId }] as const,
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import { SecretV3Raw } from "../secrets/types";
|
|
||||||
import { ProjectEnv } from "../projects/types";
|
import { ProjectEnv } from "../projects/types";
|
||||||
|
import { SecretV3Raw } from "../secrets/types";
|
||||||
|
|
||||||
export type TSecretImport = {
|
export type TSecretImport = {
|
||||||
id: string;
|
id: string;
|
||||||
|
|||||||
@@ -405,14 +405,14 @@ export const useMoveSecrets = ({
|
|||||||
};
|
};
|
||||||
|
|
||||||
export const createSecret = async (dto: TCreateSecretsV3DTO) => {
|
export const createSecret = async (dto: TCreateSecretsV3DTO) => {
|
||||||
const { data } = await apiRequest.post(`/api/v3/secrets/${dto.secretKey}`, dto);
|
const { data } = await apiRequest.post(`/api/v4/secrets/${dto.secretKey}`, dto);
|
||||||
return data;
|
return data;
|
||||||
};
|
};
|
||||||
|
|
||||||
export const useBackfillSecretReference = () =>
|
export const useBackfillSecretReference = () =>
|
||||||
useMutation<{ message: string }, object, { projectId: string }>({
|
useMutation<{ message: string }, object, { projectId: string }>({
|
||||||
mutationFn: async ({ projectId }) => {
|
mutationFn: async ({ projectId }) => {
|
||||||
const { data } = await apiRequest.post("/api/v3/secrets/backfill-secret-references", {
|
const { data } = await apiRequest.post("/api/v4/secrets/backfill-secret-references", {
|
||||||
projectId
|
projectId
|
||||||
});
|
});
|
||||||
return data.message;
|
return data.message;
|
||||||
|
|||||||
@@ -9,11 +9,9 @@ const projectTags = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const fetchWsTag = async (projectID: string) => {
|
const fetchWsTag = async (projectID: string) => {
|
||||||
const { data } = await apiRequest.get<{ projectTags: UserWsTags }>(
|
const { data } = await apiRequest.get<{ tags: UserWsTags }>(`/api/v1/projects/${projectID}/tags`);
|
||||||
`/api/v1/projects/${projectID}/tags`
|
|
||||||
);
|
|
||||||
|
|
||||||
return data.projectTags;
|
return data.tags;
|
||||||
};
|
};
|
||||||
|
|
||||||
export const useGetWsTags = (projectID: string) => {
|
export const useGetWsTags = (projectID: string) => {
|
||||||
@@ -29,14 +27,11 @@ export const useCreateWsTag = () => {
|
|||||||
|
|
||||||
return useMutation<WsTag, object, CreateTagDTO>({
|
return useMutation<WsTag, object, CreateTagDTO>({
|
||||||
mutationFn: async ({ projectId: projectID, tagColor, tagSlug }) => {
|
mutationFn: async ({ projectId: projectID, tagColor, tagSlug }) => {
|
||||||
const { data } = await apiRequest.post<{ projectTag: WsTag }>(
|
const { data } = await apiRequest.post<{ tag: WsTag }>(`/api/v1/projects/${projectID}/tags`, {
|
||||||
`/api/v1/projects/${projectID}/tags`,
|
color: tagColor || "",
|
||||||
{
|
slug: tagSlug
|
||||||
color: tagColor || "",
|
});
|
||||||
slug: tagSlug
|
return data.tag;
|
||||||
}
|
|
||||||
);
|
|
||||||
return data.projectTag;
|
|
||||||
},
|
},
|
||||||
onSuccess: (tagData) => {
|
onSuccess: (tagData) => {
|
||||||
queryClient.invalidateQueries({ queryKey: projectTags.getWsTags(tagData?.projectId) });
|
queryClient.invalidateQueries({ queryKey: projectTags.getWsTags(tagData?.projectId) });
|
||||||
@@ -49,10 +44,10 @@ export const useDeleteWsTag = () => {
|
|||||||
|
|
||||||
return useMutation<WsTag, object, DeleteTagDTO>({
|
return useMutation<WsTag, object, DeleteTagDTO>({
|
||||||
mutationFn: async ({ tagID, projectId }) => {
|
mutationFn: async ({ tagID, projectId }) => {
|
||||||
const { data } = await apiRequest.delete<{ projectTag: WsTag }>(
|
const { data } = await apiRequest.delete<{ tag: WsTag }>(
|
||||||
`/api/v1/projects/${projectId}/tags/${tagID}`
|
`/api/v1/projects/${projectId}/tags/${tagID}`
|
||||||
);
|
);
|
||||||
return data.projectTag;
|
return data.tag;
|
||||||
},
|
},
|
||||||
onSuccess: (tagData) => {
|
onSuccess: (tagData) => {
|
||||||
queryClient.invalidateQueries({ queryKey: projectTags.getWsTags(tagData?.projectId) });
|
queryClient.invalidateQueries({ queryKey: projectTags.getWsTags(tagData?.projectId) });
|
||||||
|
|||||||
@@ -8,6 +8,18 @@ export type { IncidentContact } from "./incidentContacts/types";
|
|||||||
export type { IntegrationAuth } from "./integrationAuth/types";
|
export type { IntegrationAuth } from "./integrationAuth/types";
|
||||||
export type { TCloudIntegration, TIntegration } from "./integrations/types";
|
export type { TCloudIntegration, TIntegration } from "./integrations/types";
|
||||||
export type { Organization } from "./organization/types";
|
export type { Organization } from "./organization/types";
|
||||||
|
export type {
|
||||||
|
CreateEnvironmentDTO,
|
||||||
|
CreateWorkspaceDTO,
|
||||||
|
DeleteEnvironmentDTO,
|
||||||
|
DeleteWorkspaceDTO,
|
||||||
|
Project,
|
||||||
|
ProjectEnv,
|
||||||
|
ProjectTag,
|
||||||
|
ToggleAutoCapitalizationDTO,
|
||||||
|
UpdateEnvironmentDTO,
|
||||||
|
UpdateProjectDTO
|
||||||
|
} from "./projects/types";
|
||||||
export type { TSecretApprovalPolicy } from "./secretApproval/types";
|
export type { TSecretApprovalPolicy } from "./secretApproval/types";
|
||||||
export type {
|
export type {
|
||||||
TGetSecretApprovalRequestDetails,
|
TGetSecretApprovalRequestDetails,
|
||||||
@@ -28,18 +40,6 @@ export type { SubscriptionPlan } from "./subscriptions/types";
|
|||||||
export type { WsTag } from "./tags/types";
|
export type { WsTag } from "./tags/types";
|
||||||
export type { OrgUser, TWorkspaceUser, User, UserEnc } from "./users/types";
|
export type { OrgUser, TWorkspaceUser, User, UserEnc } from "./users/types";
|
||||||
export type { TWebhook } from "./webhooks/types";
|
export type { TWebhook } from "./webhooks/types";
|
||||||
export type {
|
|
||||||
CreateEnvironmentDTO,
|
|
||||||
CreateWorkspaceDTO,
|
|
||||||
DeleteEnvironmentDTO,
|
|
||||||
DeleteWorkspaceDTO,
|
|
||||||
ToggleAutoCapitalizationDTO,
|
|
||||||
UpdateEnvironmentDTO,
|
|
||||||
UpdateProjectDTO,
|
|
||||||
Project,
|
|
||||||
ProjectEnv,
|
|
||||||
ProjectTag
|
|
||||||
} from "./projects/types";
|
|
||||||
|
|
||||||
export enum ApiErrorTypes {
|
export enum ApiErrorTypes {
|
||||||
ValidationError = "ValidationFailure",
|
ValidationError = "ValidationFailure",
|
||||||
|
|||||||
@@ -8,9 +8,9 @@ import { queryClient as qc } from "@app/hooks/api/reactQuery";
|
|||||||
import { APIKeyDataV2 } from "../apiKeys/types";
|
import { APIKeyDataV2 } from "../apiKeys/types";
|
||||||
import { MfaMethod } from "../auth/types";
|
import { MfaMethod } from "../auth/types";
|
||||||
import { TGroupWithProjectMemberships } from "../groups/types";
|
import { TGroupWithProjectMemberships } from "../groups/types";
|
||||||
|
import { projectKeys } from "../projects";
|
||||||
import { setAuthToken } from "../reactQuery";
|
import { setAuthToken } from "../reactQuery";
|
||||||
import { subscriptionQueryKeys } from "../subscriptions/queries";
|
import { subscriptionQueryKeys } from "../subscriptions/queries";
|
||||||
import { projectKeys } from "../projects";
|
|
||||||
import { userKeys } from "./query-keys";
|
import { userKeys } from "./query-keys";
|
||||||
import {
|
import {
|
||||||
AddUserToOrgDTO,
|
AddUserToOrgDTO,
|
||||||
|
|||||||
@@ -8,19 +8,19 @@ export const queryKeys = {
|
|||||||
getWebhooks: (workspaceId: string) => ["webhooks", { workspaceId }]
|
getWebhooks: (workspaceId: string) => ["webhooks", { workspaceId }]
|
||||||
};
|
};
|
||||||
|
|
||||||
const fetchWebhooks = async (workspaceId: string) => {
|
const fetchWebhooks = async (projectId: string) => {
|
||||||
const { data } = await apiRequest.get<{ webhooks: TWebhook[] }>("/api/v1/webhooks", {
|
const { data } = await apiRequest.get<{ webhooks: TWebhook[] }>("/api/v1/webhooks", {
|
||||||
params: {
|
params: {
|
||||||
workspaceId
|
projectId
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
return data.webhooks;
|
return data.webhooks;
|
||||||
};
|
};
|
||||||
|
|
||||||
export const useGetWebhooks = (workspaceId: string) =>
|
export const useGetWebhooks = (projectId: string) =>
|
||||||
useQuery({
|
useQuery({
|
||||||
queryKey: queryKeys.getWebhooks(workspaceId),
|
queryKey: queryKeys.getWebhooks(projectId),
|
||||||
queryFn: () => fetchWebhooks(workspaceId),
|
queryFn: () => fetchWebhooks(projectId),
|
||||||
enabled: Boolean(workspaceId)
|
enabled: Boolean(projectId)
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { useMemo } from "react";
|
import { useMemo } from "react";
|
||||||
|
|
||||||
import { useSubscription, useProject } from "@app/context";
|
import { useProject, useSubscription } from "@app/context";
|
||||||
import { useGetAccessApprovalPolicies } from "@app/hooks/api";
|
import { useGetAccessApprovalPolicies } from "@app/hooks/api";
|
||||||
|
|
||||||
const matchesPath = (folderPath: string, pattern: string) => {
|
const matchesPath = (folderPath: string, pattern: string) => {
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ import { Link, Outlet } from "@tanstack/react-router";
|
|||||||
import { motion } from "framer-motion";
|
import { motion } from "framer-motion";
|
||||||
|
|
||||||
import { Lottie, Menu, MenuGroup, MenuItem } from "@app/components/v2";
|
import { Lottie, Menu, MenuGroup, MenuItem } from "@app/components/v2";
|
||||||
import { useProjectPermission, useProject } from "@app/context";
|
import { useProject, useProjectPermission } from "@app/context";
|
||||||
|
|
||||||
import { AssumePrivilegeModeBanner } from "../ProjectLayout/components/AssumePrivilegeModeBanner";
|
import { AssumePrivilegeModeBanner } from "../ProjectLayout/components/AssumePrivilegeModeBanner";
|
||||||
|
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ import { envConfig } from "@app/config/env";
|
|||||||
import { useOrganization, useSubscription, useUser } from "@app/context";
|
import { useOrganization, useSubscription, useUser } from "@app/context";
|
||||||
import { isInfisicalCloud } from "@app/helpers/platform";
|
import { isInfisicalCloud } from "@app/helpers/platform";
|
||||||
import { useToggle } from "@app/hooks";
|
import { useToggle } from "@app/hooks";
|
||||||
import { useGetOrganizations, useLogoutUser, projectKeys } from "@app/hooks/api";
|
import { projectKeys, useGetOrganizations, useLogoutUser } from "@app/hooks/api";
|
||||||
import { authKeys, selectOrganization } from "@app/hooks/api/auth/queries";
|
import { authKeys, selectOrganization } from "@app/hooks/api/auth/queries";
|
||||||
import { MfaMethod } from "@app/hooks/api/auth/types";
|
import { MfaMethod } from "@app/hooks/api/auth/types";
|
||||||
import { getAuthToken } from "@app/hooks/api/reactQuery";
|
import { getAuthToken } from "@app/hooks/api/reactQuery";
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ import { Link, Outlet } from "@tanstack/react-router";
|
|||||||
import { motion } from "framer-motion";
|
import { motion } from "framer-motion";
|
||||||
|
|
||||||
import { Lottie, Menu, MenuGroup, MenuItem } from "@app/components/v2";
|
import { Lottie, Menu, MenuGroup, MenuItem } from "@app/components/v2";
|
||||||
import { useProjectPermission, useProject } from "@app/context";
|
import { useProject, useProjectPermission } from "@app/context";
|
||||||
|
|
||||||
import { AssumePrivilegeModeBanner } from "../ProjectLayout/components/AssumePrivilegeModeBanner";
|
import { AssumePrivilegeModeBanner } from "../ProjectLayout/components/AssumePrivilegeModeBanner";
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -2,7 +2,7 @@ import { faInfoCircle } from "@fortawesome/free-solid-svg-icons";
|
|||||||
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
||||||
|
|
||||||
import { Button } from "@app/components/v2";
|
import { Button } from "@app/components/v2";
|
||||||
import { useProjectPermission, useProject } from "@app/context";
|
import { useProject, useProjectPermission } from "@app/context";
|
||||||
import { getProjectHomePage } from "@app/helpers/project";
|
import { getProjectHomePage } from "@app/helpers/project";
|
||||||
import { useRemoveAssumeProjectPrivilege } from "@app/hooks/api";
|
import { useRemoveAssumeProjectPrivilege } from "@app/hooks/api";
|
||||||
import { ActorType } from "@app/hooks/api/auditLogs/enums";
|
import { ActorType } from "@app/hooks/api/auditLogs/enums";
|
||||||
|
|||||||
@@ -28,15 +28,15 @@ import {
|
|||||||
OrgPermissionActions,
|
OrgPermissionActions,
|
||||||
OrgPermissionSubjects,
|
OrgPermissionSubjects,
|
||||||
useOrganization,
|
useOrganization,
|
||||||
useSubscription,
|
useProject,
|
||||||
useProject
|
useSubscription
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { getProjectHomePage } from "@app/helpers/project";
|
import { getProjectHomePage } from "@app/helpers/project";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { useGetUserProjects } from "@app/hooks/api";
|
import { useGetUserProjects } from "@app/hooks/api";
|
||||||
|
import { Project } from "@app/hooks/api/projects/types";
|
||||||
import { useUpdateUserProjectFavorites } from "@app/hooks/api/users/mutation";
|
import { useUpdateUserProjectFavorites } from "@app/hooks/api/users/mutation";
|
||||||
import { useGetUserProjectFavorites } from "@app/hooks/api/users/queries";
|
import { useGetUserProjectFavorites } from "@app/hooks/api/users/queries";
|
||||||
import { Project } from "@app/hooks/api/projects/types";
|
|
||||||
|
|
||||||
export const ProjectSelect = () => {
|
export const ProjectSelect = () => {
|
||||||
const [searchProject, setSearchProject] = useState("");
|
const [searchProject, setSearchProject] = useState("");
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ import { Link, Outlet, useLocation } from "@tanstack/react-router";
|
|||||||
import { motion } from "framer-motion";
|
import { motion } from "framer-motion";
|
||||||
|
|
||||||
import { Badge, Lottie, Menu, MenuGroup, MenuItem } from "@app/components/v2";
|
import { Badge, Lottie, Menu, MenuGroup, MenuItem } from "@app/components/v2";
|
||||||
import { useProjectPermission, useProject } from "@app/context";
|
import { useProject, useProjectPermission } from "@app/context";
|
||||||
import {
|
import {
|
||||||
useGetAccessRequestsCount,
|
useGetAccessRequestsCount,
|
||||||
useGetSecretApprovalRequestCount,
|
useGetSecretApprovalRequestCount,
|
||||||
|
|||||||
@@ -13,9 +13,9 @@ import { motion } from "framer-motion";
|
|||||||
import { Badge, Lottie, Menu, MenuGroup, MenuItem } from "@app/components/v2";
|
import { Badge, Lottie, Menu, MenuGroup, MenuItem } from "@app/components/v2";
|
||||||
import {
|
import {
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
|
useProject,
|
||||||
useProjectPermission,
|
useProjectPermission,
|
||||||
useSubscription,
|
useSubscription
|
||||||
useProject
|
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { ProjectPermissionSecretScanningFindingActions } from "@app/context/ProjectPermissionContext/types";
|
import { ProjectPermissionSecretScanningFindingActions } from "@app/context/ProjectPermissionContext/types";
|
||||||
import { useGetSecretScanningUnresolvedFindingCount } from "@app/hooks/api/secretScanningV2";
|
import { useGetSecretScanningUnresolvedFindingCount } from "@app/hooks/api/secretScanningV2";
|
||||||
|
|||||||
@@ -15,8 +15,8 @@ import { Lottie, Menu, MenuGroup, MenuItem } from "@app/components/v2";
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
|
|
||||||
import { AssumePrivilegeModeBanner } from "../ProjectLayout/components/AssumePrivilegeModeBanner";
|
import { AssumePrivilegeModeBanner } from "../ProjectLayout/components/AssumePrivilegeModeBanner";
|
||||||
|
|||||||
+2
-2
@@ -27,8 +27,8 @@ import {
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionPkiSubscriberActions,
|
ProjectPermissionPkiSubscriberActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { useGetPkiSubscriberCertificates } from "@app/hooks/api";
|
import { useGetPkiSubscriberCertificates } from "@app/hooks/api";
|
||||||
import { caSupportsCapability } from "@app/hooks/api/ca/constants";
|
import { caSupportsCapability } from "@app/hooks/api/ca/constants";
|
||||||
|
|||||||
+2
-2
@@ -16,8 +16,8 @@ import {
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionPkiSubscriberActions,
|
ProjectPermissionPkiSubscriberActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { useTimedReset } from "@app/hooks";
|
import { useTimedReset } from "@app/hooks";
|
||||||
import {
|
import {
|
||||||
|
|||||||
@@ -42,8 +42,8 @@ import {
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionPkiTemplateActions,
|
ProjectPermissionPkiTemplateActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useSubscription,
|
useProject,
|
||||||
useProject
|
useSubscription
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { useDeleteCertTemplateV2 } from "@app/hooks/api";
|
import { useDeleteCertTemplateV2 } from "@app/hooks/api";
|
||||||
|
|||||||
@@ -2,8 +2,8 @@ import { createFileRoute } from "@tanstack/react-router";
|
|||||||
|
|
||||||
import { BreadcrumbTypes } from "@app/components/v2";
|
import { BreadcrumbTypes } from "@app/components/v2";
|
||||||
import { projectKeys } from "@app/hooks/api";
|
import { projectKeys } from "@app/hooks/api";
|
||||||
import { fetchUserProjectPermissions, roleQueryKeys } from "@app/hooks/api/roles/queries";
|
|
||||||
import { fetchProjectById } from "@app/hooks/api/projects/queries";
|
import { fetchProjectById } from "@app/hooks/api/projects/queries";
|
||||||
|
import { fetchUserProjectPermissions, roleQueryKeys } from "@app/hooks/api/roles/queries";
|
||||||
import { PkiManagerLayout } from "@app/layouts/PkiManagerLayout";
|
import { PkiManagerLayout } from "@app/layouts/PkiManagerLayout";
|
||||||
import { ProjectSelect } from "@app/layouts/ProjectLayout/components/ProjectSelect";
|
import { ProjectSelect } from "@app/layouts/ProjectLayout/components/ProjectSelect";
|
||||||
|
|
||||||
|
|||||||
@@ -39,9 +39,9 @@ import {
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionKmipActions,
|
ProjectPermissionKmipActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
|
useProject,
|
||||||
useProjectPermission,
|
useProjectPermission,
|
||||||
useSubscription,
|
useSubscription
|
||||||
useProject
|
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import {
|
import {
|
||||||
getUserTablePreference,
|
getUserTablePreference,
|
||||||
|
|||||||
@@ -49,8 +49,8 @@ import {
|
|||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionCmekActions,
|
ProjectPermissionCmekActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { kmsKeyUsageOptions } from "@app/helpers/kms";
|
import { kmsKeyUsageOptions } from "@app/helpers/kms";
|
||||||
import {
|
import {
|
||||||
|
|||||||
@@ -2,8 +2,8 @@ import { createFileRoute } from "@tanstack/react-router";
|
|||||||
|
|
||||||
import { BreadcrumbTypes } from "@app/components/v2";
|
import { BreadcrumbTypes } from "@app/components/v2";
|
||||||
import { projectKeys } from "@app/hooks/api";
|
import { projectKeys } from "@app/hooks/api";
|
||||||
import { fetchUserProjectPermissions, roleQueryKeys } from "@app/hooks/api/roles/queries";
|
|
||||||
import { fetchProjectById } from "@app/hooks/api/projects/queries";
|
import { fetchProjectById } from "@app/hooks/api/projects/queries";
|
||||||
|
import { fetchUserProjectPermissions, roleQueryKeys } from "@app/hooks/api/roles/queries";
|
||||||
import { KmsLayout } from "@app/layouts/KmsLayout";
|
import { KmsLayout } from "@app/layouts/KmsLayout";
|
||||||
import { ProjectSelect } from "@app/layouts/ProjectLayout/components/ProjectSelect";
|
import { ProjectSelect } from "@app/layouts/ProjectLayout/components/ProjectSelect";
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -23,8 +23,8 @@ import {
|
|||||||
useGetOrgRoles,
|
useGetOrgRoles,
|
||||||
useGetUserProjects
|
useGetUserProjects
|
||||||
} from "@app/hooks/api";
|
} from "@app/hooks/api";
|
||||||
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
|
||||||
import { ProjectType, ProjectVersion } from "@app/hooks/api/projects/types";
|
import { ProjectType, ProjectVersion } from "@app/hooks/api/projects/types";
|
||||||
|
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
||||||
import { UsePopUpState } from "@app/hooks/usePopUp";
|
import { UsePopUpState } from "@app/hooks/usePopUp";
|
||||||
|
|
||||||
import { OrgInviteLink } from "./OrgInviteLink";
|
import { OrgInviteLink } from "./OrgInviteLink";
|
||||||
|
|||||||
+1
-1
@@ -25,7 +25,7 @@ export const IdentityProjectsSection = ({ identityId }: Props) => {
|
|||||||
try {
|
try {
|
||||||
await deleteMutateAsync({
|
await deleteMutateAsync({
|
||||||
identityId: id,
|
identityId: id,
|
||||||
projectId: projectId
|
projectId
|
||||||
});
|
});
|
||||||
|
|
||||||
createNotification({
|
createNotification({
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ import {
|
|||||||
useRequestProjectAccess,
|
useRequestProjectAccess,
|
||||||
useSearchProjects
|
useSearchProjects
|
||||||
} from "@app/hooks/api";
|
} from "@app/hooks/api";
|
||||||
import { ProjectType, Project, ProjectEnv } from "@app/hooks/api/projects/types";
|
import { Project, ProjectEnv, ProjectType } from "@app/hooks/api/projects/types";
|
||||||
import {
|
import {
|
||||||
ProjectListToggle,
|
ProjectListToggle,
|
||||||
ProjectListView
|
ProjectListView
|
||||||
|
|||||||
@@ -41,9 +41,9 @@ import {
|
|||||||
import { usePagination, useResetPageHelper } from "@app/hooks";
|
import { usePagination, useResetPageHelper } from "@app/hooks";
|
||||||
import { useGetUserProjects } from "@app/hooks/api";
|
import { useGetUserProjects } from "@app/hooks/api";
|
||||||
import { OrderByDirection } from "@app/hooks/api/generic/types";
|
import { OrderByDirection } from "@app/hooks/api/generic/types";
|
||||||
|
import { Project, ProjectType } from "@app/hooks/api/projects/types";
|
||||||
import { useUpdateUserProjectFavorites } from "@app/hooks/api/users/mutation";
|
import { useUpdateUserProjectFavorites } from "@app/hooks/api/users/mutation";
|
||||||
import { useGetUserProjectFavorites } from "@app/hooks/api/users/queries";
|
import { useGetUserProjectFavorites } from "@app/hooks/api/users/queries";
|
||||||
import { ProjectType, Project } from "@app/hooks/api/projects/types";
|
|
||||||
import {
|
import {
|
||||||
ProjectListToggle,
|
ProjectListToggle,
|
||||||
ProjectListView
|
ProjectListView
|
||||||
|
|||||||
+1
-1
@@ -7,8 +7,8 @@ import { Button, DeleteActionModal } from "@app/components/v2";
|
|||||||
import { OrgPermissionActions, OrgPermissionSubjects } from "@app/context";
|
import { OrgPermissionActions, OrgPermissionSubjects } from "@app/context";
|
||||||
import { getProjectTitle } from "@app/helpers/project";
|
import { getProjectTitle } from "@app/helpers/project";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { TProjectTemplate, useDeleteProjectTemplate } from "@app/hooks/api/projectTemplates";
|
|
||||||
import { ProjectType } from "@app/hooks/api/projects/types";
|
import { ProjectType } from "@app/hooks/api/projects/types";
|
||||||
|
import { TProjectTemplate, useDeleteProjectTemplate } from "@app/hooks/api/projectTemplates";
|
||||||
|
|
||||||
import { ProjectTemplateDetailsModal } from "../../ProjectTemplateDetailsModal";
|
import { ProjectTemplateDetailsModal } from "../../ProjectTemplateDetailsModal";
|
||||||
import { ProjectTemplateEnvironmentsForm } from "./ProjectTemplateEnvironmentsForm";
|
import { ProjectTemplateEnvironmentsForm } from "./ProjectTemplateEnvironmentsForm";
|
||||||
|
|||||||
+1
-1
@@ -15,12 +15,12 @@ import {
|
|||||||
TextArea
|
TextArea
|
||||||
} from "@app/components/v2";
|
} from "@app/components/v2";
|
||||||
import { getProjectLottieIcon } from "@app/helpers/project";
|
import { getProjectLottieIcon } from "@app/helpers/project";
|
||||||
|
import { ProjectType } from "@app/hooks/api/projects/types";
|
||||||
import {
|
import {
|
||||||
TProjectTemplate,
|
TProjectTemplate,
|
||||||
useCreateProjectTemplate,
|
useCreateProjectTemplate,
|
||||||
useUpdateProjectTemplate
|
useUpdateProjectTemplate
|
||||||
} from "@app/hooks/api/projectTemplates";
|
} from "@app/hooks/api/projectTemplates";
|
||||||
import { ProjectType } from "@app/hooks/api/projects/types";
|
|
||||||
import { slugSchema } from "@app/lib/schemas";
|
import { slugSchema } from "@app/lib/schemas";
|
||||||
|
|
||||||
const formSchema = z.object({
|
const formSchema = z.object({
|
||||||
|
|||||||
+1
-1
@@ -29,8 +29,8 @@ import { formatProjectRoleName } from "@app/helpers/roles";
|
|||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { useGetProjectRoles, useUpdateGroupWorkspaceRole } from "@app/hooks/api";
|
import { useGetProjectRoles, useUpdateGroupWorkspaceRole } from "@app/hooks/api";
|
||||||
import { TGroupMembership } from "@app/hooks/api/groups/types";
|
import { TGroupMembership } from "@app/hooks/api/groups/types";
|
||||||
import { TProjectRole } from "@app/hooks/api/roles/types";
|
|
||||||
import { ProjectUserMembershipTemporaryMode } from "@app/hooks/api/projects/types";
|
import { ProjectUserMembershipTemporaryMode } from "@app/hooks/api/projects/types";
|
||||||
|
import { TProjectRole } from "@app/hooks/api/roles/types";
|
||||||
import { groupBy } from "@app/lib/fn/array";
|
import { groupBy } from "@app/lib/fn/array";
|
||||||
|
|
||||||
const temporaryRoleFormSchema = z.object({
|
const temporaryRoleFormSchema = z.object({
|
||||||
|
|||||||
+2
-2
@@ -8,8 +8,8 @@ import { Button, DeleteActionModal } from "@app/components/v2";
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useSubscription,
|
useProject,
|
||||||
useProject
|
useSubscription
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { useDeleteGroupFromWorkspace } from "@app/hooks/api";
|
import { useDeleteGroupFromWorkspace } from "@app/hooks/api";
|
||||||
|
|||||||
+3
-3
@@ -30,8 +30,8 @@ import {
|
|||||||
useGetProjectRoles,
|
useGetProjectRoles,
|
||||||
useGetWorkspaceUsers
|
useGetWorkspaceUsers
|
||||||
} from "@app/hooks/api";
|
} from "@app/hooks/api";
|
||||||
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
|
||||||
import { ProjectVersion } from "@app/hooks/api/projects/types";
|
import { ProjectVersion } from "@app/hooks/api/projects/types";
|
||||||
|
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
||||||
import { UsePopUpState } from "@app/hooks/usePopUp";
|
import { UsePopUpState } from "@app/hooks/usePopUp";
|
||||||
|
|
||||||
const addMemberFormSchema = z.object({
|
const addMemberFormSchema = z.object({
|
||||||
@@ -66,9 +66,9 @@ export const AddMemberModal = ({ popUp, handlePopUpToggle }: Props) => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
const orgId = currentOrg?.id || "";
|
const orgId = currentOrg?.id || "";
|
||||||
const workspaceId = currentProject?.id || "";
|
const projectId = currentProject?.id || "";
|
||||||
|
|
||||||
const { data: members } = useGetWorkspaceUsers(workspaceId);
|
const { data: members } = useGetWorkspaceUsers(projectId);
|
||||||
const { data: orgUsers } = useGetOrgUsers(orgId);
|
const { data: orgUsers } = useGetOrgUsers(orgId);
|
||||||
|
|
||||||
const { data: roles } = useGetProjectRoles(currentProject?.id || "");
|
const { data: roles } = useGetProjectRoles(currentProject?.id || "");
|
||||||
|
|||||||
+3
-3
@@ -29,14 +29,14 @@ import {
|
|||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionMemberActions,
|
ProjectPermissionMemberActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
|
useProject,
|
||||||
useProjectPermission,
|
useProjectPermission,
|
||||||
useSubscription,
|
useSubscription
|
||||||
useProject
|
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { useGetProjectRoles, useUpdateUserWorkspaceRole } from "@app/hooks/api";
|
import { useGetProjectRoles, useUpdateUserWorkspaceRole } from "@app/hooks/api";
|
||||||
|
import { ProjectUserMembershipTemporaryMode } from "@app/hooks/api/projects/types";
|
||||||
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
||||||
import { TWorkspaceUser } from "@app/hooks/api/types";
|
import { TWorkspaceUser } from "@app/hooks/api/types";
|
||||||
import { ProjectUserMembershipTemporaryMode } from "@app/hooks/api/projects/types";
|
|
||||||
|
|
||||||
const roleFormSchema = z.object({
|
const roleFormSchema = z.object({
|
||||||
roles: z
|
roles: z
|
||||||
|
|||||||
+2
-2
@@ -43,8 +43,8 @@ import {
|
|||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionMemberActions,
|
ProjectPermissionMemberActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { removeTrailingSlash } from "@app/helpers/string";
|
import { removeTrailingSlash } from "@app/helpers/string";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
|
|||||||
+6
-6
@@ -44,7 +44,7 @@ import {
|
|||||||
Tooltip,
|
Tooltip,
|
||||||
Tr
|
Tr
|
||||||
} from "@app/components/v2";
|
} from "@app/components/v2";
|
||||||
import { ProjectPermissionActions, ProjectPermissionSub, useUser, useProject } from "@app/context";
|
import { ProjectPermissionActions, ProjectPermissionSub, useProject, useUser } from "@app/context";
|
||||||
import { getProjectBaseURL } from "@app/helpers/project";
|
import { getProjectBaseURL } from "@app/helpers/project";
|
||||||
import { formatProjectRoleName } from "@app/helpers/roles";
|
import { formatProjectRoleName } from "@app/helpers/roles";
|
||||||
import {
|
import {
|
||||||
@@ -85,8 +85,8 @@ export const MembersTable = ({ handlePopUpOpen }: Props) => {
|
|||||||
const filterRoles = useMemo(() => filter.roles, [filter.roles]);
|
const filterRoles = useMemo(() => filter.roles, [filter.roles]);
|
||||||
|
|
||||||
const userId = user?.id || "";
|
const userId = user?.id || "";
|
||||||
const workspaceId = currentProject?.id || "";
|
const projectId = currentProject?.id || "";
|
||||||
const { data: projectRoles } = useGetProjectRoles(workspaceId);
|
const { data: projectRoles } = useGetProjectRoles(projectId);
|
||||||
|
|
||||||
const {
|
const {
|
||||||
search,
|
search,
|
||||||
@@ -111,7 +111,7 @@ export const MembersTable = ({ handlePopUpOpen }: Props) => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const { data: members = [], isPending: isMembersLoading } = useGetWorkspaceUsers(
|
const { data: members = [], isPending: isMembersLoading } = useGetWorkspaceUsers(
|
||||||
workspaceId,
|
projectId,
|
||||||
undefined,
|
undefined,
|
||||||
filterRoles
|
filterRoles
|
||||||
);
|
);
|
||||||
@@ -309,7 +309,7 @@ export const MembersTable = ({ handlePopUpOpen }: Props) => {
|
|||||||
navigate({
|
navigate({
|
||||||
to: `${getProjectBaseURL(currentProject.type)}/members/$membershipId`,
|
to: `${getProjectBaseURL(currentProject.type)}/members/$membershipId`,
|
||||||
params: {
|
params: {
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
membershipId
|
membershipId
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -319,7 +319,7 @@ export const MembersTable = ({ handlePopUpOpen }: Props) => {
|
|||||||
navigate({
|
navigate({
|
||||||
to: `${getProjectBaseURL(currentProject.type)}/members/$membershipId`,
|
to: `${getProjectBaseURL(currentProject.type)}/members/$membershipId`,
|
||||||
params: {
|
params: {
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
membershipId
|
membershipId
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ const Page = () => {
|
|||||||
{
|
{
|
||||||
actorId: identityId,
|
actorId: identityId,
|
||||||
actorType: ActorType.IDENTITY,
|
actorType: ActorType.IDENTITY,
|
||||||
projectId: projectId
|
projectId
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
onSuccess: () => {
|
onSuccess: () => {
|
||||||
@@ -86,7 +86,7 @@ const Page = () => {
|
|||||||
navigate({
|
navigate({
|
||||||
to: `${getProjectBaseURL(currentProject.type)}/access-management` as const,
|
to: `${getProjectBaseURL(currentProject.type)}/access-management` as const,
|
||||||
params: {
|
params: {
|
||||||
projectId: projectId
|
projectId
|
||||||
},
|
},
|
||||||
search: {
|
search: {
|
||||||
selectedTab: "identities"
|
selectedTab: "identities"
|
||||||
|
|||||||
+2
-2
@@ -24,8 +24,8 @@ import {
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionIdentityActions,
|
ProjectPermissionIdentityActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import {
|
import {
|
||||||
useCreateIdentityProjectAdditionalPrivilege,
|
useCreateIdentityProjectAdditionalPrivilege,
|
||||||
|
|||||||
+3
-3
@@ -29,13 +29,13 @@ import {
|
|||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionIdentityActions,
|
ProjectPermissionIdentityActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { useGetProjectRoles, useUpdateIdentityWorkspaceRole } from "@app/hooks/api";
|
import { useGetProjectRoles, useUpdateIdentityWorkspaceRole } from "@app/hooks/api";
|
||||||
import { IdentityMembership } from "@app/hooks/api/identities/types";
|
import { IdentityMembership } from "@app/hooks/api/identities/types";
|
||||||
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
|
||||||
import { ProjectUserMembershipTemporaryMode } from "@app/hooks/api/projects/types";
|
import { ProjectUserMembershipTemporaryMode } from "@app/hooks/api/projects/types";
|
||||||
|
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
||||||
|
|
||||||
const roleFormSchema = z.object({
|
const roleFormSchema = z.object({
|
||||||
roles: z
|
roles: z
|
||||||
|
|||||||
+2
-2
@@ -23,8 +23,8 @@ import {
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionMemberActions,
|
ProjectPermissionMemberActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import {
|
import {
|
||||||
useCreateProjectUserAdditionalPrivilege,
|
useCreateProjectUserAdditionalPrivilege,
|
||||||
|
|||||||
+1
-1
@@ -22,7 +22,7 @@ import {
|
|||||||
Tooltip,
|
Tooltip,
|
||||||
Tr
|
Tr
|
||||||
} from "@app/components/v2";
|
} from "@app/components/v2";
|
||||||
import { ProjectPermissionActions, ProjectPermissionSub, useUser, useProject } from "@app/context";
|
import { ProjectPermissionActions, ProjectPermissionSub, useProject, useUser } from "@app/context";
|
||||||
import { formatProjectRoleName } from "@app/helpers/roles";
|
import { formatProjectRoleName } from "@app/helpers/roles";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { useUpdateUserWorkspaceRole } from "@app/hooks/api";
|
import { useUpdateUserWorkspaceRole } from "@app/hooks/api";
|
||||||
|
|||||||
+3
-3
@@ -29,14 +29,14 @@ import {
|
|||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionMemberActions,
|
ProjectPermissionMemberActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
|
useProject,
|
||||||
useProjectPermission,
|
useProjectPermission,
|
||||||
useSubscription,
|
useSubscription
|
||||||
useProject
|
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { useGetProjectRoles, useUpdateUserWorkspaceRole } from "@app/hooks/api";
|
import { useGetProjectRoles, useUpdateUserWorkspaceRole } from "@app/hooks/api";
|
||||||
|
import { ProjectUserMembershipTemporaryMode } from "@app/hooks/api/projects/types";
|
||||||
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
||||||
import { TWorkspaceUser } from "@app/hooks/api/types";
|
import { TWorkspaceUser } from "@app/hooks/api/types";
|
||||||
import { ProjectUserMembershipTemporaryMode } from "@app/hooks/api/projects/types";
|
|
||||||
|
|
||||||
const roleFormSchema = z.object({
|
const roleFormSchema = z.object({
|
||||||
roles: z
|
roles: z
|
||||||
|
|||||||
+1
-1
@@ -32,8 +32,8 @@ import {
|
|||||||
TPermissionCondition,
|
TPermissionCondition,
|
||||||
TPermissionConditionOperators
|
TPermissionConditionOperators
|
||||||
} from "@app/context/ProjectPermissionContext/types";
|
} from "@app/context/ProjectPermissionContext/types";
|
||||||
import { TProjectPermission } from "@app/hooks/api/roles/types";
|
|
||||||
import { ProjectType } from "@app/hooks/api/projects/types";
|
import { ProjectType } from "@app/hooks/api/projects/types";
|
||||||
|
import { TProjectPermission } from "@app/hooks/api/roles/types";
|
||||||
|
|
||||||
const GeneralPolicyActionSchema = z.object({
|
const GeneralPolicyActionSchema = z.object({
|
||||||
read: z.boolean().optional(),
|
read: z.boolean().optional(),
|
||||||
|
|||||||
+1
-1
@@ -12,8 +12,8 @@ import { ProjectPermissionSub, useProject } from "@app/context";
|
|||||||
import { ProjectPermissionSet } from "@app/context/ProjectPermissionContext";
|
import { ProjectPermissionSet } from "@app/context/ProjectPermissionContext";
|
||||||
import { evaluatePermissionsAbility } from "@app/helpers/permissions";
|
import { evaluatePermissionsAbility } from "@app/helpers/permissions";
|
||||||
import { useGetProjectRoleBySlug, useUpdateProjectRole } from "@app/hooks/api";
|
import { useGetProjectRoleBySlug, useUpdateProjectRole } from "@app/hooks/api";
|
||||||
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
|
||||||
import { ProjectType } from "@app/hooks/api/projects/types";
|
import { ProjectType } from "@app/hooks/api/projects/types";
|
||||||
|
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
||||||
|
|
||||||
import { AddPoliciesButton } from "./AddPoliciesButton";
|
import { AddPoliciesButton } from "./AddPoliciesButton";
|
||||||
import { DynamicSecretPermissionConditions } from "./DynamicSecretPermissionConditions";
|
import { DynamicSecretPermissionConditions } from "./DynamicSecretPermissionConditions";
|
||||||
|
|||||||
+2
-2
@@ -5,10 +5,10 @@ import { z } from "zod";
|
|||||||
import { UpgradePlanModal } from "@app/components/license/UpgradePlanModal";
|
import { UpgradePlanModal } from "@app/components/license/UpgradePlanModal";
|
||||||
import { createNotification } from "@app/components/notifications";
|
import { createNotification } from "@app/components/notifications";
|
||||||
import { Button, FormControl, Input } from "@app/components/v2";
|
import { Button, FormControl, Input } from "@app/components/v2";
|
||||||
import { useProjectPermission, useSubscription, useProject } from "@app/context";
|
import { useProject, useProjectPermission, useSubscription } from "@app/context";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
|
||||||
import { useUpdateWorkspaceAuditLogsRetention } from "@app/hooks/api/projects/queries";
|
import { useUpdateWorkspaceAuditLogsRetention } from "@app/hooks/api/projects/queries";
|
||||||
|
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
||||||
|
|
||||||
const formSchema = z.object({
|
const formSchema = z.object({
|
||||||
auditLogsRetentionDays: z.coerce.number().min(0)
|
auditLogsRetentionDays: z.coerce.number().min(0)
|
||||||
|
|||||||
+1
-1
@@ -12,7 +12,7 @@ export const DeleteProjectProtection = () => {
|
|||||||
const handleToggleDeleteProjectProtection = async (state: boolean) => {
|
const handleToggleDeleteProjectProtection = async (state: boolean) => {
|
||||||
try {
|
try {
|
||||||
await mutateAsync({
|
await mutateAsync({
|
||||||
projectId: projectId,
|
projectId,
|
||||||
hasDeleteProtection: state
|
hasDeleteProtection: state
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -9,8 +9,8 @@ import {
|
|||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useOrganization,
|
useOrganization,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { useToggle } from "@app/hooks";
|
import { useToggle } from "@app/hooks";
|
||||||
import { useDeleteWorkspace, useGetWorkspaceUsers, useLeaveProject } from "@app/hooks/api";
|
import { useDeleteWorkspace, useGetWorkspaceUsers, useLeaveProject } from "@app/hooks/api";
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ export const CommitDetailsPage = () => {
|
|||||||
>
|
>
|
||||||
<CommitDetailsTab
|
<CommitDetailsTab
|
||||||
selectedCommitId={selectedCommitId}
|
selectedCommitId={selectedCommitId}
|
||||||
workspaceId={currentProject.id}
|
projectId={currentProject.id}
|
||||||
goBackToHistory={handleGoBackToHistory}
|
goBackToHistory={handleGoBackToHistory}
|
||||||
envSlug={envSlug}
|
envSlug={envSlug}
|
||||||
goToRollbackPreview={handleGoToRollbackPreview}
|
goToRollbackPreview={handleGoToRollbackPreview}
|
||||||
|
|||||||
+4
-4
@@ -53,13 +53,13 @@ const formatDisplayDate = (dateString: string): string => {
|
|||||||
|
|
||||||
export const CommitDetailsTab = ({
|
export const CommitDetailsTab = ({
|
||||||
selectedCommitId,
|
selectedCommitId,
|
||||||
workspaceId,
|
projectId,
|
||||||
envSlug,
|
envSlug,
|
||||||
goBackToHistory,
|
goBackToHistory,
|
||||||
goToRollbackPreview
|
goToRollbackPreview
|
||||||
}: {
|
}: {
|
||||||
selectedCommitId: string;
|
selectedCommitId: string;
|
||||||
workspaceId: string;
|
projectId: string;
|
||||||
envSlug: string;
|
envSlug: string;
|
||||||
goBackToHistory: () => void;
|
goBackToHistory: () => void;
|
||||||
goToRollbackPreview: () => void;
|
goToRollbackPreview: () => void;
|
||||||
@@ -71,7 +71,7 @@ export const CommitDetailsTab = ({
|
|||||||
"revertChanges"
|
"revertChanges"
|
||||||
] as const);
|
] as const);
|
||||||
|
|
||||||
const { data: commitDetails, isLoading } = useGetCommitDetails(workspaceId, selectedCommitId);
|
const { data: commitDetails, isLoading } = useGetCommitDetails(projectId, selectedCommitId);
|
||||||
|
|
||||||
const routerQueryParams: { secretPath?: string } = useSearch({
|
const routerQueryParams: { secretPath?: string } = useSearch({
|
||||||
from: ROUTE_PATHS.SecretManager.CommitDetailsPage.id
|
from: ROUTE_PATHS.SecretManager.CommitDetailsPage.id
|
||||||
@@ -80,7 +80,7 @@ export const CommitDetailsTab = ({
|
|||||||
|
|
||||||
const { mutateAsync: revert } = useCommitRevert({
|
const { mutateAsync: revert } = useCommitRevert({
|
||||||
commitId: selectedCommitId,
|
commitId: selectedCommitId,
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
environment: envSlug,
|
environment: envSlug,
|
||||||
directory: secretPath
|
directory: secretPath
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -8,8 +8,8 @@ import { Button, DeleteActionModal } from "@app/components/v2";
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useSubscription,
|
useProject,
|
||||||
useProject
|
useSubscription
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { useDeleteTrustedIp } from "@app/hooks/api";
|
import { useDeleteTrustedIp } from "@app/hooks/api";
|
||||||
import { usePopUp } from "@app/hooks/usePopUp";
|
import { usePopUp } from "@app/hooks/usePopUp";
|
||||||
|
|||||||
@@ -18,8 +18,8 @@ import {
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useSubscription,
|
useProject,
|
||||||
useProject
|
useSubscription
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { useGetTrustedIps } from "@app/hooks/api";
|
import { useGetTrustedIps } from "@app/hooks/api";
|
||||||
import { UsePopUpState } from "@app/hooks/usePopUp";
|
import { UsePopUpState } from "@app/hooks/usePopUp";
|
||||||
|
|||||||
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
import { Link } from "@tanstack/react-router";
|
import { Link } from "@tanstack/react-router";
|
||||||
|
|
||||||
import { EmptyState } from "@app/components/v2";
|
import { EmptyState } from "@app/components/v2";
|
||||||
import { useSubscription, useProject } from "@app/context";
|
import { useProject, useSubscription } from "@app/context";
|
||||||
import { EventType } from "@app/hooks/api/auditLogs/enums";
|
import { EventType } from "@app/hooks/api/auditLogs/enums";
|
||||||
import { TIntegrationWithEnv } from "@app/hooks/api/integrations/types";
|
import { TIntegrationWithEnv } from "@app/hooks/api/integrations/types";
|
||||||
import { LogsSection } from "@app/pages/organization/AuditLogsPage/components/LogsSection";
|
import { LogsSection } from "@app/pages/organization/AuditLogsPage/components/LogsSection";
|
||||||
|
|||||||
+2
-2
@@ -24,8 +24,8 @@ import { ROUTE_PATHS } from "@app/const/routes";
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { SecretSync } from "@app/hooks/api/secretSyncs";
|
import { SecretSync } from "@app/hooks/api/secretSyncs";
|
||||||
|
|||||||
@@ -4,13 +4,13 @@ import { z } from "zod";
|
|||||||
|
|
||||||
import { projectKeys } from "@app/hooks/api";
|
import { projectKeys } from "@app/hooks/api";
|
||||||
import { TIntegration } from "@app/hooks/api/integrations/types";
|
import { TIntegration } from "@app/hooks/api/integrations/types";
|
||||||
|
import { fetchWorkspaceIntegrations } from "@app/hooks/api/projects/queries";
|
||||||
import {
|
import {
|
||||||
fetchSecretSyncsByProjectId,
|
fetchSecretSyncsByProjectId,
|
||||||
SecretSync,
|
SecretSync,
|
||||||
secretSyncKeys,
|
secretSyncKeys,
|
||||||
TSecretSync
|
TSecretSync
|
||||||
} from "@app/hooks/api/secretSyncs";
|
} from "@app/hooks/api/secretSyncs";
|
||||||
import { fetchWorkspaceIntegrations } from "@app/hooks/api/projects/queries";
|
|
||||||
import { IntegrationsListPageTabs } from "@app/types/integrations";
|
import { IntegrationsListPageTabs } from "@app/types/integrations";
|
||||||
|
|
||||||
import { IntegrationsListPage } from "./IntegrationsListPage";
|
import { IntegrationsListPage } from "./IntegrationsListPage";
|
||||||
|
|||||||
@@ -63,9 +63,9 @@ import {
|
|||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionDynamicSecretActions,
|
ProjectPermissionDynamicSecretActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
|
useProject,
|
||||||
useProjectPermission,
|
useProjectPermission,
|
||||||
useSubscription,
|
useSubscription
|
||||||
useProject
|
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { ProjectPermissionSecretRotationActions } from "@app/context/ProjectPermissionContext/types";
|
import { ProjectPermissionSecretRotationActions } from "@app/context/ProjectPermissionContext/types";
|
||||||
import {
|
import {
|
||||||
@@ -92,11 +92,11 @@ import {
|
|||||||
import { useGetProjectSecretsOverview } from "@app/hooks/api/dashboard/queries";
|
import { useGetProjectSecretsOverview } from "@app/hooks/api/dashboard/queries";
|
||||||
import { DashboardSecretsOrderBy, ProjectSecretsImportedBy } from "@app/hooks/api/dashboard/types";
|
import { DashboardSecretsOrderBy, ProjectSecretsImportedBy } from "@app/hooks/api/dashboard/types";
|
||||||
import { OrderByDirection } from "@app/hooks/api/generic/types";
|
import { OrderByDirection } from "@app/hooks/api/generic/types";
|
||||||
|
import { ProjectVersion } from "@app/hooks/api/projects/types";
|
||||||
import { useUpdateFolderBatch } from "@app/hooks/api/secretFolders/queries";
|
import { useUpdateFolderBatch } from "@app/hooks/api/secretFolders/queries";
|
||||||
import { TUpdateFolderBatchDTO } from "@app/hooks/api/secretFolders/types";
|
import { TUpdateFolderBatchDTO } from "@app/hooks/api/secretFolders/types";
|
||||||
import { TSecretRotationV2 } from "@app/hooks/api/secretRotationsV2";
|
import { TSecretRotationV2 } from "@app/hooks/api/secretRotationsV2";
|
||||||
import { SecretType, SecretV3RawSanitized, TSecretFolder, ProjectEnv } from "@app/hooks/api/types";
|
import { ProjectEnv, SecretType, SecretV3RawSanitized, TSecretFolder } from "@app/hooks/api/types";
|
||||||
import { ProjectVersion } from "@app/hooks/api/projects/types";
|
|
||||||
import {
|
import {
|
||||||
useDynamicSecretOverview,
|
useDynamicSecretOverview,
|
||||||
useFolderOverview,
|
useFolderOverview,
|
||||||
@@ -270,7 +270,7 @@ export const OverviewPage = () => {
|
|||||||
getImportedSecretByKey,
|
getImportedSecretByKey,
|
||||||
getEnvImportedSecretKeyCount
|
getEnvImportedSecretKeyCount
|
||||||
} = useGetImportedSecretsAllEnvs({
|
} = useGetImportedSecretsAllEnvs({
|
||||||
projectId: projectId,
|
projectId,
|
||||||
path: secretPath,
|
path: secretPath,
|
||||||
environments: (userAvailableEnvs || []).map(({ slug }) => slug)
|
environments: (userAvailableEnvs || []).map(({ slug }) => slug)
|
||||||
});
|
});
|
||||||
@@ -278,7 +278,7 @@ export const OverviewPage = () => {
|
|||||||
const isFilteredByResources = Object.values(filter).some(Boolean);
|
const isFilteredByResources = Object.values(filter).some(Boolean);
|
||||||
const { isPending: isOverviewLoading, data: overview } = useGetProjectSecretsOverview(
|
const { isPending: isOverviewLoading, data: overview } = useGetProjectSecretsOverview(
|
||||||
{
|
{
|
||||||
projectId: projectId,
|
projectId,
|
||||||
environments: visibleEnvs.map((env) => env.slug),
|
environments: visibleEnvs.map((env) => env.slug),
|
||||||
secretPath,
|
secretPath,
|
||||||
orderDirection,
|
orderDirection,
|
||||||
@@ -392,7 +392,7 @@ export const OverviewPage = () => {
|
|||||||
name: folderName,
|
name: folderName,
|
||||||
path: secretPath,
|
path: secretPath,
|
||||||
environment,
|
environment,
|
||||||
projectId: projectId,
|
projectId,
|
||||||
description
|
description
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@@ -484,7 +484,7 @@ export const OverviewPage = () => {
|
|||||||
);
|
);
|
||||||
if (folderName && parentPath && canCreateFolder) {
|
if (folderName && parentPath && canCreateFolder) {
|
||||||
await createFolder({
|
await createFolder({
|
||||||
projectId: projectId,
|
projectId,
|
||||||
path: parentPath,
|
path: parentPath,
|
||||||
environment: env,
|
environment: env,
|
||||||
name: folderName
|
name: folderName
|
||||||
@@ -648,7 +648,7 @@ export const OverviewPage = () => {
|
|||||||
);
|
);
|
||||||
if (folderName && parentPath && canCreateFolder) {
|
if (folderName && parentPath && canCreateFolder) {
|
||||||
await createFolder({
|
await createFolder({
|
||||||
projectId: projectId,
|
projectId,
|
||||||
environment: slug,
|
environment: slug,
|
||||||
path: parentPath,
|
path: parentPath,
|
||||||
name: folderName
|
name: folderName
|
||||||
@@ -662,7 +662,7 @@ export const OverviewPage = () => {
|
|||||||
navigate({
|
navigate({
|
||||||
to: "/projects/secret-management/$projectId/secrets/$envSlug",
|
to: "/projects/secret-management/$projectId/secrets/$envSlug",
|
||||||
params: {
|
params: {
|
||||||
projectId: projectId,
|
projectId,
|
||||||
envSlug: slug
|
envSlug: slug
|
||||||
},
|
},
|
||||||
search: query
|
search: query
|
||||||
@@ -1412,7 +1412,7 @@ export const OverviewPage = () => {
|
|||||||
<Link
|
<Link
|
||||||
to="/projects/secret-management/$projectId/settings"
|
to="/projects/secret-management/$projectId/settings"
|
||||||
params={{
|
params={{
|
||||||
projectId: projectId
|
projectId
|
||||||
}}
|
}}
|
||||||
hash="environments"
|
hash="environments"
|
||||||
>
|
>
|
||||||
|
|||||||
+4
-4
@@ -19,8 +19,8 @@ import { InfisicalSecretInput } from "@app/components/v2/InfisicalSecretInput";
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { ProjectPermissionSecretActions } from "@app/context/ProjectPermissionContext/types";
|
import { ProjectPermissionSecretActions } from "@app/context/ProjectPermissionContext/types";
|
||||||
import { getKeyValue } from "@app/helpers/parseEnvVar";
|
import { getKeyValue } from "@app/helpers/parseEnvVar";
|
||||||
@@ -92,7 +92,7 @@ export const CreateSecretForm = ({ secretPath = "/", onClose }: Props) => {
|
|||||||
|
|
||||||
if (folderName && parentPath && canCreateFolder) {
|
if (folderName && parentPath && canCreateFolder) {
|
||||||
await createFolder({
|
await createFolder({
|
||||||
projectId: projectId,
|
projectId,
|
||||||
path: parentPath,
|
path: parentPath,
|
||||||
environment,
|
environment,
|
||||||
name: folderName
|
name: folderName
|
||||||
@@ -190,7 +190,7 @@ export const CreateSecretForm = ({ secretPath = "/", onClose }: Props) => {
|
|||||||
try {
|
try {
|
||||||
const parsedSlug = slugSchema.parse(slug);
|
const parsedSlug = slugSchema.parse(slug);
|
||||||
await createWsTag.mutateAsync({
|
await createWsTag.mutateAsync({
|
||||||
projectId: projectId,
|
projectId,
|
||||||
tagSlug: parsedSlug,
|
tagSlug: parsedSlug,
|
||||||
tagColor: ""
|
tagColor: ""
|
||||||
});
|
});
|
||||||
|
|||||||
+1
-1
@@ -10,7 +10,7 @@ import { z } from "zod";
|
|||||||
|
|
||||||
import { createNotification } from "@app/components/notifications";
|
import { createNotification } from "@app/components/notifications";
|
||||||
import { IconButton, Input, Spinner, Tooltip } from "@app/components/v2";
|
import { IconButton, Input, Spinner, Tooltip } from "@app/components/v2";
|
||||||
import { ProjectPermissionSub, useProjectPermission, useProject } from "@app/context";
|
import { ProjectPermissionSub, useProject, useProjectPermission } from "@app/context";
|
||||||
import { ProjectPermissionSecretActions } from "@app/context/ProjectPermissionContext/types";
|
import { ProjectPermissionSecretActions } from "@app/context/ProjectPermissionContext/types";
|
||||||
import { useToggle } from "@app/hooks";
|
import { useToggle } from "@app/hooks";
|
||||||
import { useUpdateSecretV3 } from "@app/hooks/api";
|
import { useUpdateSecretV3 } from "@app/hooks/api";
|
||||||
|
|||||||
+1
-1
@@ -33,8 +33,8 @@ import {
|
|||||||
} from "@app/components/v2";
|
} from "@app/components/v2";
|
||||||
import { useDebounce } from "@app/hooks";
|
import { useDebounce } from "@app/hooks";
|
||||||
import { useGetProjectSecretsQuickSearch } from "@app/hooks/api/dashboard";
|
import { useGetProjectSecretsQuickSearch } from "@app/hooks/api/dashboard";
|
||||||
import { WsTag } from "@app/hooks/api/tags/types";
|
|
||||||
import { ProjectEnv } from "@app/hooks/api/projects/types";
|
import { ProjectEnv } from "@app/hooks/api/projects/types";
|
||||||
|
import { WsTag } from "@app/hooks/api/tags/types";
|
||||||
import { QuickSearchSecretRotationItem } from "@app/pages/secret-manager/OverviewPage/components/SecretSearchInput/components/QuickSearchSecretRotationItem";
|
import { QuickSearchSecretRotationItem } from "@app/pages/secret-manager/OverviewPage/components/SecretSearchInput/components/QuickSearchSecretRotationItem";
|
||||||
import { RowType } from "@app/pages/secret-manager/SecretDashboardPage/SecretMainPage.types";
|
import { RowType } from "@app/pages/secret-manager/SecretDashboardPage/SecretMainPage.types";
|
||||||
|
|
||||||
|
|||||||
+3
-3
@@ -8,11 +8,11 @@ import { z } from "zod";
|
|||||||
|
|
||||||
import { createNotification } from "@app/components/notifications";
|
import { createNotification } from "@app/components/notifications";
|
||||||
import { Button, Checkbox, Modal, ModalContent, Spinner } from "@app/components/v2";
|
import { Button, Checkbox, Modal, ModalContent, Spinner } from "@app/components/v2";
|
||||||
import { useProjectPermission, useProject } from "@app/context";
|
import { useProject, useProjectPermission } from "@app/context";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { useGetWorkspaceById, useMigrateProjectToV3, projectKeys } from "@app/hooks/api";
|
import { projectKeys, useGetWorkspaceById, useMigrateProjectToV3 } from "@app/hooks/api";
|
||||||
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
|
||||||
import { ProjectVersion } from "@app/hooks/api/projects/types";
|
import { ProjectVersion } from "@app/hooks/api/projects/types";
|
||||||
|
import { ProjectMembershipRole } from "@app/hooks/api/roles/types";
|
||||||
|
|
||||||
enum ProjectUpgradeStatus {
|
enum ProjectUpgradeStatus {
|
||||||
InProgress = "IN_PROGRESS",
|
InProgress = "IN_PROGRESS",
|
||||||
|
|||||||
+3
-3
@@ -9,9 +9,9 @@ import { Button, DeleteActionModal, Tooltip } from "@app/components/v2";
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
|
useProject,
|
||||||
useProjectPermission,
|
useProjectPermission,
|
||||||
useSubscription,
|
useSubscription
|
||||||
useProject
|
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { ProjectPermissionSecretActions } from "@app/context/ProjectPermissionContext/types";
|
import { ProjectPermissionSecretActions } from "@app/context/ProjectPermissionContext/types";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
@@ -133,7 +133,7 @@ export const SelectionPanel = ({
|
|||||||
folderId: folder?.id,
|
folderId: folder?.id,
|
||||||
path: secretPath,
|
path: secretPath,
|
||||||
environment: env.slug,
|
environment: env.slug,
|
||||||
projectId: projectId
|
projectId
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
+1
-1
@@ -30,8 +30,8 @@ import { ProjectPermissionSecretActions } from "@app/context/ProjectPermissionCo
|
|||||||
import { useDebounce } from "@app/hooks";
|
import { useDebounce } from "@app/hooks";
|
||||||
import { useMoveSecrets } from "@app/hooks/api";
|
import { useMoveSecrets } from "@app/hooks/api";
|
||||||
import { useGetProjectSecretsQuickSearch } from "@app/hooks/api/dashboard";
|
import { useGetProjectSecretsQuickSearch } from "@app/hooks/api/dashboard";
|
||||||
import { SecretV3RawSanitized } from "@app/hooks/api/secrets/types";
|
|
||||||
import { ProjectEnv } from "@app/hooks/api/projects/types";
|
import { ProjectEnv } from "@app/hooks/api/projects/types";
|
||||||
|
import { SecretV3RawSanitized } from "@app/hooks/api/secrets/types";
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
isOpen: boolean;
|
isOpen: boolean;
|
||||||
|
|||||||
@@ -66,7 +66,7 @@ export const SecretApprovalsPage = () => {
|
|||||||
<AccessApprovalRequest projectId={projectId} projectSlug={projectSlug} />
|
<AccessApprovalRequest projectId={projectId} projectSlug={projectSlug} />
|
||||||
</TabPanel>
|
</TabPanel>
|
||||||
<TabPanel value={TabSection.Policies}>
|
<TabPanel value={TabSection.Policies}>
|
||||||
<ApprovalPolicyList workspaceId={projectId} />
|
<ApprovalPolicyList projectId={projectId} />
|
||||||
</TabPanel>
|
</TabPanel>
|
||||||
</Tabs>
|
</Tabs>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
+2
-2
@@ -39,10 +39,10 @@ import { Badge } from "@app/components/v2/Badge";
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionMemberActions,
|
ProjectPermissionMemberActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
|
useProject,
|
||||||
useProjectPermission,
|
useProjectPermission,
|
||||||
useSubscription,
|
useSubscription,
|
||||||
useUser,
|
useUser
|
||||||
useProject
|
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import {
|
import {
|
||||||
getUserTablePreference,
|
getUserTablePreference,
|
||||||
|
|||||||
+1
-1
@@ -25,7 +25,7 @@ import {
|
|||||||
Tooltip
|
Tooltip
|
||||||
} from "@app/components/v2";
|
} from "@app/components/v2";
|
||||||
import { Badge } from "@app/components/v2/Badge";
|
import { Badge } from "@app/components/v2/Badge";
|
||||||
import { ProjectPermissionActions, useUser, useProject } from "@app/context";
|
import { ProjectPermissionActions, useProject, useUser } from "@app/context";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { useListWorkspaceGroups, useReviewAccessRequest } from "@app/hooks/api";
|
import { useListWorkspaceGroups, useReviewAccessRequest } from "@app/hooks/api";
|
||||||
import {
|
import {
|
||||||
|
|||||||
+6
-6
@@ -40,9 +40,9 @@ import {
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
TProjectPermission,
|
TProjectPermission,
|
||||||
|
useProject,
|
||||||
useProjectPermission,
|
useProjectPermission,
|
||||||
useSubscription,
|
useSubscription
|
||||||
useProject
|
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { ProjectPermissionActions } from "@app/context/ProjectPermissionContext/types";
|
import { ProjectPermissionActions } from "@app/context/ProjectPermissionContext/types";
|
||||||
import {
|
import {
|
||||||
@@ -59,14 +59,14 @@ import {
|
|||||||
import { useGetAccessApprovalPolicies } from "@app/hooks/api/accessApproval/queries";
|
import { useGetAccessApprovalPolicies } from "@app/hooks/api/accessApproval/queries";
|
||||||
import { OrderByDirection } from "@app/hooks/api/generic/types";
|
import { OrderByDirection } from "@app/hooks/api/generic/types";
|
||||||
import { PolicyType } from "@app/hooks/api/policies/enums";
|
import { PolicyType } from "@app/hooks/api/policies/enums";
|
||||||
import { TAccessApprovalPolicy, Project } from "@app/hooks/api/types";
|
import { Project, TAccessApprovalPolicy } from "@app/hooks/api/types";
|
||||||
|
|
||||||
import { AccessPolicyForm } from "./components/AccessPolicyModal";
|
import { AccessPolicyForm } from "./components/AccessPolicyModal";
|
||||||
import { ApprovalPolicyRow } from "./components/ApprovalPolicyRow";
|
import { ApprovalPolicyRow } from "./components/ApprovalPolicyRow";
|
||||||
import { RemoveApprovalPolicyModal } from "./components/RemoveApprovalPolicyModal";
|
import { RemoveApprovalPolicyModal } from "./components/RemoveApprovalPolicyModal";
|
||||||
|
|
||||||
interface IProps {
|
interface IProps {
|
||||||
workspaceId: string;
|
projectId: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
enum PolicyOrderBy {
|
enum PolicyOrderBy {
|
||||||
@@ -118,7 +118,7 @@ const useApprovalPolicies = (permission: TProjectPermission, currentProject?: Pr
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
export const ApprovalPolicyList = ({ workspaceId }: IProps) => {
|
export const ApprovalPolicyList = ({ projectId }: IProps) => {
|
||||||
const { handlePopUpToggle, handlePopUpOpen, popUp } = usePopUp([
|
const { handlePopUpToggle, handlePopUpOpen, popUp } = usePopUp([
|
||||||
"policyForm",
|
"policyForm",
|
||||||
"deletePolicy",
|
"deletePolicy",
|
||||||
@@ -128,7 +128,7 @@ export const ApprovalPolicyList = ({ workspaceId }: IProps) => {
|
|||||||
const { subscription } = useSubscription();
|
const { subscription } = useSubscription();
|
||||||
const { currentProject } = useProject();
|
const { currentProject } = useProject();
|
||||||
|
|
||||||
const { data: members } = useGetWorkspaceUsers(workspaceId, true);
|
const { data: members } = useGetWorkspaceUsers(projectId, true);
|
||||||
const { data: groups } = useListWorkspaceGroups(currentProject?.id || "");
|
const { data: groups } = useListWorkspaceGroups(currentProject?.id || "");
|
||||||
|
|
||||||
const { policies, isLoading: isPoliciesLoading } = useApprovalPolicies(
|
const { policies, isLoading: isPoliciesLoading } = useApprovalPolicies(
|
||||||
|
|||||||
+2
-2
@@ -35,9 +35,9 @@ import { ROUTE_PATHS } from "@app/const/routes";
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionMemberActions,
|
ProjectPermissionMemberActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
|
useProject,
|
||||||
useProjectPermission,
|
useProjectPermission,
|
||||||
useUser,
|
useUser
|
||||||
useProject
|
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import {
|
import {
|
||||||
getUserTablePreference,
|
getUserTablePreference,
|
||||||
|
|||||||
+1
-1
@@ -13,12 +13,12 @@ import { twMerge } from "tailwind-merge";
|
|||||||
|
|
||||||
import { createNotification } from "@app/components/notifications";
|
import { createNotification } from "@app/components/notifications";
|
||||||
import { Button, Checkbox, FormControl, Input } from "@app/components/v2";
|
import { Button, Checkbox, FormControl, Input } from "@app/components/v2";
|
||||||
|
import { useProject } from "@app/context";
|
||||||
import {
|
import {
|
||||||
usePerformSecretApprovalRequestMerge,
|
usePerformSecretApprovalRequestMerge,
|
||||||
useUpdateSecretApprovalRequestStatus
|
useUpdateSecretApprovalRequestStatus
|
||||||
} from "@app/hooks/api";
|
} from "@app/hooks/api";
|
||||||
import { EnforcementLevel } from "@app/hooks/api/policies/enums";
|
import { EnforcementLevel } from "@app/hooks/api/policies/enums";
|
||||||
import { useProject } from "@app/context";
|
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
approvalRequestId: string;
|
approvalRequestId: string;
|
||||||
|
|||||||
+1
-1
@@ -33,7 +33,7 @@ import {
|
|||||||
TextArea,
|
TextArea,
|
||||||
Tooltip
|
Tooltip
|
||||||
} from "@app/components/v2";
|
} from "@app/components/v2";
|
||||||
import { useUser, useProject } from "@app/context";
|
import { useProject, useUser } from "@app/context";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import {
|
import {
|
||||||
useGetSecretApprovalRequestDetails,
|
useGetSecretApprovalRequestDetails,
|
||||||
|
|||||||
@@ -25,8 +25,8 @@ import {
|
|||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionDynamicSecretActions,
|
ProjectPermissionDynamicSecretActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useProjectPermission,
|
useProject,
|
||||||
useProject
|
useProjectPermission
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import {
|
import {
|
||||||
ProjectPermissionCommitsActions,
|
ProjectPermissionCommitsActions,
|
||||||
@@ -50,10 +50,10 @@ import { useGetProjectSecretsDetails } from "@app/hooks/api/dashboard";
|
|||||||
import { DashboardSecretsOrderBy } from "@app/hooks/api/dashboard/types";
|
import { DashboardSecretsOrderBy } from "@app/hooks/api/dashboard/types";
|
||||||
import { useGetFolderCommitsCount } from "@app/hooks/api/folderCommits";
|
import { useGetFolderCommitsCount } from "@app/hooks/api/folderCommits";
|
||||||
import { OrderByDirection } from "@app/hooks/api/generic/types";
|
import { OrderByDirection } from "@app/hooks/api/generic/types";
|
||||||
|
import { ProjectVersion } from "@app/hooks/api/projects/types";
|
||||||
import { PendingAction } from "@app/hooks/api/secretFolders/types";
|
import { PendingAction } from "@app/hooks/api/secretFolders/types";
|
||||||
import { useCreateCommit } from "@app/hooks/api/secrets/mutations";
|
import { useCreateCommit } from "@app/hooks/api/secrets/mutations";
|
||||||
import { SecretV3RawSanitized } from "@app/hooks/api/types";
|
import { SecretV3RawSanitized } from "@app/hooks/api/types";
|
||||||
import { ProjectVersion } from "@app/hooks/api/projects/types";
|
|
||||||
import { usePathAccessPolicies } from "@app/hooks/usePathAccessPolicies";
|
import { usePathAccessPolicies } from "@app/hooks/usePathAccessPolicies";
|
||||||
import { useResizableColWidth } from "@app/hooks/useResizableColWidth";
|
import { useResizableColWidth } from "@app/hooks/useResizableColWidth";
|
||||||
import { hasSecretReadValueOrDescribePermission } from "@app/lib/fn/permission";
|
import { hasSecretReadValueOrDescribePermission } from "@app/lib/fn/permission";
|
||||||
@@ -148,7 +148,7 @@ const Page = () => {
|
|||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (isBatchMode && projectId && environment && secretPath) {
|
if (isBatchMode && projectId && environment && secretPath) {
|
||||||
loadPendingChanges({ projectId: projectId, environment, secretPath });
|
loadPendingChanges({ projectId, environment, secretPath });
|
||||||
}
|
}
|
||||||
}, [isBatchMode, projectId, environment, secretPath, loadPendingChanges]);
|
}, [isBatchMode, projectId, environment, secretPath, loadPendingChanges]);
|
||||||
|
|
||||||
@@ -248,7 +248,7 @@ const Page = () => {
|
|||||||
navigate({
|
navigate({
|
||||||
to: "/projects/secret-management/$projectId/overview",
|
to: "/projects/secret-management/$projectId/overview",
|
||||||
params: {
|
params: {
|
||||||
projectId: projectId
|
projectId
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -262,7 +262,7 @@ const Page = () => {
|
|||||||
isFetched
|
isFetched
|
||||||
} = useGetProjectSecretsDetails({
|
} = useGetProjectSecretsDetails({
|
||||||
environment,
|
environment,
|
||||||
projectId: projectId,
|
projectId,
|
||||||
secretPath,
|
secretPath,
|
||||||
offset,
|
offset,
|
||||||
limit,
|
limit,
|
||||||
@@ -316,7 +316,7 @@ const Page = () => {
|
|||||||
|
|
||||||
// fetch imported secrets to show user the overriden ones
|
// fetch imported secrets to show user the overriden ones
|
||||||
const { data: importedSecrets } = useGetImportedSecretsSingleEnv({
|
const { data: importedSecrets } = useGetImportedSecretsSingleEnv({
|
||||||
projectId: projectId,
|
projectId,
|
||||||
environment,
|
environment,
|
||||||
path: secretPath,
|
path: secretPath,
|
||||||
options: {
|
options: {
|
||||||
@@ -416,7 +416,7 @@ const Page = () => {
|
|||||||
navigate({
|
navigate({
|
||||||
to: "/projects/secret-management/$projectId/commits/$environment/$folderId",
|
to: "/projects/secret-management/$projectId/commits/$environment/$folderId",
|
||||||
params: {
|
params: {
|
||||||
projectId: projectId,
|
projectId,
|
||||||
folderId,
|
folderId,
|
||||||
environment
|
environment
|
||||||
},
|
},
|
||||||
@@ -647,7 +647,7 @@ const Page = () => {
|
|||||||
? change.tags?.map((tag) => ({
|
? change.tags?.map((tag) => ({
|
||||||
id: tag.id,
|
id: tag.id,
|
||||||
slug: tag.slug,
|
slug: tag.slug,
|
||||||
projectId: projectId,
|
projectId,
|
||||||
createdAt: new Date().toISOString(),
|
createdAt: new Date().toISOString(),
|
||||||
updatedAt: new Date().toISOString(),
|
updatedAt: new Date().toISOString(),
|
||||||
__v: 0
|
__v: 0
|
||||||
@@ -955,7 +955,7 @@ const Page = () => {
|
|||||||
secretImports={imports}
|
secretImports={imports}
|
||||||
isFetching={isDetailsFetching}
|
isFetching={isDetailsFetching}
|
||||||
environment={environment}
|
environment={environment}
|
||||||
workspaceId={projectId}
|
projectId={projectId}
|
||||||
secretPath={secretPath}
|
secretPath={secretPath}
|
||||||
importedSecrets={importedSecrets}
|
importedSecrets={importedSecrets}
|
||||||
/>
|
/>
|
||||||
@@ -964,7 +964,7 @@ const Page = () => {
|
|||||||
<FolderListView
|
<FolderListView
|
||||||
folders={mergedFolders}
|
folders={mergedFolders}
|
||||||
environment={environment}
|
environment={environment}
|
||||||
workspaceId={projectId}
|
projectId={projectId}
|
||||||
secretPath={secretPath}
|
secretPath={secretPath}
|
||||||
onNavigateToFolder={handleResetFilter}
|
onNavigateToFolder={handleResetFilter}
|
||||||
canNavigate={isFetched}
|
canNavigate={isFetched}
|
||||||
@@ -999,7 +999,7 @@ const Page = () => {
|
|||||||
<CommitForm
|
<CommitForm
|
||||||
onCommit={handleCreateCommit}
|
onCommit={handleCreateCommit}
|
||||||
environment={environment}
|
environment={environment}
|
||||||
workspaceId={projectId}
|
projectId={projectId}
|
||||||
secretPath={secretPath}
|
secretPath={secretPath}
|
||||||
isCommitting={isCommitPending}
|
isCommitting={isCommitPending}
|
||||||
/>
|
/>
|
||||||
|
|||||||
+3
-3
@@ -55,9 +55,9 @@ import {
|
|||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionDynamicSecretActions,
|
ProjectPermissionDynamicSecretActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
|
useProject,
|
||||||
useProjectPermission,
|
useProjectPermission,
|
||||||
useSubscription,
|
useSubscription
|
||||||
useProject
|
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import {
|
import {
|
||||||
ProjectPermissionCommitsActions,
|
ProjectPermissionCommitsActions,
|
||||||
@@ -635,7 +635,7 @@ export const ActionBar = ({
|
|||||||
queryKey: secretKeys.getProjectSecret({ projectId, environment, secretPath })
|
queryKey: secretKeys.getProjectSecret({ projectId, environment, secretPath })
|
||||||
});
|
});
|
||||||
queryClient.invalidateQueries({});
|
queryClient.invalidateQueries({});
|
||||||
queryKey: dashboardKeys.getDashboardSecrets({ projectId, secretPath });
|
dashboardKeys.getDashboardSecrets({ projectId, secretPath });
|
||||||
queryClient.invalidateQueries({
|
queryClient.invalidateQueries({
|
||||||
queryKey: secretApprovalRequestKeys.count({ projectId })
|
queryKey: secretApprovalRequestKeys.count({ projectId })
|
||||||
});
|
});
|
||||||
|
|||||||
+3
-3
@@ -14,7 +14,7 @@ import {
|
|||||||
SelectItem
|
SelectItem
|
||||||
} from "@app/components/v2";
|
} from "@app/components/v2";
|
||||||
import { SecretPathInput } from "@app/components/v2/SecretPathInput";
|
import { SecretPathInput } from "@app/components/v2/SecretPathInput";
|
||||||
import { useSubscription, useProject } from "@app/context";
|
import { useProject, useSubscription } from "@app/context";
|
||||||
import { useCreateSecretImport } from "@app/hooks/api";
|
import { useCreateSecretImport } from "@app/hooks/api";
|
||||||
|
|
||||||
const typeSchema = z.object({
|
const typeSchema = z.object({
|
||||||
@@ -43,7 +43,7 @@ type Props = {
|
|||||||
|
|
||||||
export const CreateSecretImportForm = ({
|
export const CreateSecretImportForm = ({
|
||||||
environment,
|
environment,
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
secretPath = "/",
|
secretPath = "/",
|
||||||
isOpen,
|
isOpen,
|
||||||
onClose,
|
onClose,
|
||||||
@@ -77,7 +77,7 @@ export const CreateSecretImportForm = ({
|
|||||||
|
|
||||||
await createSecretImport({
|
await createSecretImport({
|
||||||
environment,
|
environment,
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
path: secretPath,
|
path: secretPath,
|
||||||
isReplication,
|
isReplication,
|
||||||
import: {
|
import: {
|
||||||
|
|||||||
+3
-3
@@ -64,7 +64,7 @@ type SecretStructure = {
|
|||||||
|
|
||||||
export const ReplicateFolderFromBoard = ({
|
export const ReplicateFolderFromBoard = ({
|
||||||
environments = [],
|
environments = [],
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
isOpen,
|
isOpen,
|
||||||
onToggle,
|
onToggle,
|
||||||
onParsedEnv
|
onParsedEnv
|
||||||
@@ -82,14 +82,14 @@ export const ReplicateFolderFromBoard = ({
|
|||||||
const [debouncedEnvCopySecretPath] = useDebounce(envCopySecPath);
|
const [debouncedEnvCopySecretPath] = useDebounce(envCopySecPath);
|
||||||
|
|
||||||
const { data: accessibleSecrets } = useGetAccessibleSecrets({
|
const { data: accessibleSecrets } = useGetAccessibleSecrets({
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
secretPath: "/",
|
secretPath: "/",
|
||||||
environment: selectedEnvSlug.slug,
|
environment: selectedEnvSlug.slug,
|
||||||
recursive: true,
|
recursive: true,
|
||||||
filterByAction: shouldIncludeValues
|
filterByAction: shouldIncludeValues
|
||||||
? ProjectPermissionSecretActions.ReadValue
|
? ProjectPermissionSecretActions.ReadValue
|
||||||
: ProjectPermissionSecretActions.DescribeSecret,
|
: ProjectPermissionSecretActions.DescribeSecret,
|
||||||
options: { enabled: Boolean(workspaceId) && Boolean(selectedEnvSlug) && isOpen }
|
options: { enabled: Boolean(projectId) && Boolean(selectedEnvSlug) && isOpen }
|
||||||
});
|
});
|
||||||
|
|
||||||
const restructureSecrets = useMemo(() => {
|
const restructureSecrets = useMemo(() => {
|
||||||
|
|||||||
+9
-11
@@ -25,14 +25,14 @@ interface CommitFormProps {
|
|||||||
onCommit: (changes: PendingChanges, commitMessage: string) => Promise<void>;
|
onCommit: (changes: PendingChanges, commitMessage: string) => Promise<void>;
|
||||||
isCommitting?: boolean;
|
isCommitting?: boolean;
|
||||||
environment: string;
|
environment: string;
|
||||||
workspaceId: string;
|
projectId: string;
|
||||||
secretPath: string;
|
secretPath: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
interface ResourceChangeProps {
|
interface ResourceChangeProps {
|
||||||
change: PendingChange;
|
change: PendingChange;
|
||||||
environment: string;
|
environment: string;
|
||||||
workspaceId: string;
|
projectId: string;
|
||||||
secretPath: string;
|
secretPath: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -237,7 +237,7 @@ const RenderFolderChanges = ({ onDiscard, change }: RenderResourceProps) => {
|
|||||||
const ResourceChange: React.FC<ResourceChangeProps> = ({
|
const ResourceChange: React.FC<ResourceChangeProps> = ({
|
||||||
change,
|
change,
|
||||||
environment,
|
environment,
|
||||||
workspaceId,
|
projectId,
|
||||||
secretPath
|
secretPath
|
||||||
}) => {
|
}) => {
|
||||||
const { removePendingChange } = useBatchModeActions();
|
const { removePendingChange } = useBatchModeActions();
|
||||||
@@ -245,7 +245,7 @@ const ResourceChange: React.FC<ResourceChangeProps> = ({
|
|||||||
const handleDeletePending = useCallback(
|
const handleDeletePending = useCallback(
|
||||||
(changeType: string, id: string) => {
|
(changeType: string, id: string) => {
|
||||||
removePendingChange(id, changeType, {
|
removePendingChange(id, changeType, {
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
environment,
|
environment,
|
||||||
secretPath
|
secretPath
|
||||||
});
|
});
|
||||||
@@ -272,7 +272,7 @@ export const CommitForm: React.FC<CommitFormProps> = ({
|
|||||||
onCommit,
|
onCommit,
|
||||||
isCommitting = false,
|
isCommitting = false,
|
||||||
environment,
|
environment,
|
||||||
workspaceId,
|
projectId,
|
||||||
secretPath
|
secretPath
|
||||||
}) => {
|
}) => {
|
||||||
const { isBatchMode, pendingChanges, totalChangesCount } = useBatchMode();
|
const { isBatchMode, pendingChanges, totalChangesCount } = useBatchMode();
|
||||||
@@ -291,7 +291,7 @@ export const CommitForm: React.FC<CommitFormProps> = ({
|
|||||||
}
|
}
|
||||||
await onCommit(pendingChanges, commitMessage);
|
await onCommit(pendingChanges, commitMessage);
|
||||||
clearAllPendingChanges({
|
clearAllPendingChanges({
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
environment,
|
environment,
|
||||||
secretPath
|
secretPath
|
||||||
});
|
});
|
||||||
@@ -335,9 +335,7 @@ export const CommitForm: React.FC<CommitFormProps> = ({
|
|||||||
<div className="ml-6 mt-0.5 flex items-center gap-3">
|
<div className="ml-6 mt-0.5 flex items-center gap-3">
|
||||||
<Button
|
<Button
|
||||||
size="sm"
|
size="sm"
|
||||||
onClick={() =>
|
onClick={() => clearAllPendingChanges({ projectId, environment, secretPath })}
|
||||||
clearAllPendingChanges({ projectId: workspaceId, environment, secretPath })
|
|
||||||
}
|
|
||||||
isDisabled={totalChangesCount === 0}
|
isDisabled={totalChangesCount === 0}
|
||||||
variant="outline_bg"
|
variant="outline_bg"
|
||||||
className="px-4 hover:border-red/40 hover:bg-red/[0.1]"
|
className="px-4 hover:border-red/40 hover:bg-red/[0.1]"
|
||||||
@@ -393,7 +391,7 @@ export const CommitForm: React.FC<CommitFormProps> = ({
|
|||||||
key={change.id}
|
key={change.id}
|
||||||
change={change}
|
change={change}
|
||||||
environment={environment}
|
environment={environment}
|
||||||
workspaceId={workspaceId}
|
projectId={projectId}
|
||||||
secretPath={secretPath}
|
secretPath={secretPath}
|
||||||
/>
|
/>
|
||||||
))}
|
))}
|
||||||
@@ -414,7 +412,7 @@ export const CommitForm: React.FC<CommitFormProps> = ({
|
|||||||
key={change.id}
|
key={change.id}
|
||||||
change={change}
|
change={change}
|
||||||
environment={environment}
|
environment={environment}
|
||||||
workspaceId={workspaceId}
|
projectId={projectId}
|
||||||
secretPath={secretPath}
|
secretPath={secretPath}
|
||||||
/>
|
/>
|
||||||
))}
|
))}
|
||||||
|
|||||||
+3
-3
@@ -133,7 +133,7 @@ export const CompareEnvironments = ({ secretPath }: Props) => {
|
|||||||
setUserTablePreference("secretCompareTable", PreferenceKey.PerPage, newPerPage);
|
setUserTablePreference("secretCompareTable", PreferenceKey.PerPage, newPerPage);
|
||||||
};
|
};
|
||||||
|
|
||||||
const workspaceId = currentProject.id;
|
const projectId = currentProject.id;
|
||||||
const [searchFilter, setSearchFilter] = useState("");
|
const [searchFilter, setSearchFilter] = useState("");
|
||||||
const [debouncedSearchFilter] = useDebounce(searchFilter);
|
const [debouncedSearchFilter] = useDebounce(searchFilter);
|
||||||
const [debouncedSelectedEnvironments] = useDebounce(selectedEnvironments);
|
const [debouncedSelectedEnvironments] = useDebounce(selectedEnvironments);
|
||||||
@@ -151,7 +151,7 @@ export const CompareEnvironments = ({ secretPath }: Props) => {
|
|||||||
getImportedSecretByKey,
|
getImportedSecretByKey,
|
||||||
getEnvImportedSecretKeyCount
|
getEnvImportedSecretKeyCount
|
||||||
} = useGetImportedSecretsAllEnvs({
|
} = useGetImportedSecretsAllEnvs({
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
path: secretPath,
|
path: secretPath,
|
||||||
environments: (currentProject.environments || []).map(({ slug }) => slug)
|
environments: (currentProject.environments || []).map(({ slug }) => slug)
|
||||||
});
|
});
|
||||||
@@ -163,7 +163,7 @@ export const CompareEnvironments = ({ secretPath }: Props) => {
|
|||||||
const isFilteredByResources = Object.values(filter).some(Boolean);
|
const isFilteredByResources = Object.values(filter).some(Boolean);
|
||||||
const { isPending: isOverviewLoading, data: overview } = useGetProjectSecretsOverview(
|
const { isPending: isOverviewLoading, data: overview } = useGetProjectSecretsOverview(
|
||||||
{
|
{
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
environments: compareEnvironments.map((env) => env.slug),
|
environments: compareEnvironments.map((env) => env.slug),
|
||||||
secretPath,
|
secretPath,
|
||||||
orderDirection,
|
orderDirection,
|
||||||
|
|||||||
+2
-2
@@ -24,8 +24,8 @@ import { ROUTE_PATHS } from "@app/const/routes";
|
|||||||
import {
|
import {
|
||||||
ProjectPermissionActions,
|
ProjectPermissionActions,
|
||||||
ProjectPermissionSub,
|
ProjectPermissionSub,
|
||||||
useSubscription,
|
useProject,
|
||||||
useProject
|
useSubscription
|
||||||
} from "@app/context";
|
} from "@app/context";
|
||||||
import { usePopUp } from "@app/hooks";
|
import { usePopUp } from "@app/hooks";
|
||||||
import { projectKeys } from "@app/hooks/api";
|
import { projectKeys } from "@app/hooks/api";
|
||||||
|
|||||||
+8
-8
@@ -33,7 +33,7 @@ import { FolderForm } from "../ActionBar/FolderForm";
|
|||||||
type Props = {
|
type Props = {
|
||||||
folders?: TSecretFolder[];
|
folders?: TSecretFolder[];
|
||||||
environment: string;
|
environment: string;
|
||||||
workspaceId: string;
|
projectId: string;
|
||||||
secretPath?: string;
|
secretPath?: string;
|
||||||
onNavigateToFolder: (path: string) => void;
|
onNavigateToFolder: (path: string) => void;
|
||||||
canNavigate: boolean;
|
canNavigate: boolean;
|
||||||
@@ -42,7 +42,7 @@ type Props = {
|
|||||||
export const FolderListView = ({
|
export const FolderListView = ({
|
||||||
folders = [],
|
folders = [],
|
||||||
environment,
|
environment,
|
||||||
workspaceId,
|
projectId,
|
||||||
secretPath = "/",
|
secretPath = "/",
|
||||||
onNavigateToFolder,
|
onNavigateToFolder,
|
||||||
canNavigate
|
canNavigate
|
||||||
@@ -89,7 +89,7 @@ export const FolderListView = ({
|
|||||||
};
|
};
|
||||||
|
|
||||||
addPendingChange(updatedCreate, {
|
addPendingChange(updatedCreate, {
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
environment,
|
environment,
|
||||||
secretPath
|
secretPath
|
||||||
});
|
});
|
||||||
@@ -106,7 +106,7 @@ export const FolderListView = ({
|
|||||||
};
|
};
|
||||||
|
|
||||||
addPendingChange(updateChange, {
|
addPendingChange(updateChange, {
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
environment,
|
environment,
|
||||||
secretPath
|
secretPath
|
||||||
});
|
});
|
||||||
@@ -121,7 +121,7 @@ export const FolderListView = ({
|
|||||||
name: newFolderName,
|
name: newFolderName,
|
||||||
path: secretPath,
|
path: secretPath,
|
||||||
environment,
|
environment,
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
description: newFolderDescription
|
description: newFolderDescription
|
||||||
});
|
});
|
||||||
handlePopUpClose("updateFolder");
|
handlePopUpClose("updateFolder");
|
||||||
@@ -140,7 +140,7 @@ export const FolderListView = ({
|
|||||||
|
|
||||||
const handleDeletePending = (id: string) => {
|
const handleDeletePending = (id: string) => {
|
||||||
removePendingChange(id, "folder", {
|
removePendingChange(id, "folder", {
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
environment,
|
environment,
|
||||||
secretPath
|
secretPath
|
||||||
});
|
});
|
||||||
@@ -161,7 +161,7 @@ export const FolderListView = ({
|
|||||||
};
|
};
|
||||||
|
|
||||||
addPendingChange(pendingFolderDelete, {
|
addPendingChange(pendingFolderDelete, {
|
||||||
projectId: workspaceId,
|
projectId,
|
||||||
environment,
|
environment,
|
||||||
secretPath
|
secretPath
|
||||||
});
|
});
|
||||||
@@ -174,7 +174,7 @@ export const FolderListView = ({
|
|||||||
folderId: folderData.id,
|
folderId: folderData.id,
|
||||||
path: secretPath,
|
path: secretPath,
|
||||||
environment,
|
environment,
|
||||||
projectId: workspaceId
|
projectId
|
||||||
});
|
});
|
||||||
|
|
||||||
handlePopUpClose("deleteFolder");
|
handlePopUpClose("deleteFolder");
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user