Chamilo is a learning management system focused on ease of use and accessibility
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
chamilo-lms/src/CoreBundle/Repository/LanguageRepository.php

34 lines
737 B

<?php
/* For licensing terms, see /license.txt */
namespace Chamilo\CoreBundle\Repository;
use Doctrine\ORM\EntityRepository;
/**
* Class LanguageRepository.
*
* @package Chamilo\CoreBundle\Repository
*/
class LanguageRepository extends EntityRepository
{
/**
* Get all the sub languages that are made available by the admin.
*
* @return array
*/
public function findAllPlatformSubLanguages()
{
$qb = $this->createQueryBuilder('l');
$qb->select('l')
->where(
$qb->expr()->eq('l.available', true)
)
->andWhere(
$qb->expr()->isNotNull('l.parent')
);
return $qb->getQuery()->getResult();
}
}