From b772de06ef05a9b4ca59bcef9c1a2212d26d4004 Mon Sep 17 00:00:00 2001 From: "SANDHYA.JS" Date: Tue, 10 Dec 2024 15:21:03 +0530 Subject: [PATCH] Advanced Cluster Management Enhancements - Chnaged cluster page design from switch to single page - Added bootstrap option in creation and registration - Added horizontal scaling, vertical scaling and upgrade in cluster action - In cluster page, for list combined two apis to show list done temporary fix from UI Change-Id: Ie4d30f5db28025ec92398cc60fc50ab7030f8f9b Signed-off-by: SANDHYA.JS --- .../k8s/k8s-action/K8sActionComponent.html | 82 +++++---- src/app/k8s/k8s-action/K8sActionComponent.ts | 26 +-- .../K8sAddClusterComponent.html | 85 +++++++--- .../K8sAddClusterComponent.scss | 44 ++++- .../k8s-add-cluster/K8sAddClusterComponent.ts | 135 ++++++++++++--- .../k8s/k8scluster/K8sClusterComponent.html | 27 +-- .../k8s/k8scluster/K8sClusterComponent.scss | 85 ---------- src/app/k8s/k8scluster/K8sClusterComponent.ts | 155 +++++++++++++----- src/app/utilities/delete/DeleteComponent.html | 2 +- src/app/utilities/delete/DeleteComponent.ts | 36 +++- .../utilities/show-info/ShowInfoComponent.ts | 31 +++- src/assets/i18n/de.json | 7 +- src/assets/i18n/en.json | 7 +- src/assets/i18n/es.json | 7 +- src/assets/i18n/pt.json | 7 +- src/models/CommonModel.ts | 9 + src/models/K8sModel.ts | 21 ++- 17 files changed, 499 insertions(+), 267 deletions(-) diff --git a/src/app/k8s/k8s-action/K8sActionComponent.html b/src/app/k8s/k8s-action/K8sActionComponent.html index efa3616..5482868 100644 --- a/src/app/k8s/k8s-action/K8sActionComponent.html +++ b/src/app/k8s/k8s-action/K8sActionComponent.html @@ -16,28 +16,34 @@ limitations under the License. Author: KUMARAN M (kumaran.m@tataelxsi.co.in), RAJESH S (rajesh.s@tataelxsi.co.in), BARATH KUMAR R (barath.r@tataelxsi.co.in) -->
- + - - - -
+ + +
-
-
- +
+
+ +
diff --git a/src/app/k8s/k8s-action/K8sActionComponent.ts b/src/app/k8s/k8s-action/K8sActionComponent.ts index 4723deb..bbd574f 100644 --- a/src/app/k8s/k8s-action/K8sActionComponent.ts +++ b/src/app/k8s/k8s-action/K8sActionComponent.ts @@ -121,21 +121,20 @@ export class K8sActionComponent { this.instanceID = this.value.identifier; this.getK8sType = this.value.pageType; this.state = this.value.state; - if (sessionStorage.getItem('clusterType') === 'Registered') { - this.checkRegister = true; - } - if (this.getK8sType === 'infra-config' || this.getK8sType === 'infra-controller' || this.getK8sType === 'app-profile' || this.getK8sType === 'resource-profile') { - this.isCluster = false; - this.isProfile = true; - this.isKSU = false; - } else if (sessionStorage.getItem('clusterType') === 'Managed') { + if ((this.value.createdbyosm) === 'true') { this.isCluster = true; - this.isProfile = false; - this.isKSU = false; + } else if ((this.value.createdbyosm) === 'false') { + this.isCluster = false; } if (this.getK8sType === 'k8-ksu') { this.isKSU = true; - this.isCluster = false; + } else { + this.isKSU = false; + } + + if (this.getK8sType === 'infra-config' || this.getK8sType === 'infra-controller' || this.getK8sType === 'app-profile' || this.getK8sType === 'resource-profile') { + this.isProfile = true; + } else { this.isProfile = false; } } @@ -168,7 +167,10 @@ export class K8sActionComponent { this.modalService.open(ShowInfoComponent, { backdrop: 'static' }).componentInstance.params = { id: this.instanceID, page: pageName, - titleName: title + titleName: title, + createdbyosm: this.value.createdbyosm, + bootstrap: this.value.bootstrap, + key: this.value.key }; } /** Edit profile @public */ diff --git a/src/app/k8s/k8s-add-cluster/K8sAddClusterComponent.html b/src/app/k8s/k8s-add-cluster/K8sAddClusterComponent.html index a8d5820..3d623ae 100644 --- a/src/app/k8s/k8s-add-cluster/K8sAddClusterComponent.html +++ b/src/app/k8s/k8s-add-cluster/K8sAddClusterComponent.html @@ -17,19 +17,39 @@ Author: KUMARAN M (kumaran.m@tataelxsi.co.in), RAJESH S (rajesh.s@tataelxsi.co.i -->
-
+
-
+
-
+
@@ -69,27 +88,27 @@ Author: KUMARAN M (kumaran.m@tataelxsi.co.in), RAJESH S (rajesh.s@tataelxsi.co.i
-
- +
+
+ formControlName="description" id="description" + [ngClass]="{ 'is-invalid': submitted && f.description.errors }">
-
+
{{'FILEUPLOADLABEL' | translate}}
- +
-
+