Skip to content

Commit

Permalink
image pull policy check box added, modifications in app setting for
Browse files Browse the repository at this point in the history
compute and scaling
  • Loading branch information
nxtcoder36 committed Mar 14, 2024
1 parent ce163de commit a14b49f
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 10 deletions.
1 change: 1 addition & 0 deletions src/apps/console/page-components/app-states.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ const defaultApp: AppIn = {
{
image: '',
name: 'container-1',
env: [],
},
],
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ export const EnvironmentVariables = () => {
submit,
resetValues: resetAppValue,
} = useForm({
initialValues: getContainer().env || [],
initialValues: getContainer().env,
validationSchema: Yup.array(entry),
onSubmit: (val) => {
setContainer((c) => ({
Expand All @@ -252,15 +252,16 @@ export const EnvironmentVariables = () => {
}, [hasChanges]);

const addEntry = (val: IEnvVariable) => {
const tempVal = val || [];
setValues((v = []) => {
const data = {
key: val.key,
type: val.type,
refName: val.refName || '',
refKey: val.refKey || '',
value: val.value || '',
key: tempVal.key,
type: tempVal.type,
refName: tempVal.refName || '',
refKey: tempVal.refKey || '',
value: tempVal.value || '',
};
return [...v, data];
return [...(v || []), data];
});
};

Expand Down Expand Up @@ -312,8 +313,6 @@ export const EnvironmentVariables = () => {
}),
}),
onSubmit: () => {
console.log(eValues);

if (eValues.textInputValue) {
const ev: IEnvVariable = {
key: eValues.key,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ const AppReview = () => {

useEffect(() => {
const res = validateType(app, 'AppIn');
// console.log('res', res);
setErrors(res);
}, []);

Expand Down

0 comments on commit a14b49f

Please sign in to comment.