src/Flowcode/ShopBundle/Controller/ShopSettingController.php
public function createAction(Request $request)
    {
        $shopSetting = new ShopSetting();
        $form = $this->createForm(new ShopSettingType(), $shopSetting);
        if ($form->handleRequest($request)->isValid()) {
            $em = $this->getDoctrine()->getManager();
            $em->persist($shopSetting);
            $em->flush();

            return $this->redirect($this->generateUrl('admin_amulen_shop_setting_show', array('id' => $shopSetting->getId())));
        }

        return array(
            'shopSetting' => $shopSetting,
            'form' => $form->createView(),
        );
    }
public function createAction(Request $request)
    {
        $shopSetting = new ShopSetting();
        $form = $this->createForm(new ShopSettingType(), $shopSetting);
        if ($form->handleRequest($request)->isValid()) {
            $em = $this->getDoctrine()->getManager();
            $em->persist($shopSetting);
            $em->flush();

            return $this->redirect($this->generateUrl('admin_amulen_shop_setting_show', array('id' => $shopSetting->getId())));
        }

        return array(
            'shopSetting' => $shopSetting,
            'form' => $form->createView(),
        );
    }
public function createAction ( Request $ request ) { $ shopSetting = new ShopSetting ( ) ; $ form = $ this -> createForm ( new ShopSettingType ( ) , $ shopSetting ) ; if ( $ form -> handleRequest ( $ request ) -> isValid ( ) ) { $ em = $ this -> getDoctrine ( ) -> getManager ( ) ; $ em -> persist ( $ shopSetting ) ; $ em -> flush ( ) ; return $ this -> redirect ( $ this -> generateUrl ( 'admin_amulen_shop_setting_show' , array ( 'id' => $ shopSetting -> getId ( ) ) ) ) ; } return array ( 'shopSetting' => $ shopSetting , 'form' => $ form -> createView ( ) , ) ; }
Creates a new ShopSetting entity.

@Route("/create", name="admin_amulen_shop_setting_create")
@Method("POST")
@Template("FlowcodeShopBundle:ShopSetting:new.html.twig")
Creates a new ShopSetting entity .