Answer the question
In order to leave comments, you need to log in
Yii2 - is there an event "after successful" and "after unsuccessful" validation?
I am doing a behavior and there is a need for events: "after successful" and "after not
unsuccessful" validation
ActiveRecord::EVENT_AFTER_VALIDATE
ActiveRecord::EVENT_BEFORE_VALIDATE
Answer the question
In order to leave comments, you need to log in
All this can be hung up on `afterValidate` and choose where to write, already there.
You can also write a log in the validator of the correct login and password.
Although, offhand, writing to the database from the validator does not look like a very good idea.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question