Files
petitspas/backend/src/routes/relais/dto/create-relais.dto.ts
T
jmartinandCursor 42c569e491 feat(release): Backend Relais Module (#94)
- Implemented Relais entity and CRUD API
- Added relation between Users (Gestionnaires) and Relais
- Updated database initialization script
- Documentation updates

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-21 14:40:32 +01:00

35 lines
849 B
TypeScript

import { ApiProperty } from '@nestjs/swagger';
import { IsBoolean, IsNotEmpty, IsOptional, IsString, IsObject } from 'class-validator';
export class CreateRelaisDto {
@ApiProperty({ example: 'Relais Petite Enfance Centre' })
@IsString()
@IsNotEmpty()
nom: string;
@ApiProperty({ example: '12 rue de la Mairie, 75000 Paris' })
@IsString()
@IsNotEmpty()
adresse: string;
@ApiProperty({ example: { lundi: '09:00-17:00' }, required: false })
@IsOptional()
@IsObject()
horaires_ouverture?: any;
@ApiProperty({ example: '0123456789', required: false })
@IsOptional()
@IsString()
ligne_fixe?: string;
@ApiProperty({ default: true, required: false })
@IsOptional()
@IsBoolean()
actif?: boolean;
@ApiProperty({ example: 'Notes internes...', required: false })
@IsOptional()
@IsString()
notes?: string;
}