refactor: fix bugs et réduire duplication + extraire modales BrowseComponent
- fix(dto): ajouter @IsEmail() sur contactFunctionalEmail/TechnicalEmail dans UpdateApiEntryDto - fix(docs): corriger stringify des erreurs (String(error) → error.message) - refactor(mapper): extraire toApiEntryListItem() dans api-entry.mapper.ts partagé - refactor(categories): supprimer CONVENTION_LABELS et toApiEntryListItem locaux dupliqués - refactor(browse): extraire CategoryFormModalComponent et CategoryDeleteModalComponent - refactor(api-detail): convertir editPreviewTitle() en computed() Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { IsString, IsOptional, IsUUID, IsIn, IsInt, Min } from 'class-validator';
|
||||
import { IsString, IsOptional, IsUUID, IsIn, IsInt, Min, IsEmail } from 'class-validator';
|
||||
import { Type } from 'class-transformer';
|
||||
import { ApiConvention } from '@datacat/shared';
|
||||
|
||||
@@ -49,7 +49,7 @@ export class UpdateApiEntryDto {
|
||||
@IsOptional()
|
||||
contactFunctionalEntity?: string;
|
||||
|
||||
@IsString()
|
||||
@IsEmail()
|
||||
@IsOptional()
|
||||
contactFunctionalEmail?: string;
|
||||
|
||||
@@ -61,7 +61,7 @@ export class UpdateApiEntryDto {
|
||||
@IsOptional()
|
||||
contactTechnicalEntity?: string;
|
||||
|
||||
@IsString()
|
||||
@IsEmail()
|
||||
@IsOptional()
|
||||
contactTechnicalEmail?: string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user