PHP 클래스 Newscoop\NewscoopBundle\Entity\Repository\TopicRepository

상속: extends Gedmo\Tree\Entity\Repository\NestedTreeRepository
파일 보기 프로젝트 열기: sourcefabric/newscoop

공개 프로퍼티들

프로퍼티 타입 설명
$onChildrenQuery

공개 메소드들

메소드 설명
childrenQuery ( $node = null, $direct = false, $sortByField = null, $direction = 'ASC', $include = false ) Will do reordering based on current translations.
childrenWithTranslations ( $node = null, $locale = null, $direct = false, $sortByField = null, $direction = 'ASC', $includeNode = false, $start = null, $limit = null )
countBy ( array $criteria = [] ) : integer Count topics by given criteria.
findAllParentChoices ( Topic $node = null ) : array Get all parent choices.
findOptions ( ) : array Find topic options.
getArticleTopics ( integer $articleNr, string $languageCode, string $order = 'asc' ) : Doctrine\ORM\Query Get Topics for Article.
getArticlesQueryByTopicIdAndLanguage ( integer $topicId, string $languageCode, boolean $defaultFallback = false ) : Doctrine\ORM\Query Get all articles for given topic by topic id and language code.
getOneByExtractedFullName ( $name, $languageCode )
getReadablePath ( Topic $topic, $locale = null ) : string Gets topic's path.
getRootNodes ( $locale = null, $childrenLevel = false, $sortByField = null, $direction = 'asc' ) {@inheritDoc}
getSingleTopicQuery ( integer $id, string $locale = null ) : Doctrine\ORM\Query Gets the single topic's query by id.
getTopicByIdOrName ( string | integer $topicIdOrName, string | integer $locale = null ) : Doctrine\ORM\Query Gets topic by given id or name.
getTopics ( $languageCode = null ) : Doctrine\ORM\Query Get all topics.
getTopicsQuery ( $direction = 'ASC' )
getTranslatableTopicLocale ( Topic $topic )
getTranslatableTopics ( $locale, $order = 'asc' ) Get topics query and set translatable hints.
searchTopics ( string $query, array $sort = [], $limit = null, $locale = null ) : Doctrine\ORM\Query Search topic by given query.
setTranslatableHint ( Doctrine\ORM\Query $query, string | null $locale = null ) : Doctrine\ORM\Query Add hints to the query.

메소드 상세

childrenQuery() 공개 메소드

Will do reordering based on current translations.
public childrenQuery ( $node = null, $direct = false, $sortByField = null, $direction = 'ASC', $include = false )

childrenWithTranslations() 공개 메소드

또한 보기: getChildrenQueryBuilder
public childrenWithTranslations ( $node = null, $locale = null, $direct = false, $sortByField = null, $direction = 'ASC', $includeNode = false, $start = null, $limit = null )

countBy() 공개 메소드

Count topics by given criteria.
public countBy ( array $criteria = [] ) : integer
$criteria array
리턴 integer

findAllParentChoices() 공개 메소드

Get all parent choices.
public findAllParentChoices ( Topic $node = null ) : array
$node Newscoop\NewscoopBundle\Entity\Topic Topic object
리턴 array

findOptions() 공개 메소드

Find topic options.
public findOptions ( ) : array
리턴 array

getArticleTopics() 공개 메소드

Returns all the associated Topics to an Article.
public getArticleTopics ( integer $articleNr, string $languageCode, string $order = 'asc' ) : Doctrine\ORM\Query
$articleNr integer Article number
$languageCode string Language code in format "en" for example.
$order string Order of the topics, default ascending
리턴 Doctrine\ORM\Query Query

getArticlesQueryByTopicIdAndLanguage() 공개 메소드

Get all articles for given topic by topic id and language code.
public getArticlesQueryByTopicIdAndLanguage ( integer $topicId, string $languageCode, boolean $defaultFallback = false ) : Doctrine\ORM\Query
$topicId integer Topic id
$languageCode string Language code
$defaultFallback boolean Sets the language of the topic to the default one
리턴 Doctrine\ORM\Query

getOneByExtractedFullName() 공개 메소드

public getOneByExtractedFullName ( $name, $languageCode )

getReadablePath() 공개 메소드

Gets topic's path.
public getReadablePath ( Topic $topic, $locale = null ) : string
$topic Newscoop\NewscoopBundle\Entity\Topic Topic
리턴 string Path of the topic

getRootNodes() 공개 메소드

{@inheritDoc}
public getRootNodes ( $locale = null, $childrenLevel = false, $sortByField = null, $direction = 'asc' )

getSingleTopicQuery() 공개 메소드

Gets the single topic's query by id.
public getSingleTopicQuery ( integer $id, string $locale = null ) : Doctrine\ORM\Query
$id integer Topic id
$locale string Language code
리턴 Doctrine\ORM\Query $query Query object

getTopicByIdOrName() 공개 메소드

Gets topic by given id or name.
public getTopicByIdOrName ( string | integer $topicIdOrName, string | integer $locale = null ) : Doctrine\ORM\Query
$topicIdOrName string | integer Topicid or name
$locale string | integer Current locale, language code or id
리턴 Doctrine\ORM\Query

getTopics() 공개 메소드

Get all topics.
public getTopics ( $languageCode = null ) : Doctrine\ORM\Query
$languageCode Language code
리턴 Doctrine\ORM\Query

getTopicsQuery() 공개 메소드

public getTopicsQuery ( $direction = 'ASC' )

getTranslatableTopicLocale() 공개 메소드

public getTranslatableTopicLocale ( Topic $topic )
$topic Newscoop\NewscoopBundle\Entity\Topic

getTranslatableTopics() 공개 메소드

Get topics query and set translatable hints.
public getTranslatableTopics ( $locale, $order = 'asc' )

searchTopics() 공개 메소드

Search topic by given query.
public searchTopics ( string $query, array $sort = [], $limit = null, $locale = null ) : Doctrine\ORM\Query
$query string
$sort array
리턴 Doctrine\ORM\Query

setTranslatableHint() 공개 메소드

Add hints to the query.
public setTranslatableHint ( Doctrine\ORM\Query $query, string | null $locale = null ) : Doctrine\ORM\Query
$query Doctrine\ORM\Query Query
$locale string | null Lecale to which fallback
리턴 Doctrine\ORM\Query

프로퍼티 상세

$onChildrenQuery 공개적으로 프로퍼티

public $onChildrenQuery