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.
34 lines
797 B
34 lines
797 B
<?php
|
|
/* For licensing terms, see /license.txt */
|
|
|
|
namespace Chamilo\CoreBundle\Controller;
|
|
|
|
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Template;
|
|
use Symfony\Component\HttpFoundation\Response;
|
|
use Symfony\Component\Routing\Annotation\Route;
|
|
|
|
/**
|
|
* Class UserController.
|
|
*
|
|
* @Route("/user")
|
|
*
|
|
* @author Julio Montoya <gugli100@gmail.com>
|
|
*/
|
|
class UserController extends BaseController
|
|
{
|
|
/**
|
|
* @Route("/{username}", methods={"GET"})
|
|
*
|
|
* @param string $username
|
|
*
|
|
* @Template("ChamiloCoreBundle:User:profile.html.twig")
|
|
*
|
|
* @return Response
|
|
*/
|
|
public function profileAction($username): array
|
|
{
|
|
$user = $this->container->get('fos_user.user_manager')->findUserByUsername($username);
|
|
|
|
return ['user' => $user];
|
|
}
|
|
}
|
|
|