diff --git a/app/kubernetes/views/applications/create/createApplication.html b/app/kubernetes/views/applications/create/createApplication.html
index 5b85af74f..9fb8576fb 100644
--- a/app/kubernetes/views/applications/create/createApplication.html
+++ b/app/kubernetes/views/applications/create/createApplication.html
@@ -414,7 +414,7 @@
style="margin-top: 7px; margin-left: 0"
button-spinner="ctrl.state.updateWebEditorInProgress"
>
- Update the application
+ Update application
Update in progress...
diff --git a/app/kubernetes/views/applications/create/createApplicationController.js b/app/kubernetes/views/applications/create/createApplicationController.js
index 4d64afcd1..d1da5f208 100644
--- a/app/kubernetes/views/applications/create/createApplicationController.js
+++ b/app/kubernetes/views/applications/create/createApplicationController.js
@@ -216,10 +216,12 @@ class KubernetesCreateApplicationController {
}
onChangeFileContent(value) {
- if (this.stackFileContent.replace(/(\r\n|\n|\r)/gm, '') !== value.replace(/(\r\n|\n|\r)/gm, '')) {
- this.state.isEditorDirty = true;
- this.stackFileContent = value;
- }
+ this.$scope.$evalAsync(() => {
+ if (this.stackFileContent.replace(/(\r\n|\n|\r)/gm, '') !== value.replace(/(\r\n|\n|\r)/gm, '')) {
+ this.state.isEditorDirty = true;
+ this.stackFileContent = value;
+ }
+ });
}
onDataAccessPolicyChange(value) {
@@ -1055,9 +1057,6 @@ class KubernetesCreateApplicationController {
this.formValues.OriginalIngresses = this.ingresses;
this.formValues.ImageModel = await this.parseImageConfiguration(this.formValues.ImageModel);
- this.savedFormValues = angular.copy(this.formValues);
- this.updateNamespaceLimits(this.namespaceWithQuota);
- this.updateSliders(this.namespaceWithQuota);
if (this.application.ApplicationType !== KubernetesApplicationTypes.StatefulSet) {
_.forEach(this.formValues.PersistedFolders, (persistedFolder) => {
@@ -1070,6 +1069,10 @@ class KubernetesCreateApplicationController {
}
this.formValues.OriginalPersistedFolders = this.formValues.PersistedFolders;
await this.refreshNamespaceData(namespace);
+
+ this.savedFormValues = angular.copy(this.formValues);
+ this.updateNamespaceLimits(this.namespaceWithQuota);
+ this.updateSliders(this.namespaceWithQuota);
} else {
this.formValues.AutoScaler = KubernetesApplicationHelper.generateAutoScalerFormValueFromHorizontalPodAutoScaler(null, this.formValues.ReplicaCount);
}
diff --git a/app/react/kubernetes/applications/application.queries.ts b/app/react/kubernetes/applications/application.queries.ts
index 118bc02af..5496f86cf 100644
--- a/app/react/kubernetes/applications/application.queries.ts
+++ b/app/react/kubernetes/applications/application.queries.ts
@@ -316,7 +316,9 @@ export function usePatchApplicationMutation(
}: {
appKind: AppKind;
patch: ApplicationPatch;
- contentType?: string;
+ contentType?:
+ | 'application/json-patch+json'
+ | 'application/strategic-merge-patch+json';
}) =>
patchApplication(
environmentId,