Moving Validation out of model

I have a big method validation() beacause i validate many fields, how i can move this validation to another file ?



30.0k
edited May '15

Hi,

maybe you will find inspiration here

I dont mean creating new validators - i dont have problem with that. I mean that in validation() method in my model i have many $this->validate() for many fields and i want to move it to another file, is it possible to use trait for example ?