예제 #1
0
 public function addAction()
 {
     if ($this->request->isPost()) {
         $this->seoForm->setData($this->request->getPost());
         if ($this->seoForm->isValid()) {
             $this->seoService->add($this->seoForm->getData());
             $this->flashMessenger()->addSuccessMessage("Seo record has been successfully created");
             return $this->redirect()->toRoute('seo', array('action' => 'list'));
         }
     }
     return array('form' => $this->seoForm);
 }