| Conditions | 1 |
| Paths | 1 |
| Total Lines | 25 |
| Code Lines | 17 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 24 |
| CRAP Score | 1 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 20 | 4 | public static function loadValidatorMetadata(ClassMetadata $metadata) |
|
| 21 | { |
||
| 22 | 4 | $metadata->addPropertyConstraints('tipoDoc', [ |
|
| 23 | 4 | new Assert\NotBlank(), |
|
| 24 | 4 | new Assert\Length([ |
|
| 25 | 4 | 'min' => 2, |
|
| 26 | 4 | 'max' => 2, |
|
| 27 | 4 | ]), |
|
| 28 | 4 | ]); |
|
| 29 | 4 | $metadata->addPropertyConstraints('serie', [ |
|
| 30 | 4 | new Assert\NotBlank(), |
|
| 31 | 4 | new Assert\Length([ |
|
| 32 | 4 | 'min' => 4, |
|
| 33 | 4 | 'max' => 4, |
|
| 34 | 4 | ]), |
|
| 35 | 4 | ]); |
|
| 36 | 4 | $metadata->addPropertyConstraints('correlativo', [ |
|
| 37 | 4 | new Assert\NotBlank(), |
|
| 38 | 4 | new Assert\Length(['max' => 8]), |
|
| 39 | 4 | ]); |
|
| 40 | 4 | $metadata->addPropertyConstraints('desMotivoBaja', [ |
|
| 41 | 4 | new Assert\NotBlank(), |
|
| 42 | 4 | new Assert\Length(['max' => 100]), |
|
| 43 | 4 | ]); |
|
| 44 | } |
||
| 45 | } |