fix(clients): use Count constraint instead of GreaterThan for moving clients payload validation
testing/ogcore-api/pipeline/head There was a failure building this commit Details
ogcore-debian-package/pipeline/head This commit looks good Details
ogcore-debian-package/pipeline/tag This commit looks good Details

devel 1.11.2
Juan Manuel Bardallo 2026-10-06 14:15:58 +02:00
parent e8f5fe12d3
commit e5fbb0a24c
2 changed files with 7 additions and 2 deletions

View File

@ -1,5 +1,10 @@
# Changelog
## [1.11.2] - 2026-10-06
### Fixed
- **API Platform (Client)**: Corregido un error ("The input data is misformatted") al mover clientes a otras unidades organizativas o aulas desde la interfaz. El endpoint de la API (`/clients/change-organizational-unit`) estaba utilizando incorrectamente la restricción de validación `GreaterThan(1)` sobre la lista de equipos en lugar de `Count(min: 1)`, lo que provocaba un fallo interno en el serializador de Symfony. Ahora se pueden mover equipos correctamente, incluso de uno en uno.
## [1.11.1] - 2026-10-02
### Fixed

View File

@ -13,10 +13,10 @@ final class ChangeOrganizationalUnitInput
/**
* @var ClientOutput[]
*/
#[Assert\GreaterThan(1)]
#[Assert\Count(min: 1)]
#[Groups(['client:write'])]
#[ApiProperty(
description: 'Los clientes a mover (mínimo 2)',
description: 'Los clientes a mover (mínimo 1)',
example: []
)]
public ?array $clients = [];