[FEATURE] New TCA displayCond options BIT and !BIT
[Packages/TYPO3.CMS.git] / typo3 / sysext / backend / Classes / Form / ElementConditionMatcher.php
index eae870b..6486814 100644 (file)
@@ -240,6 +240,13 @@ class ElementConditionMatcher {
                                        $result = !$result;
                                }
                                break;
+                       case 'BIT':
+                       case '!BIT':
+                               $result = (intval($fieldValue) & $operand) ? TRUE : FALSE;
+                               if ($operator{0} === '!') {
+                                       $result = !$result;
+                               }
+                               break;
                }
                return $result;
        }
@@ -336,4 +343,4 @@ class ElementConditionMatcher {
        }
 }
 
-?>
\ No newline at end of file
+?>