From f8b91b875818015af194a35469067e6b69badba8 Mon Sep 17 00:00:00 2001 From: Hugo <hugo.cubino@estudiantes.uva.es> Date: Fri, 27 Dec 2024 14:53:20 +0100 Subject: [PATCH] Parece que ya no hay errores al lanzar angular --- .../users/main-page/main-page.component.ts | 1 + angular/RestClient/src/mocks/users.ts | 20 +++++++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/angular/RestClient/src/app/features/users/main-page/main-page.component.ts b/angular/RestClient/src/app/features/users/main-page/main-page.component.ts index 6434114..aa156b5 100644 --- a/angular/RestClient/src/app/features/users/main-page/main-page.component.ts +++ b/angular/RestClient/src/app/features/users/main-page/main-page.component.ts @@ -4,6 +4,7 @@ import { FormsModule } from '@angular/forms'; import { CommonModule } from '@angular/common'; import { Router, RouterModule } from '@angular/router'; import { UserClientService } from '../../../core/services/api/users/user-client.service'; +import { users } from '../../../../mocks/users'; import { MatTableDataSource, MatTableModule } from '@angular/material/table'; import { MatPaginator, MatPaginatorModule } from '@angular/material/paginator'; import { MatCardModule } from '@angular/material/card'; diff --git a/angular/RestClient/src/mocks/users.ts b/angular/RestClient/src/mocks/users.ts index e69de29..3a78c8f 100644 --- a/angular/RestClient/src/mocks/users.ts +++ b/angular/RestClient/src/mocks/users.ts @@ -0,0 +1,20 @@ +import { Client } from '@features/users/types/User.interface'; // Asegúrate de importar el tipo Client desde donde lo hayas definido + +export const users: Client[] = [ + { + id: 1, + name: "John Doe", + email: "john.doe@example.com", + status: "NO_BOOKINGS", + bookings: [], + rol: "CLIENT" + }, + { + id: 2, // Otro ID único + name: "Pepe", + email: "pepe@example.com", + status: "WITH_ACTIVE_BOOKINGS", + bookings: [], + rol: "CLIENT" + } +]; -- GitLab