Commit 673647f5 authored by arnaudbey's avatar arnaudbey

sensio fixes

parent 1345e911
......@@ -3,10 +3,8 @@
namespace MagicWordBundle\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Symfony\Component\HttpFoundation\Response;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\ParamConverter;
use Innova\LexiconBundle\Entity\Lemma;
use Innova\LexiconBundle\Entity\Language;
use MagicWordBundle\Entity\FoundableForm;
......
......@@ -60,7 +60,7 @@ class GameController extends Controller
* @Route("/game/import", name="json_import_form")
* @Method("GET")
*/
public function jsonImportForm()
public function jsonImportFormAction()
{
return $this->render('MagicWordBundle:Game:import.html.twig');
}
......@@ -69,7 +69,7 @@ class GameController extends Controller
* @Route("/game/import", name="json_import", options={"expose"=true})
* @Method("POST")
*/
public function jsonImport(Request $request)
public function jsonImportAction(Request $request)
{
$json = $request->get('json');
......
......@@ -55,9 +55,6 @@ class GridPatternController extends Controller
public function savePatternAction(GridPattern $gridPattern, Request $request)
{
$this->get('mw_manager.grid_pattern')->save($gridPattern, $request);
$form = $this->get('mw_manager.grid_pattern')->getForm($gridPattern);
$template = $this->get('templating')->render('MagicWordBundle:Grid:grid-pattern-edit.html.twig', array('form' => $form, 'pattern' => $gridPattern ));
return new JsonResponse();
}
......
......@@ -3,7 +3,6 @@
namespace MagicWordBundle\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Symfony\Component\HttpFoundation\Response;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Method;
......
......@@ -31,7 +31,7 @@ class Square
public function setId($id)
{
if ($id >=1 and $id <=16) {
if ($id >=1 && $id <=16) {
$this->_idCase = $id;
}
}
......
......@@ -6,7 +6,6 @@ use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolver;
use Symfony\Component\Form\Extension\Core\Type\TextType;
use Symfony\Component\Form\Extension\Core\Type\SubmitType;
class GridPatternStringType extends AbstractType
{
......
......@@ -5,8 +5,6 @@ namespace MagicWordBundle\Form\Type;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolver;
use Symfony\Component\Form\Extension\Core\Type\IntegerType;
use Symfony\Component\Form\Extension\Core\Type\SubmitType;
use MagicWordBundle\Form\Type\GridPatternStringType;
use Symfony\Component\Form\Extension\Core\Type\TextType;
use Symfony\Component\Form\Extension\Core\Type\TextareaType;
......
......@@ -9,12 +9,10 @@ use Symfony\Component\EventDispatcher\EventSubscriberInterface;
class LocaleListener implements EventSubscriberInterface
{
private $defaultLocale;
private $tokenStorage;
public function __construct($defaultLocale = 'fr', $tokenStorage)
public function __construct($defaultLocale = 'fr')
{
$this->defaultLocale = $defaultLocale;
$this->tokenStorage = $tokenStorage;
}
public function onKernelRequest(GetResponseEvent $event)
......
......@@ -3,7 +3,6 @@
namespace MagicWordBundle\Manager;
use JMS\DiExtraBundle\Annotation as DI;
use MagicWordBundle\Entity\Grid;
use MagicWordBundle\Entity\Round;
use MagicWordBundle\Entity\GameType\Massive;
......
......@@ -3,7 +3,6 @@
namespace MagicWordBundle\Manager\Letter;
use JMS\DiExtraBundle\Annotation as DI;
use Innova\LexiconBundle\Entity\Language;
use MagicWordBundle\Entity\Bigram\Grille;
/**
......
......@@ -3,7 +3,6 @@
namespace MagicWordBundle\Twig;
use MagicWordBundle\Entity\Round;
use MagicWordBundle\Entity\Player;
class GeneralParametersExtension extends \Twig_Extension
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment