[#3262] Mettre de l'ordre dans le dashboard
authorPA Parent <paparent@paparent.me>
Wed, 6 Jun 2012 19:21:43 +0000 (15:21 -0400)
committerPA Parent <paparent@paparent.me>
Wed, 6 Jun 2012 19:21:43 +0000 (15:21 -0400)
project/dashboard.py

index cad8b21..8ef431a 100644 (file)
@@ -17,23 +17,46 @@ from django.utils.translation import ugettext_lazy as _
 
 class CustomIndexDashboard(Dashboard):
     """
-    Custom index dashboard for SIGMA.
+    Custom index dashboard for SGRH.
     """
     def init_with_context(self, context):
 
         # append an app list module for "Applications"
-        self.children.append(modules.AppList(
+        self.children.append(modules.Group(
             _('Applications'),
-            models=(
-                'project.dae.models.*',
-                'project.recrutement.models.*',
-                'project.rh.models.AyantDroit',
-                'project.rh.models.Dossier',
-                'project.rh.models.DossierInactif',
-                'project.rh.models.Employe',
-                'project.rh.models.EmployeInactif',
-                'project.rh.models.Poste',
-            ),
+            display='stacked',
+            children=[
+                modules.ModelList(
+                    title='Demande d\'autorisation d\'engagement',
+                    models=(
+                        'project.dae.models.*',
+                    )
+                ),
+                modules.ModelList(
+                    title='Gestion des candidatures',
+                    models=(
+                        'auf.django.emploi.models.OffreEmploi',
+                        'project.recrutement.models.ProxyOffreEmploi',
+                        'auf.django.emploi.models.Candidat',
+                        'project.recrutement.models.ProxyCandidat',
+                        'project.recrutement.models.CandidatEvaluation',
+                        'project.recrutement.models.MesCandidatEvaluation',
+                        'project.recrutement.models.Evaluateur',
+                        'project.recrutement.models.CourrielTemplate',
+                    )
+                ),
+                modules.ModelList(
+                    title='Gestion des personnels',
+                    models=(
+                        'project.rh.models.AyantDroit',
+                        'project.rh.models.Dossier',
+                        'project.rh.models.DossierInactif',
+                        'project.rh.models.Employe',
+                        'project.rh.models.EmployeInactif',
+                        'project.rh.models.Poste',
+                    )
+                ),
+            ]
         ))
 
         # append an app list module for "Configuration"