在Symfony Doctrine Query Builder中选择具有x标签的产品

I need your help.

Situation:

I have two entity Products and Tags.(many to many) For example I have product "car" which have tags: "red" and "sport" Next I have search form with checkbox for tags, user can select tag red or sport or both and click search. After that I want have product which have one or more selected tags.

I want to use query builder but I dont know What I should to do?

>$category= $form->get('category')->getData();

>$tags = $form->get('tags')->getData();

>$repository = $this->getDoctrine()->getRepository('AppBundle:Product');

>$qb = $repository->createQueryBuilder('p')
->select('p, t, c')
->leftJoin('p.category', 'c')
->leftJoin('p.tags', 't');

//for category

>if(isset($category) && $category!= NULL){
$qb->andWhere('c.slug = :category')
->setParameter('category', $category->getSlug());
}

//for tags ???

What next? Please help me.

Try this:

$qb
    ->select('p, t, c')
    // ...
    ->andWhere('t IN (:tags)')
    ->setParameter('tags', $tags);

Thank you @MateuszMal for the correction.