public function isRecordInPublicFeed($sbas_id, $record_id)
    {
        $dql = 'SELECT COUNT(i)
            FROM Phraseanet:FeedItem i
            JOIN i.entry e
            JOIN e.feed f
            WHERE i.sbasId = :sbas_id
                AND i.recordId = :record_id
                AND f.public = true';

        $query = $this->_em->createQuery($dql);
        $query->setParameters(['sbas_id' => $sbas_id, 'record_id' => $record_id]);

        return $query->getSingleScalarResult() > 0;
    }
public function isRecordInPublicFeed($sbas_id, $record_id)
    {
        $dql = 'SELECT COUNT(i)
            FROM Phraseanet:FeedItem i
            JOIN i.entry e
            JOIN e.feed f
            WHERE i.sbasId = :sbas_id
                AND i.recordId = :record_id
                AND f.public = true';

        $query = $this->_em->createQuery($dql);
        $query->setParameters(['sbas_id' => $sbas_id, 'record_id' => $record_id]);

        return $query->getSingleScalarResult() > 0;
    }
public function isRecordInPublicFeed ( $ sbas_id , $ record_id ) { $ dql = 'SELECT COUNT(i)
            FROM Phraseanet:FeedItem i
            JOIN i.entry e
            JOIN e.feed f
            WHERE i.sbasId = :sbas_id
                AND i.recordId = :record_id
                AND f.public = true' ; $ query = $ this -> _em -> createQuery ( $ dql ) ; $ query -> setParameters ( [ 'sbas_id' => $ sbas_id , 'record_id' => $ record_id ] ) ; return $ query -> getSingleScalarResult ( ) > 0 ; }
Checks if a record is published in a public feed.

@param int $sbas_id
@param int $record_id

@return bool
Checks if a record is published in a public feed .