forked from cerc-io/snowballtools-base
Add mutations for edit and delete environment variables (#54)
Co-authored-by: neeraj <neeraj.rtly@gmail.com>
This commit is contained in:
committed by
Ashwin Phatak
co-authored by
neeraj
parent
e1e9a7063e
commit
c8c6f66ed2
@@ -12,7 +12,7 @@ interface OverviewProps {
|
||||
}
|
||||
|
||||
// TODO: Check if any live domain is set for production branch
|
||||
const IS_DOMAIN_SETUP = true;
|
||||
const IS_DOMAIN_SETUP = false;
|
||||
|
||||
const OverviewTabPanel = ({ project }: OverviewProps) => {
|
||||
return (
|
||||
|
||||
+4
-4
@@ -70,7 +70,7 @@ export const EnvironmentVariablesTabPanel = () => {
|
||||
}
|
||||
}, [isSubmitSuccessful, reset, id]);
|
||||
|
||||
const getEnvironmentVariable = useCallback(
|
||||
const getEnvironmentVariables = useCallback(
|
||||
(environment: Environment) => {
|
||||
return environmentVariables.filter(
|
||||
(item) => item.environment === environment,
|
||||
@@ -226,17 +226,17 @@ export const EnvironmentVariablesTabPanel = () => {
|
||||
<div className="p-2">
|
||||
<DisplayEnvironmentVariables
|
||||
environment={Environment.Production}
|
||||
variables={getEnvironmentVariable(Environment.Production)}
|
||||
variables={getEnvironmentVariables(Environment.Production)}
|
||||
/>
|
||||
<HorizontalLine />
|
||||
<DisplayEnvironmentVariables
|
||||
environment={Environment.Preview}
|
||||
variables={getEnvironmentVariable(Environment.Preview)}
|
||||
variables={getEnvironmentVariables(Environment.Preview)}
|
||||
/>
|
||||
<HorizontalLine />
|
||||
<DisplayEnvironmentVariables
|
||||
environment={Environment.Development}
|
||||
variables={getEnvironmentVariable(Environment.Development)}
|
||||
variables={getEnvironmentVariables(Environment.Development)}
|
||||
/>
|
||||
</div>
|
||||
</>
|
||||
|
||||
@@ -51,7 +51,6 @@ const ProjectSearch = () => {
|
||||
...project,
|
||||
// TODO: populate empty fields
|
||||
icon: '',
|
||||
title: project.name,
|
||||
organization: orgName,
|
||||
deployments: updatedDeployments,
|
||||
url: '',
|
||||
|
||||
Reference in New Issue
Block a user