refs #1318 No clients view added and minor upgrades.
testing/ogGui-multibranch/pipeline/head There was a failure building this commit Details

pull/10/head
Lucas Lara García 2025-01-08 12:04:00 +01:00
parent e9baede635
commit d469b93a96
4 changed files with 147 additions and 112 deletions

View File

@ -600,3 +600,10 @@ button[mat-raised-button] {
display: block;
margin-bottom: 1.5rem;
}
.no-clients-info {
display: flex;
align-items: center;
gap: 10px;
margin-top: 1.5rem;
}

View File

@ -1,3 +1,4 @@
<!-- Header -->
<div class="header-container" joyrideStep="tabsStep" text="{{ 'tabsStepText' | translate }}">
<button mat-icon-button color="primary" (click)="iniciarTour()">
<mat-icon>help</mat-icon>
@ -22,6 +23,7 @@
</div>
</div>
<!-- Filters Panel -->
<mat-expansion-panel *ngIf="isTreeViewActive" class="filters-panel" joyrideStep="filtersPanelStep" text="{{ 'filtersPanelStepText' | translate }}">
<mat-expansion-panel-header>
<mat-panel-title>{{ 'filters' | translate }}</mat-panel-title>
@ -54,6 +56,7 @@
</div>
</mat-expansion-panel>
<!-- Main units cards -->
<div *ngIf="!selectedUnidad; else detailsTemplate" class="card-container" joyrideStep="organizationalUnitsStep" text="{{ 'organizationalUnitsStepText' | translate }}">
<mat-card *ngFor="let unidad of organizationalUnits"
[ngClass]="{'selected-item': unidad === selectedUnidad, 'clickable-item': true}"
@ -100,7 +103,9 @@
</mat-card>
</div>
<!-- Unit details view-->
<ng-template #detailsTemplate>
<!-- Header -->
<div class="header-actions-container">
<button mat-raised-button color="primary" (click)="clearSelection()" class="back-button">
<mat-icon>arrow_back</mat-icon>
@ -116,6 +121,7 @@
</div>
</div>
<div class="main-container">
<!-- Tree view -->
<div class="tree-container">
<h2>{{ selectedUnidad?.name }}</h2>
<mat-tree [dataSource]="treeDataSource" [treeControl]="treeControl">
@ -160,8 +166,10 @@
</mat-tree-node>
</mat-tree>
</div>
<mat-divider [vertical]="true"></mat-divider>
<!-- Tree node actions -->
<mat-menu restoreFocus=false #commandMenu="matMenu">
<button mat-menu-item *ngFor="let command of commands" (click)="executeCommand(command, selectedNode)">
<span>{{ command.name }}</span>
@ -193,8 +201,17 @@
<span>{{ 'delete' | translate }}</span>
</button>
</mat-menu>
<div class="clients-container" *ngIf="(selectedClients.data?.length || 0) > 0">
<span class="clients-title-name">{{ 'clients' | translate }} <strong>{{ selectedNode?.name ? ' ' + selectedNode?.name : ' ' + selectedUnidad?.name }}</strong></span>
<!-- Clients view -->
<div class="clients-container">
<span class="clients-title-name">{{ 'clients' | translate }}
<strong>{{ selectedNode?.name ? ' ' + selectedNode?.name : ' ' + selectedUnidad?.name }}</strong>
</span>
<mat-divider></mat-divider>
<div *ngIf="(selectedClients.data?.length || 0) > 0; else noClientsTemplate">
<!-- Cards view -->
<div class="clients-grid" *ngIf="currentView === 'card'">
<div *ngFor="let client of selectedClients.data" class="client-item">
<div class="client-card">
@ -231,7 +248,7 @@
</div>
</div>
</div>
<!-- List view -->
<div class="clients-table" *ngIf="currentView === 'list'">
<table mat-table matSort [dataSource]="selectedClients" class="mat-elevation-z8">
<ng-container matColumnDef="status">
@ -324,4 +341,13 @@
</div>
</div>
</div>
<!-- No clients view -->
<ng-template #noClientsTemplate>
<div class="no-clients-info">
<mat-icon>error_outline</mat-icon>
<span>{{ 'noClients' | translate }}</span>
</div>
</ng-template>
</div>
</ng-template>

View File

@ -449,5 +449,6 @@
"adminUsersTitle": "Manage users",
"filtersPanelStepText": "Use these filters to search or load configurations.",
"organizationalUnitsStepText": "List of Organizational Units. Click on one to view details.",
"defaultMenuLabel": "Main menu"
"defaultMenuLabel": "Main menu",
"noClients": "No clients"
}

View File

@ -451,5 +451,6 @@
"adminUsersTitle": "Administrar usuarios",
"filtersPanelStepText": "Utiliza estos filtros para buscar o cargar configuraciones.",
"organizationalUnitsStepText": "Lista de Unidades Organizacionales. Haz clic en una para ver detalles.",
"defaultMenuLabel": "Menú por defecto"
"defaultMenuLabel": "Menú por defecto",
"noClients": "No hay clientes"
}