Hello people, good evening. I’m trying to do the following validation:
-
Se tipo_pessoa find is PF, enable cpf field and add the required validation for it
1.2 Disable cnpj field and clear its validation
-
Se tipo_pessoa field is PJ, enable cnpj field and add the required validation for it
2.1 Disable npf field and clear its validation
In other hands, i’m getting an error explained in the image. Aparentely the logic is right, but for some reason something is wrong.
Could someone help me in this issue?
See code here
Solution here!
Well, the solution is above.