Browse Source

Anomalie #137: Ajout d'un élément a un groupe

bastien 12 years ago
parent
commit
a8632a5fe2
1 changed files with 19 additions and 4 deletions
  1. 19 4
      src/Muzich/CoreBundle/Controller/CoreController.php

+ 19 - 4
src/Muzich/CoreBundle/Controller/CoreController.php View File

@@ -225,10 +225,25 @@ class CoreController extends Controller
225 225
       if ($this->getRequest()->isXmlHttpRequest())
226 226
       {
227 227
         // Récupération du li
228
-        $html = $this->render('MuzichCoreBundle:SearchElement:li.element.html.twig', array(
229
-          'element'     => $element,
230
-          'class_color' => 'odd'
231
-        ))->getContent();
228
+        if (!$group)
229
+        {
230
+          $html = $this->render('MuzichCoreBundle:SearchElement:li.element.html.twig', array(
231
+            'element'     => $element,
232
+            'class_color' => 'odd'
233
+          ))->getContent();
234
+        }
235
+         else 
236
+        {
237
+          $html = $this->render('MuzichCoreBundle:SearchElement:li.element.html.twig', array(
238
+            'element'     => $element,
239
+            'class_color' => 'odd',
240
+            'no_group_name' => true
241
+          ))->getContent();
242
+        }
243
+
244
+        
245
+        
246
+        
232 247
         
233 248
         return $this->jsonResponse(array(
234 249
           'status' => 'success',