<?php
namespace App\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Routing\Annotation\Route;
use App\Lib\Services\Enovia;
class MainController extends YAITSController
{
/**F
* @var Enovia
*/
private $enovia;
/**
* MainController constructor.
* @param SessionInterface $session
* @param Enovia $enovia
*/
public function __construct(SessionInterface $session, Enovia $enovia)
{
$this->enovia = $enovia;
parent::__construct($session);
}
/**
* @Route("/", name="main")
*/
public function index()
{
$me = $this->session->get("me");
$cs = $this->enovia->getCollabspaces($this->getParameter("tenant"));
$this->session->set("cs", $cs->items);
// $this->enovia->uploadFileTo3DDrive($this->getParameter("tenant"), "67-00100-FCS-20200415-145834.log");
$parameters = $this->conf->getProperty("parameters");
$bigram = $me->firstName[0] . $me->lastName[0];
return $this->render('main/index.html.twig', [
'bigram' => $bigram,
'multiuser' => $parameters["multiuser"]
]);
}
}