-
I don't have a complete overview to create a validation for decimal types like the original from doc // Must have exactly two decimal places (9.99)...
'price' => 'decimal:2'
// Must have between 2 and 4 decimal places...
'price' => 'decimal:2,4' it's missing in new Attribute Validation class ( ex: Validate(min,max) ) |
Beta Was this translation helpful? Give feedback.
Answered by
Nir-An
Apr 26, 2023
Replies: 1 comment 2 replies
-
Hi @wit3 👍 you're always can use the #[Rule(['required', 'decimal:2,4'])]
public float $price |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
wit3
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi @wit3 👍
you're always can use the
rule
attribute