From b7b707ada80893aca0d82512371f3917c228c420 Mon Sep 17 00:00:00 2001 From: Manuel Aranda Date: Mon, 20 Apr 2026 11:33:31 +0200 Subject: [PATCH 1/2] refs #2969. Updated deploy assistant UX --- .../deploy-image/deploy-image.component.css | 103 ++++++++++++++++-- .../deploy-image/deploy-image.component.html | 61 ++++++++--- .../deploy-image/deploy-image.component.ts | 13 ++- 3 files changed, 150 insertions(+), 27 deletions(-) diff --git a/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.css b/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.css index 8726114..c194ac4 100644 --- a/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.css +++ b/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.css @@ -107,12 +107,16 @@ /* Layout horizontal: imagen + partición */ .deploy-config-row { display: flex; + align-items: flex-start; gap: 16px; margin-bottom: 4px; } .image-config-section { flex: 0 0 340px; + min-width: 0; + max-width: 340px; + overflow: hidden; } .image-config-section .filters-row { @@ -125,11 +129,26 @@ width: 100% !important; } +.partition-column { + display: flex; + flex-direction: column; + flex: 1; + min-width: 0; + gap: 8px; +} + .partition-select-section { flex: 1; min-width: 0; } +.deploy-mode-row { + background: #ffffff; + border: 1px solid #e9ecef; + border-radius: 8px; + padding: 8px 12px; +} + .form-section-title mat-icon { color: #667eea; font-size: 24px; @@ -343,27 +362,60 @@ table { /* Resumen de configuración avanzada */ .method-config-summary { display: flex; - align-items: center; - justify-content: space-between; + flex-direction: column; padding: 8px 12px; background: #f0f4ff; border: 1px solid #d0d9ff; border-radius: 8px; margin-top: 8px; + gap: 4px; + min-width: 0; + overflow: hidden; +} + +.summary-top-row { + display: flex; + align-items: center; + justify-content: space-between; +} + +.summary-header { + display: flex; + align-items: center; + gap: 4px; +} + +.summary-header-icon { + font-size: 16px; + width: 16px; + height: 16px; + color: #667eea; + flex-shrink: 0; +} + +.summary-header-label { + font-size: 12px; + font-weight: 600; + color: #667eea; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + min-width: 0; } .summary-content { display: flex; align-items: center; - gap: 8px; + gap: 6px; min-width: 0; + overflow: hidden; } .summary-icon { - font-size: 18px; - width: 18px; - height: 18px; - color: #667eea; + font-size: 16px; + width: 16px; + height: 16px; + color: #28a745; flex-shrink: 0; } @@ -374,6 +426,39 @@ table { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; + min-width: 0; +} + +/* Estado pendiente de configurar método */ +.method-config-pending { + display: flex; + flex-direction: column; + align-items: flex-start; + gap: 8px; + padding: 10px 12px; + background: #fff8e1; + border: 1px solid #ffe082; + border-radius: 8px; + margin-top: 8px; +} + +.pending-message { + display: flex; + align-items: center; + gap: 6px; +} + +.pending-icon { + font-size: 18px; + width: 18px; + height: 18px; + color: #f9a825; + flex-shrink: 0; +} + +.pending-text { + font-size: 12px; + color: #795548; } /* Mensajes de error */ @@ -764,9 +849,9 @@ table { flex-wrap: wrap; margin-bottom: 20px; padding: 16px 20px; - background: #f7faff; + background: #ffffff; border-radius: 10px; - border: 1px solid #e2e8ff; + border: 1px solid #e9ecef; } .deploy-mode-label { diff --git a/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.html b/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.html index d86dc8d..79da034 100644 --- a/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.html +++ b/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.html @@ -157,9 +157,51 @@ + + @if (imageType === 'monolithic' && selectedMethod && needsAdvancedConfig(selectedMethod)) { + @if (methodConfigured) { +
+
+
+ tune + Parámetros de {{ getMethodLabel() }} +
+ +
+
+ check_circle + {{ getMethodConfigSummary() }} +
+
+ } @else { +
+
+ warning + Se requiere configurar los parámetros de {{ getMethodLabel() }} +
+ +
+ } + } + + +
+ {{ errorMessage }} +
+ + + + +
+ @if (imageType === 'monolithic' && selectedMethod && !isDirectMethod()) { -
+
cached Modo de operación @@ -187,21 +229,6 @@
} -
- {{ errorMessage }} -
- -
-
- tune - {{ getMethodConfigSummary() }} -
- -
-
- @if (deployMode !== 'update-cache') {
@@ -253,6 +280,8 @@
} + +
diff --git a/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.ts b/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.ts index 58de3dc..d42aeaf 100644 --- a/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.ts +++ b/ogWebconsole/src/app/components/groups/components/client-main-view/deploy-image/deploy-image.component.ts @@ -274,11 +274,10 @@ export class DeployImageComponent implements OnInit { } } this.errorMessage = ""; + this.methodConfigured = false; if (this.selectedMethod && this.needsAdvancedConfig(this.selectedMethod)) { this.openMethodConfigDialog(); - } else { - this.methodConfigured = false; } return true; @@ -288,6 +287,16 @@ export class DeployImageComponent implements OnInit { return ['udpcast', 'uftp', 'udpcast-direct', 'p2p'].includes(method); } + getMethodLabel(): string { + const labels: Record = { + 'udpcast': 'Multicast', + 'uftp': 'UFTP', + 'udpcast-direct': 'Multicast (directo)', + 'p2p': 'Torrent (P2P)', + }; + return this.selectedMethod ? (labels[this.selectedMethod] || this.selectedMethod) : ''; + } + openMethodConfigDialog(): void { const dialogRef = this.dialog.open(DeployMethodConfigDialogComponent, { width: '540px', -- 2.40.1 From fccbb26dac74283ee4e4160a981d4cc80b3f9bdd Mon Sep 17 00:00:00 2001 From: Manuel Aranda Date: Mon, 20 Apr 2026 11:45:17 +0200 Subject: [PATCH 2/2] refs #2970. Fixed bug in repo --- .../manage-repository/manage-repository.component.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ogWebconsole/src/app/components/repositories/manage-repository/manage-repository.component.ts b/ogWebconsole/src/app/components/repositories/manage-repository/manage-repository.component.ts index 581e656..189cdac 100644 --- a/ogWebconsole/src/app/components/repositories/manage-repository/manage-repository.component.ts +++ b/ogWebconsole/src/app/components/repositories/manage-repository/manage-repository.component.ts @@ -73,7 +73,7 @@ export class ManageRepositoryComponent implements OnInit { this.http.put(`${this.baseUrl}${this.repositoryId}`, payload).subscribe( (response) => { this.toastService.success('Repositorio editada correctamente'); - this.dialogRef.close(); + this.dialogRef.close(true); }, (error) => { this.toastService.error(error['error']['hydra:description']); @@ -83,7 +83,7 @@ export class ManageRepositoryComponent implements OnInit { this.http.post(`${this.baseUrl}/image-repositories`, payload).subscribe( (response) => { this.toastService.success('Repositorio añadido correctamente'); - this.dialogRef.close(); + this.dialogRef.close(true); }, (error) => { this.toastService.error(error['error']['hydra:description']); -- 2.40.1