is there a way to use the findAll()
function with conditions?
I want to do something like
->findAll('active'=1);
I know that i can write custom repository classes but just for a simple "where-condition" I thought there is an easier way.
You can use findBy
:
$objects = $yourRepo -> findBy(array('key' => $value ));
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With