<?php
/**
 * Created by PhpStorm.
 * User: danielknudsen
 * Date: 03.05.18
 * Time: 16:43
 */

namespace App\Utils;


use App\Entity\EntCadasterGlassSurfaceEntry;
use App\Entity\EntCadasterLocalizationEntry;
use App\Entity\EntCadasterTreeEntry;
use App\Entity\EntCountry;
use App\Entity\EntLocationObject;
use App\Entity\EntQualityRequirementRoom;
use App\Entity\EntUserType;
use Doctrine\Common\Persistence\ObjectManager;

class Config
{
    /**
     * Returns api config
     * @param ObjectManager $em
     * @return array
     */
    public static function getConfig(ObjectManager $em)
    {
        return [
            'users' => Utils::clientMap($em, $em->getRepository('App:EntUser')->findBy(['visible' => true])),
            'meeting_types' => Utils::clientMap($em, $em->getRepository('App:EntMeetingType')->findAll()),
            'countries' => Utils::clientMap($em, $em->getRepository('App:EntCountry')->findAll()),
        ];
    }

}