Rails Validations - Reverse of Confirmation Validation -


I have to make sure that the two attributes do not have the same value with verification in my Rails4 application. I know about confirmation verification, but I want exactly the opposite.

Is this kind of railroad recognition?

You need to create a custom verification that I believe:

 < Code> validate: check_edit1 and_datite2def def_attribute1_and_attribute2 if attribute_1 == attribute_2 errors.add (hopefully: column_2, 'value can not be equal to value 1!') And end   

hope Does that help :)

Comments

Popular posts from this blog

c - Mpirun hangs when mpi send and recieve is put in a loop -

python - Apply coupon to a customer's subscription based on non-stripe related actions on the site -

java - Unable to get JDBC connection in Spring application to MySQL -