Controller/WikiTagController.php
changeset 65 ba6b8e38d90e
parent 63 774ba82dca59
child 67 989d9e117586
--- a/Controller/WikiTagController.php	Wed Dec 14 23:53:37 2011 +0100
+++ b/Controller/WikiTagController.php	Mon Dec 19 17:50:04 2011 +0100
@@ -272,13 +272,15 @@
         
         try
         {
-            $this->get('wiki_tag.document')->addTag($id_doc, $tag_label);
+            $this->get('wiki_tag.document')->addTags($id_doc, $tag_label);
         }
         catch (WikiTagServiceException $e)
         {
             return new Response(json_encode(array('error' => $e->getErrorCode(), 'message' => $e->getMessage())),$e->getCode());
         }
+        $this->getDoctrine()->getEntityManager()->flush();
 
+        
         return $this->renderDocTags($id_doc, $this->getRequest()->request->get('wikitag_document_profile'));
     }