Browse Source

remove useless code

Thomas 14 years ago
parent
commit
7747b7fbd0
2 changed files with 4 additions and 9 deletions
  1. 3 8
      Controller/CRUDController.php
  2. 1 1
      Resources/views/standard_layout.html.twig

+ 3 - 8
Controller/CRUDController.php

@@ -277,15 +277,10 @@ class CRUDController extends Controller
      *
      * @return \Symfony\Component\HttpFoundation\Response
      */
-    public function createAction($id = null)
+    public function createAction()
     {
-        if ($id instanceof Form) {
-            $object = $id->getData();
-            $form = $id;
-        } else {
-            $object = $this->admin->getNewInstance();
-            $form = $this->admin->getForm($object);
-        }
+        $object = $this->admin->getNewInstance();
+        $form = $this->admin->getForm($object);
 
         $this->admin->setSubject($object);
 

+ 1 - 1
Resources/views/standard_layout.html.twig

@@ -144,7 +144,7 @@ file that was distributed with this source code.
 
             <!-- footer -->
             <div class="span-24 last">
-                        {% block footer %}{% endblock %}
+                {% block footer %}{% endblock %}
             </div>
         </div>
     </body>