EcommerceBundle/Controller/ContractController.php
public function newAction()
    {
        $entity = new Contract();
        $form   = $this->createCreateForm($entity);

        $planForm = $this->createForm(new PlanType(), new Plan(), array(
            'action' => $this->generateUrl('ecommerce_plan_new'),
            'method' => 'POST',
        ));
        
        return array(
            'entity' => $entity,
            'form'   => $form->createView(),
            'planForm' => $planForm->createView(),
        );
    }
public function newAction()
    {
        $entity = new Contract();
        $form   = $this->createCreateForm($entity);

        $planForm = $this->createForm(new PlanType(), new Plan(), array(
            'action' => $this->generateUrl('ecommerce_plan_new'),
            'method' => 'POST',
        ));
        
        return array(
            'entity' => $entity,
            'form'   => $form->createView(),
            'planForm' => $planForm->createView(),
        );
    }
public function newAction ( ) { $ entity = new Contract ( ) ; $ form = $ this -> createCreateForm ( $ entity ) ; $ planForm = $ this -> createForm ( new PlanType ( ) , new Plan ( ) , array ( 'action' => $ this -> generateUrl ( 'ecommerce_plan_new' ) , 'method' => 'POST' , ) ) ; return array ( 'entity' => $ entity , 'form' => $ form -> createView ( ) , 'planForm' => $ planForm -> createView ( ) , ) ; }
Displays a form to create a new Contract entity.

@Route("/new")
@Method("GET")
@Template()
Displays a form to create a new Contract entity .