19 lines
435 B
PHP
19 lines
435 B
PHP
<?php
|
|
|
|
namespace Cadoles\PortalBundle\Repository;
|
|
|
|
use Doctrine\ORM\EntityRepository;
|
|
|
|
class WidgetRepository extends EntityRepository
|
|
{
|
|
// getWidgetAccess
|
|
public function getWidgetAccess($access)
|
|
{
|
|
$qb = $this->createQueryBuilder("widget");
|
|
$qb ->where($qb->expr()->like('widget.access', $qb->expr()->literal("%$access%")));
|
|
$widgets=$qb->getQuery()->getResult();
|
|
|
|
return $widgets;
|
|
}
|
|
}
|