From 255ed9432dfe3a3ed21a44fb26c16de963524356 Mon Sep 17 00:00:00 2001
From: Jonathan Foucher <jfoucher@gmail.com>
Date: Tue, 14 Mar 2023 15:21:45 +0100
Subject: [PATCH] Fix https://gitlab.adullact.net/soluris/madis/-/issues/639

---
 config/domain/notification/translations/messages.fr.yaml      | 2 +-
 src/Domain/Notification/Controller/NotificationController.php | 2 +-
 .../Notification/Dictionary/NotificationModuleDictionary.php  | 2 +-
 templates/Notification/Notification/list.html.twig            | 4 ++--
 4 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/config/domain/notification/translations/messages.fr.yaml b/config/domain/notification/translations/messages.fr.yaml
index fd50846df..748eba46c 100644
--- a/config/domain/notification/translations/messages.fr.yaml
+++ b/config/domain/notification/translations/messages.fr.yaml
@@ -6,7 +6,7 @@ notifications:
         subcontractor: Sous-traitants
         violation: Violations
         proof: Preuves
-        document: Document
+        document: Espace documentaire
         action: Actions de protection
         protect_action: Actions de protection
         request: Demandes
diff --git a/src/Domain/Notification/Controller/NotificationController.php b/src/Domain/Notification/Controller/NotificationController.php
index 431d9dc72..e901ad3f4 100644
--- a/src/Domain/Notification/Controller/NotificationController.php
+++ b/src/Domain/Notification/Controller/NotificationController.php
@@ -174,7 +174,7 @@ class NotificationController extends CRUDController
 
             $nameHtml = '<span>' . $notification->getName() . '</span> ';
 
-            if ($link && 'notifications.actions.delete' !== $notification->getAction()) {
+            if ($link && 'notification.actions.delete' !== $notification->getAction()) {
                 $nameHtml = '<a href="' . $link . '">' . $notification->getName() . '</a>'
                 ;
             }
diff --git a/src/Domain/Notification/Dictionary/NotificationModuleDictionary.php b/src/Domain/Notification/Dictionary/NotificationModuleDictionary.php
index 0d31f6029..04af083c7 100644
--- a/src/Domain/Notification/Dictionary/NotificationModuleDictionary.php
+++ b/src/Domain/Notification/Dictionary/NotificationModuleDictionary.php
@@ -63,7 +63,7 @@ class NotificationModuleDictionary extends SimpleDictionary
             Notification::MODULES[ConformiteTraitement::class] => 'Conformité du traitement',
             Notification::MODULES[Conformite::class]           => 'Conformité de la structure',
             Notification::MODULES[AnalyseImpact::class]        => 'Analyse d\'impact',
-            Notification::MODULES[Document::class]             => 'Document',
+            Notification::MODULES[Document::class]             => 'Espace Documentaire',
             'user'                                             => 'Utilisateurs',
         ];
     }
diff --git a/templates/Notification/Notification/list.html.twig b/templates/Notification/Notification/list.html.twig
index 227a91212..770eac8c1 100644
--- a/templates/Notification/Notification/list.html.twig
+++ b/templates/Notification/Notification/list.html.twig
@@ -22,7 +22,6 @@
 {% endblock %}
 
 {% block body %}
-    <div class="dt-button-background" style=""></div>
     <div class="row">
         <div class="col-xs-12">
             <div class="box box-solid">
@@ -138,7 +137,7 @@
         dom: 'Bfrtip',
         columnDefs: [
             {
-                targets: 4,
+                targets: 10,
                 className: 'noVis'
             }
         ],
@@ -245,6 +244,7 @@
 
 
     $('#table').on('column-visibility.dt', function() {
+        console.log('set events')
         setEvents();
     } );
 
-- 
GitLab