From 774d0d0293404569a5a63c55be83bd759ae2586a Mon Sep 17 00:00:00 2001
From: "a.schindlbeck" <a.schindlbeck@adito.de>
Date: Thu, 13 Aug 2020 11:34:06 +0200
Subject: [PATCH] #1060652 Favorites: filterExtensions fixes

---
 entity/Favorite_entity/Favorite_entity.aod             |  1 -
 .../jditorecordcontainer/contentProcess.js             | 10 +++++++++-
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/entity/Favorite_entity/Favorite_entity.aod b/entity/Favorite_entity/Favorite_entity.aod
index 431adf82e4..58fde656e8 100644
--- a/entity/Favorite_entity/Favorite_entity.aod
+++ b/entity/Favorite_entity/Favorite_entity.aod
@@ -105,7 +105,6 @@
           <title>Titel</title>
           <contentType>TEXT</contentType>
           <filterValuesProcess>%aditoprj%/entity/Favorite_entity/recordcontainers/jditorecordcontainer/filterextensions/grouptitleextension/filterValuesProcess.js</filterValuesProcess>
-          <isLookupFilter v="false" />
           <filtertype>BASIC</filtertype>
         </filterExtension>
         <filterExtension>
diff --git a/entity/Favorite_entity/recordcontainers/jditorecordcontainer/contentProcess.js b/entity/Favorite_entity/recordcontainers/jditorecordcontainer/contentProcess.js
index f11203501b..183c191aca 100644
--- a/entity/Favorite_entity/recordcontainers/jditorecordcontainer/contentProcess.js
+++ b/entity/Favorite_entity/recordcontainers/jditorecordcontainer/contentProcess.js
@@ -68,7 +68,7 @@ function isFiltered(filters, fav)
         }
         if(filters[i]["name"].includes("groupGroupNameExtension"))
         {
-            if(!isValid(favoObjectType, filters[i]))
+            if(!isValid(favoGroupName, filters[i]))
             {
                 isFiltered = false;
                 break;
@@ -88,8 +88,16 @@ function isValid(value, filter)
     {
         case "EQUAL":
             return value.equals(filterValue);
+        case "NOT_EQUAL":
+            return !value.equals(filterValue);
         case "CONTAINS":
             return value.includes(filterValue);
+        case "NOT_CONTAINS":
+            return !value.includes(filterValue);
+        case "ISNULL":
+            return value == null;
+        case "ISNOTNULL":
+            return value != null;
     }
     
     return false;
-- 
GitLab