Sevajol Bastien 11 anni fa
parent
commit
68bbc176d4

+ 3 - 3
src/Muzich/CoreBundle/Tests/ElementFactory/ElementFactoryTest.php Vedi File

@@ -116,7 +116,7 @@ class ElementFactoryTest extends UnitTest
116 116
       array($hardtek->getId(), $tribe->getId()), 
117 117
       '<iframe frameborder="0" width="'.$this->getParam('dailymotion_player_width').'" '
118 118
         .'height="'.$this->getParam('dailymotion_player_height').'" '
119
-        .'src="http://www.dailymotion.com/embed/video/xafj1q"></iframe>'
119
+        .'src="http://www.dailymotion.com/embed/video/xafj1q?autoPlay=1"></iframe>'
120 120
     );
121 121
     
122 122
     /*
@@ -259,7 +259,7 @@ class ElementFactoryTest extends UnitTest
259 259
       'http://www.deezer.com/fr/music/pantera/far-beyond-driven-80398', 
260 260
       array($hardtek->getId(), $tribe->getId()), 
261 261
       '<iframe scrolling="no" frameborder="0" allowTransparency="true" '
262
-        .'src="http://www.deezer.com/fr/plugins/player?autoplay=false&playlist=true'
262
+        .'src="http://www.deezer.com/fr/plugins/player?autoplay=true&playlist=true'
263 263
         .'&width='.$this->getParam('deezer_player_width').'&height='
264 264
         .$this->getParam('deezer_player_height')
265 265
         .'&cover=true&btn_popup=true&type=album&id=80398&title=" '
@@ -274,7 +274,7 @@ class ElementFactoryTest extends UnitTest
274 274
       'http://www.deezer.com/fr/music/playlist/18701350', 
275 275
       array($hardtek->getId(), $tribe->getId()), 
276 276
       '<iframe scrolling="no" frameborder="0" allowTransparency="true" '
277
-        .'src="http://www.deezer.com/fr/plugins/player?autoplay=false&playlist=true'
277
+        .'src="http://www.deezer.com/fr/plugins/player?autoplay=true&playlist=true'
278 278
         .'&width='.$this->getParam('deezer_player_width').'&height='
279 279
         .$this->getParam('deezer_player_height')
280 280
         .'&cover=true&btn_popup=true&type=playlist&id=18701350&title=" '

+ 9 - 0
src/Muzich/CoreBundle/lib/Controller.php Vedi File

@@ -10,6 +10,7 @@ use Muzich\CoreBundle\Form\Element\ElementAddForm;
10 10
 use Symfony\Component\HttpFoundation\Response;
11 11
 use Muzich\CoreBundle\Searcher\GlobalSearcher;
12 12
 use Muzich\CoreBundle\Entity\Element;
13
+use Muzich\CoreBundle\Entity\Presubscription;
13 14
 
14 15
 class Controller extends BaseController
15 16
 {
@@ -492,4 +493,12 @@ class Controller extends BaseController
492 493
     return $groups;
493 494
   }
494 495
   
496
+  protected function getPreSubscriptionForm()
497
+  {
498
+    return $this->createFormBuilder(new Presubscription())
499
+      ->add('email', 'email')
500
+      ->getForm()
501
+    ;
502
+  }
503
+  
495 504
 }

+ 0 - 9
src/Muzich/IndexBundle/Controller/IndexController.php Vedi File

@@ -7,7 +7,6 @@ use Sensio\Bundle\FrameworkExtraBundle\Configuration\Template;
7 7
 use Symfony\Component\Security\Core\SecurityContext;
8 8
 use Symfony\Component\Validator\Constraints\Email;
9 9
 use Symfony\Component\Validator\Constraints\Collection;
10
-use Muzich\CoreBundle\Entity\Presubscription;
11 10
 use Symfony\Component\HttpFoundation\Request;
12 11
 
13 12
 class IndexController extends Controller
@@ -35,14 +34,6 @@ class IndexController extends Controller
35 34
     ));
36 35
   }
37 36
   
38
-  protected function getPreSubscriptionForm()
39
-  {
40
-    return $this->createFormBuilder(new Presubscription())
41
-      ->add('email', 'email')
42
-      ->getForm()
43
-    ;
44
-  }
45
-  
46 37
   /**
47 38
    * Gestion du formulaire d'identification sur la page d'index.
48 39
    * 

+ 2 - 1
src/Muzich/UserBundle/Controller/UserController.php Vedi File

@@ -215,7 +215,8 @@ class UserController extends Controller
215 215
         'registration_errors'      => $form->getErrors(),
216 216
         'registration_errors_pers' => $errors,
217 217
         'last_username'            => null,
218
-        'registration_page'        => true
218
+        'registration_page'        => true,
219
+        'presubscription_form'     => $this->getPreSubscriptionForm()->createView()
219 220
       )
220 221
     );
221 222
   }