How to validate data with in_list inside model |
I am trying to do clean-up in my controllers by moving my validation rules to the model class but unfortunately i came to realize there is no clear documentation on how to pass values to be tested into the validation rules. I have been searching for a solution without luck.
NB: the in_list values are expected to come from the database, so the list is dynamic PHP Code: protected $validationRules = [
I think that's what the is_not_unique method is for.
PHP Code: protected $validationRules = [
|
Welcome Guest, Not a member yet? Register Sign In |