‪TYPO3CMS  ‪main
EvaluateDisplayConditionsTest.php
Go to the documentation of this file.
1 <?php
2 
3 declare(strict_types=1);
4 
5 /*
6  * This file is part of the TYPO3 CMS project.
7  *
8  * It is free software; you can redistribute it and/or modify it under
9  * the terms of the GNU General Public License, either version 2
10  * of the License, or any later version.
11  *
12  * For the full copyright and license information, please read the
13  * LICENSE.txt file that was distributed with this source code.
14  *
15  * The TYPO3 project - inspiring people to share!
16  */
17 
19 
20 use PHPUnit\Framework\Attributes\DataProvider;
21 use PHPUnit\Framework\Attributes\Test;
26 use TYPO3\TestingFramework\Core\Unit\UnitTestCase;
27 
28 final class ‪EvaluateDisplayConditionsTest extends UnitTestCase
29 {
30  #[Test]
32  {
33  $input = [
34  'databaseRow' => [],
35  'processedTca' => [
36  'columns' => [
37  'field_1' => [
38  'displayCond' => [
39  'FOO' => [
40  'condition1',
41  'condition2',
42  ],
43  ],
44  ],
45  ],
46  ],
47  ];
48  $this->expectException(\RuntimeException::class);
49  $this->expectExceptionCode(1481380393);
50  (new ‪EvaluateDisplayConditions())->addData($input);
51  }
52 
53  #[Test]
55  {
56  $input = [
57  'databaseRow' => [],
58  'processedTca' => [
59  'columns' => [
60  'field_1' => [
61  'displayCond' => [
62  ['condition1'],
63  ],
64  ],
65  ],
66  ],
67  ];
68  $this->expectException(\RuntimeException::class);
69  $this->expectExceptionCode(1481380393);
70  (new ‪EvaluateDisplayConditions())->addData($input);
71  }
72 
73  #[Test]
75  {
76  $input = [
77  'databaseRow' => [],
78  'processedTca' => [
79  'columns' => [
80  'field_1' => [
81  'displayCond' => false,
82  ],
83  ],
84  ],
85  ];
86  $this->expectException(\RuntimeException::class);
87  $this->expectExceptionCode(1481381058);
88  (new ‪EvaluateDisplayConditions())->addData($input);
89  }
90 
91  #[Test]
93  {
94  $input = [
95  'databaseRow' => [],
96  'processedTca' => [
97  'columns' => [
98  'field_1' => [
99  'displayCond' => 'foo',
100  ],
101  ],
102  ],
103  ];
104  $this->expectException(\RuntimeException::class);
105  $this->expectExceptionCode(1481381950);
106  (new ‪EvaluateDisplayConditions())->addData($input);
107  }
108 
109  #[Test]
111  {
112  $input = [
113  'databaseRow' => [],
114  'processedTca' => [
115  'columns' => [
116  'field_1' => [
117  'displayCond' => 'FIELD',
118  ],
119  ],
120  ],
121  ];
122  $this->expectException(\RuntimeException::class);
123  $this->expectExceptionCode(1481385695);
124  (new ‪EvaluateDisplayConditions())->addData($input);
125  }
126 
127  #[Test]
129  {
130  $input = [
131  'databaseRow' => [],
132  'processedTca' => [
133  'columns' => [
134  'field_1' => [
135  'displayCond' => 'FIELD:fieldName',
136  ],
137  ],
138  ],
139  ];
140  $this->expectException(\RuntimeException::class);
141  $this->expectExceptionCode(1481386239);
142  (new ‪EvaluateDisplayConditions())->addData($input);
143  }
144 
145  #[Test]
147  {
148  $input = [
149  'databaseRow' => [],
150  'processedTca' => [
151  'columns' => [
152  'field_1' => [
153  'displayCond' => 'FIELD:fieldName:foo',
154  ],
155  ],
156  ],
157  ];
158  $this->expectException(\RuntimeException::class);
159  $this->expectExceptionCode(1481386239);
160  (new ‪EvaluateDisplayConditions())->addData($input);
161  }
162 
163  #[Test]
165  {
166  $input = [
167  'databaseRow' => [],
168  'processedTca' => [
169  'columns' => [
170  'field_1' => [
171  'displayCond' => 'FIELD:fieldName:REQ',
172  ],
173  ],
174  ],
175  ];
176  $this->expectException(\RuntimeException::class);
177  $this->expectExceptionCode(1481401543);
178  (new ‪EvaluateDisplayConditions())->addData($input);
179  }
180 
181  #[Test]
183  {
184  $input = [
185  'databaseRow' => [],
186  'processedTca' => [
187  'columns' => [
188  'field_1' => [
189  'displayCond' => 'FIELD:fieldName:REQ:foo',
190  ],
191  ],
192  ],
193  ];
194  $this->expectException(\RuntimeException::class);
195  $this->expectExceptionCode(1481401892);
196  (new ‪EvaluateDisplayConditions())->addData($input);
197  }
198 
199  #[Test]
201  {
202  $input = [
203  'databaseRow' => [],
204  'processedTca' => [
205  'columns' => [
206  'field_1' => [
207  'displayCond' => 'FIELD:fieldName:>=:foo',
208  ],
209  ],
210  ],
211  ];
212  $this->expectException(\RuntimeException::class);
213  $this->expectExceptionCode(1481456806);
214  (new ‪EvaluateDisplayConditions())->addData($input);
215  }
216 
217  #[Test]
219  {
220  $input = [
221  'databaseRow' => [],
222  'processedTca' => [
223  'columns' => [
224  'field_1' => [
225  'displayCond' => 'FIELD:fieldName:-:23-',
226  ],
227  ],
228  ],
229  ];
230  $this->expectException(\RuntimeException::class);
231  $this->expectExceptionCode(1481457277);
232  (new ‪EvaluateDisplayConditions())->addData($input);
233  }
234 
235  #[Test]
237  {
238  $input = [
239  'databaseRow' => [],
240  'processedTca' => [
241  'columns' => [
242  'field_1' => [
243  'displayCond' => 'FIELD:fieldName:-:23-foo',
244  ],
245  ],
246  ],
247  ];
248  $this->expectException(\RuntimeException::class);
249  $this->expectExceptionCode(1481457277);
250  (new ‪EvaluateDisplayConditions())->addData($input);
251  }
252 
253  #[Test]
255  {
256  $input = [
257  'databaseRow' => [],
258  'processedTca' => [
259  'columns' => [
260  'field_1' => [
261  'displayCond' => 'REC',
262  ],
263  ],
264  ],
265  ];
266  $this->expectException(\RuntimeException::class);
267  $this->expectExceptionCode(1481384784);
268  (new ‪EvaluateDisplayConditions())->addData($input);
269  }
270 
271  #[Test]
273  {
274  $input = [
275  'databaseRow' => [],
276  'processedTca' => [
277  'columns' => [
278  'field_1' => [
279  'displayCond' => 'REC:foo',
280  ],
281  ],
282  ],
283  ];
284  $this->expectException(\RuntimeException::class);
285  $this->expectExceptionCode(1481384784);
286  (new ‪EvaluateDisplayConditions())->addData($input);
287  }
288 
289  #[Test]
291  {
292  $input = [
293  'databaseRow' => [],
294  'processedTca' => [
295  'columns' => [
296  'field_1' => [
297  'displayCond' => 'REC:NEW',
298  ],
299  ],
300  ],
301  ];
302  $this->expectException(\RuntimeException::class);
303  $this->expectExceptionCode(1481384947);
304  (new ‪EvaluateDisplayConditions())->addData($input);
305  }
306 
307  #[Test]
309  {
310  $input = [
311  'databaseRow' => [],
312  'processedTca' => [
313  'columns' => [
314  'field_1' => [
315  'displayCond' => 'REC:NEW:foo',
316  ],
317  ],
318  ],
319  ];
320  $this->expectException(\RuntimeException::class);
321  $this->expectExceptionCode(1481385173);
322  (new ‪EvaluateDisplayConditions())->addData($input);
323  }
324 
325  #[Test]
327  {
328  $input = [
329  'databaseRow' => [],
330  'processedTca' => [
331  'columns' => [
332  'field_1' => [
333  'displayCond' => 'REC:NEW:false',
334  ],
335  ],
336  ],
337  ];
338  $this->expectException(\RuntimeException::class);
339  $this->expectExceptionCode(1481467208);
340  (new ‪EvaluateDisplayConditions())->addData($input);
341  }
342 
343  #[Test]
345  {
346  $input = [
347  'databaseRow' => [],
348  'processedTca' => [
349  'columns' => [
350  'field_1' => [
351  'displayCond' => 'VERSION',
352  ],
353  ],
354  ],
355  ];
356  $this->expectException(\RuntimeException::class);
357  $this->expectExceptionCode(1481383660);
358  (new ‪EvaluateDisplayConditions())->addData($input);
359  }
360 
361  #[Test]
363  {
364  $input = [
365  'databaseRow' => [],
366  'processedTca' => [
367  'columns' => [
368  'field_1' => [
369  'displayCond' => 'VERSION:foo',
370  ],
371  ],
372  ],
373  ];
374  $this->expectException(\RuntimeException::class);
375  $this->expectExceptionCode(1481383660);
376  (new ‪EvaluateDisplayConditions())->addData($input);
377  }
378 
379  #[Test]
381  {
382  $input = [
383  'databaseRow' => [],
384  'processedTca' => [
385  'columns' => [
386  'field_1' => [
387  'displayCond' => 'VERSION:IS',
388  ],
389  ],
390  ],
391  ];
392  $this->expectException(\RuntimeException::class);
393  $this->expectExceptionCode(1481383888);
394  (new ‪EvaluateDisplayConditions())->addData($input);
395  }
396 
397  #[Test]
399  {
400  $input = [
401  'databaseRow' => [],
402  'processedTca' => [
403  'columns' => [
404  'field_1' => [
405  'displayCond' => 'VERSION:IS:foo',
406  ],
407  ],
408  ],
409  ];
410  $this->expectException(\RuntimeException::class);
411  $this->expectExceptionCode(1481384123);
412  (new ‪EvaluateDisplayConditions())->addData($input);
413  }
414 
415  #[Test]
417  {
418  $input = [
419  'databaseRow' => [],
420  'processedTca' => [
421  'columns' => [
422  'field_1' => [
423  'displayCond' => 'VERSION:IS:false',
424  ],
425  ],
426  ],
427  ];
428  $this->expectException(\RuntimeException::class);
429  $this->expectExceptionCode(1481469854);
430  (new ‪EvaluateDisplayConditions())->addData($input);
431  }
432 
433  #[Test]
435  {
436  $input = [
437  'databaseRow' => [],
438  'processedTca' => [
439  'columns' => [
440  'field_1' => [
441  'displayCond' => 'USER',
442  ],
443  ],
444  ],
445  ];
446  $this->expectException(\RuntimeException::class);
447  $this->expectExceptionCode(1481382954);
448  (new ‪EvaluateDisplayConditions())->addData($input);
449  }
450 
451  #[Test]
452  public function ‪addDataEvaluatesUserCondition(): void
453  {
454  $this->expectException(\RuntimeException::class);
455  $this->expectExceptionCode(1488130499);
456  $input = [
457  'databaseRow' => [],
458  'processedTca' => [
459  'columns' => [
460  'field_1' => [
461  'displayCond' => 'USER:' . EvaluateDisplayConditionsTestClass::class . '->addDataEvaluatesUserConditionCallback:more:arguments',
462  ],
463  ],
464  ],
465  ];
466  (new ‪EvaluateDisplayConditions())->addData($input);
467  }
468 
469  #[Test]
471  {
472  $input = [
473  'databaseRow' => [],
474  'processedTca' => [
475  'columns' => [
476  'field_1' => [
477  'config' => [
478  'type' => 'flex',
479  'ds' => [
480  'sheets' => [
481  'sDEF' => [
482  'ROOT' => [
483  'type' => 'array',
484  'el' => [
485  'foo' => [
486  'displayCond' => 'USER:' . EvaluateDisplayConditionsTestClass::class . '->addDataPassesFlexContextToUserConditionCallback:some:info',
487  ],
488  ],
489  ],
490  ],
491  ],
492  ],
493  ],
494  ],
495  ],
496  ],
497  ];
498  $expected = $input;
499  unset($expected['processedTca']['columns']['field_1']['config']['ds']['sheets']['sDEF']['ROOT']['el']['foo']['displayCond']);
500  self::assertSame($expected, (new ‪EvaluateDisplayConditions())->addData($input));
501  }
502 
503  #[Test]
505  {
506  $input = [
507  'databaseRow' => [],
508  'processedTca' => [
509  'columns' => [
510  'field_1' => [
511  'config' => [
512  'type' => 'flex',
513  'ds' => [
514  'sheets' => [
515  'sheet' => [
516  'ROOT' => [
517  'el' => [
518  'name.field' => [],
519  ],
520  ],
521  ],
522  'sheet.name' => [
523  'ROOT' => [
524  'el' => [
525  'field' => [],
526  ],
527  ],
528  ],
529  ],
530  ],
531  ],
532  ],
533  ],
534  ],
535  ];
536  $this->expectException(\RuntimeException::class);
537  $this->expectExceptionCode(1481483061);
538  (new ‪EvaluateDisplayConditions())->addData($input);
539  }
540 
541  #[Test]
543  {
544  $input = [
545  'databaseRow' => [],
546  'processedTca' => [
547  'columns' => [
548  'field_1' => [
549  'config' => [
550  'type' => 'flex',
551  'ds' => [
552  'sheets' => [
553  'aSheet' => [
554  'ROOT' => [
555  'displayCond' => 'FIELD:aSheet.aField:=:foo',
556  'el' => [
557  'aField' => [],
558  ],
559  ],
560  ],
561  ],
562  ],
563  ],
564  ],
565  ],
566  ],
567  ];
568  $this->expectException(\RuntimeException::class);
569  $this->expectExceptionCode(1481485705);
570  (new ‪EvaluateDisplayConditions())->addData($input);
571  }
572 
573  #[Test]
575  {
576  $input = [
577  'databaseRow' => [],
578  'processedTca' => [
579  'columns' => [
580  'field_1' => [
581  'config' => [
582  'type' => 'flex',
583  'ds' => [
584  'sheets' => [
585  'sheet_1' => [],
586  'sheet_2' => [
587  'ROOT' => [
588  'displayCond' => 'FIELD:sheet_1.flexField_1:!=:foo',
589  ],
590  ],
591  ],
592  ],
593  ],
594  ],
595  ],
596  ],
597  ];
598  $this->expectException(\RuntimeException::class);
599  $this->expectExceptionCode(1481488492);
600  (new ‪EvaluateDisplayConditions())->addData($input);
601  }
602 
603  #[Test]
605  {
606  $input = [
607  'databaseRow' => [],
608  'processedTca' => [
609  'columns' => [
610  'field_1' => [
611  'config' => [
612  'type' => 'flex',
613  'ds' => [
614  'sheets' => [
615  'sheet_1' => [
616  'ROOT' => [
617  'el' => [
618  'flexField_1' => [],
619  'flexField_2' => [
620  'displayCond' => 'FIELD:flexField_1:!=:foo',
621  ],
622  ],
623  ],
624  ],
625  ],
626  ],
627  ],
628  ],
629  ],
630  ],
631  ];
632  $this->expectException(\RuntimeException::class);
633  $this->expectExceptionCode(1481492953);
634  (new ‪EvaluateDisplayConditions())->addData($input);
635  }
636 
637  #[Test]
639  {
640  $input = [
641  'databaseRow' => [],
642  'processedTca' => [
643  'columns' => [
644  'field_1' => [
645  'config' => [
646  'type' => 'flex',
647  'ds' => [
648  'sheets' => [
649  'sheet_1' => [
650  'ROOT' => [
651  'el' => [
652  'flexField_1' => [
653  'displayCond' => 'FIELD:foo.flexField_1:!=:foo',
654  ],
655  ],
656  ],
657  ],
658  ],
659  ],
660  ],
661  ],
662  ],
663  ],
664  ];
665  $this->expectException(\RuntimeException::class);
666  $this->expectExceptionCode(1481496170);
667  (new ‪EvaluateDisplayConditions())->addData($input);
668  }
669 
670  #[Test]
672  {
673  $input = [
674  'databaseRow' => [
675  'field_1' => [
676  'data' => [
677  'sheet_1' => [
678  'lDEF' => [
679  'section_1' => [
680  'el' => [
681  '1' => [
682  'container_1' => [],
683  ],
684  ],
685  ],
686  ],
687  ],
688  ],
689  ],
690  ],
691  'processedTca' => [
692  'columns' => [
693  'field_1' => [
694  'config' => [
695  'type' => 'flex',
696  'ds' => [
697  'sheets' => [
698  'sheet_1' => [
699  'ROOT' => [
700  'el' => [
701  'section_1' => [
702  'type' => 'array',
703  'section' => 1,
704  'children' => [
705  '1' => [
706  'el' => [
707  'containerField_1' => [
708  'displayCond' => 'FIELD:flexField_1:!=:foo',
709  ],
710  ],
711  ],
712  ],
713  ],
714  ],
715  ],
716  ],
717  ],
718  ],
719  ],
720  ],
721  ],
722  ],
723  ];
724  $this->expectException(\RuntimeException::class);
725  $this->expectExceptionCode(1481634649);
726  (new ‪EvaluateDisplayConditions())->addData($input);
727  }
728 
733  {
734  return [
735 
736  // tca field to tca field value tests
737  'remove tca field by tca field value' => [
738  // path that should be removed from 'processedTca' by condition
739  'columns/field_2',
740  // 'databaseRow'
741  [
742  'field_1' => 'foo',
743  ],
744  // 'processedTca'
745  [
746  'columns' => [
747  'field_2' => [
748  'displayCond' => 'FIELD:field_1:!=:foo',
749  ],
750  ],
751  ],
752  ],
753 
754  // flex field to tca field value tests
755  'remove flex form field by tca field value' => [
756  'columns/field_2/config/ds/sheets/sheet_1/ROOT/el/flexField_1',
757  [
758  'field_1' => 'foo',
759  ],
760  [
761  'columns' => [
762  'field_2' => [
763  'config' => [
764  'type' => 'flex',
765  'ds' => [
766  'sheets' => [
767  'sheet_1' => [
768  'ROOT' => [
769  'el' => [
770  'flexField_1' => [
771  'displayCond' => 'FIELD:parentRec.field_1:!=:foo',
772  ],
773  ],
774  ],
775  ],
776  ],
777  ],
778  ],
779  ],
780  ],
781  ],
782  ],
783 
784  // flex field to flex field value on same sheet tests
785  'remove flex form field by flex field value on same flex sheet' => [
786  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/flexField_2',
787  [
788  'field_1' => [
789  'data' => [
790  'sheet_1' => [
791  'lDEF' => [
792  'flexField_1' => [
793  'vDEF' => [
794  0 => 'foo',
795  ],
796  ],
797  ],
798  ],
799  ],
800  ],
801  ],
802  [
803  'columns' => [
804  'field_1' => [
805  'config' => [
806  'type' => 'flex',
807  'ds' => [
808  'sheets' => [
809  'sheet_1' => [
810  'ROOT' => [
811  'el' => [
812  'flexField_1' => [],
813  'flexField_2' => [
814  'displayCond' => 'FIELD:flexField_1:!=:foo',
815  ],
816  ],
817  ],
818  ],
819  ],
820  ],
821  ],
822  ],
823  ],
824  ],
825  ],
826 
827  'remove flex form field by flex field value on same flex sheet with dot in flex sheet name' => [
828  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/flexField_2',
829  [
830  'field_1' => [
831  'data' => [
832  'sheet.1' => [
833  'lDEF' => [
834  'flexField_1' => [
835  'vDEF' => [
836  0 => 'foo',
837  ],
838  ],
839  ],
840  ],
841  ],
842  ],
843  ],
844  [
845  'columns' => [
846  'field_1' => [
847  'config' => [
848  'type' => 'flex',
849  'ds' => [
850  'sheets' => [
851  'sheet.1' => [
852  'ROOT' => [
853  'el' => [
854  'flexField_1' => [],
855  'flexField_2' => [
856  'displayCond' => 'FIELD:flexField_1:!=:foo',
857  ],
858  ],
859  ],
860  ],
861  ],
862  ],
863  ],
864  ],
865  ],
866  ],
867  ],
868 
869  'remove flex form field by flex field value on same flex sheet with dot in flex field name' => [
870  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/flexField_2',
871  [
872  'field_1' => [
873  'data' => [
874  'sheet_1' => [
875  'lDEF' => [
876  'flexField.1' => [
877  'vDEF' => [
878  0 => 'foo',
879  ],
880  ],
881  ],
882  ],
883  ],
884  ],
885  ],
886  [
887  'columns' => [
888  'field_1' => [
889  'config' => [
890  'type' => 'flex',
891  'ds' => [
892  'sheets' => [
893  'sheet_1' => [
894  'ROOT' => [
895  'el' => [
896  'flexField.1' => [],
897  'flexField_2' => [
898  'displayCond' => 'FIELD:flexField.1:!=:foo',
899  ],
900  ],
901  ],
902  ],
903  ],
904  ],
905  ],
906  ],
907  ],
908  ],
909  ],
910 
911  'remove flex form field by flex field value on same flex sheet with dot in flex sheet name and dot in flex field name' => [
912  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/flexField_2',
913  [
914  'field_1' => [
915  'data' => [
916  'sheet.1' => [
917  'lDEF' => [
918  'flexField.1' => [
919  'vDEF' => [
920  0 => 'foo',
921  ],
922  ],
923  ],
924  ],
925  ],
926  ],
927  ],
928  [
929  'columns' => [
930  'field_1' => [
931  'config' => [
932  'type' => 'flex',
933  'ds' => [
934  'sheets' => [
935  'sheet.1' => [
936  'ROOT' => [
937  'el' => [
938  'flexField.1' => [],
939  'flexField_2' => [
940  'displayCond' => 'FIELD:flexField.1:!=:foo',
941  ],
942  ],
943  ],
944  ],
945  ],
946  ],
947  ],
948  ],
949  ],
950  ],
951  ],
952 
953  'remove flex form field by flex field value on same flex sheet with specified flex sheet name' => [
954  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/flexField_2',
955  [
956  'field_1' => [
957  'data' => [
958  'sheet_1' => [
959  'lDEF' => [
960  'flexField_1' => [
961  'vDEF' => [
962  0 => 'foo',
963  ],
964  ],
965  ],
966  ],
967  ],
968  ],
969  ],
970  [
971  'columns' => [
972  'field_1' => [
973  'config' => [
974  'type' => 'flex',
975  'ds' => [
976  'sheets' => [
977  'sheet_1' => [
978  'ROOT' => [
979  'el' => [
980  'flexField_1' => [],
981  'flexField_2' => [
982  'displayCond' => 'FIELD:sheet_1.flexField_1:!=:foo',
983  ],
984  ],
985  ],
986  ],
987  ],
988  ],
989  ],
990  ],
991  ],
992  ],
993  ],
994 
995  'remove flex form field by flex field value on same flex sheet with specified flex sheet name with dot in flex sheet name' => [
996  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/flexField_2',
997  [
998  'field_1' => [
999  'data' => [
1000  'sheet.1' => [
1001  'lDEF' => [
1002  'flexField_1' => [
1003  'vDEF' => [
1004  0 => 'foo',
1005  ],
1006  ],
1007  ],
1008  ],
1009  ],
1010  ],
1011  ],
1012  [
1013  'columns' => [
1014  'field_1' => [
1015  'config' => [
1016  'type' => 'flex',
1017  'ds' => [
1018  'sheets' => [
1019  'sheet.1' => [
1020  'ROOT' => [
1021  'el' => [
1022  'flexField_1' => [],
1023  'flexField_2' => [
1024  'displayCond' => 'FIELD:sheet.1.flexField_1:!=:foo',
1025  ],
1026  ],
1027  ],
1028  ],
1029  ],
1030  ],
1031  ],
1032  ],
1033  ],
1034  ],
1035  ],
1036 
1037  'remove flex form field by flex field value on same flex sheet with specified flex sheet name with dot in flex field name' => [
1038  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/flexField_2',
1039  [
1040  'field_1' => [
1041  'data' => [
1042  'sheet_1' => [
1043  'lDEF' => [
1044  'flexField.1' => [
1045  'vDEF' => [
1046  0 => 'foo',
1047  ],
1048  ],
1049  ],
1050  ],
1051  ],
1052  ],
1053  ],
1054  [
1055  'columns' => [
1056  'field_1' => [
1057  'config' => [
1058  'type' => 'flex',
1059  'ds' => [
1060  'sheets' => [
1061  'sheet_1' => [
1062  'ROOT' => [
1063  'el' => [
1064  'flexField.1' => [],
1065  'flexField_2' => [
1066  'displayCond' => 'FIELD:sheet_1.flexField.1:!=:foo',
1067  ],
1068  ],
1069  ],
1070  ],
1071  ],
1072  ],
1073  ],
1074  ],
1075  ],
1076  ],
1077  ],
1078 
1079  'remove flex form field by flex field value on same flex sheet with specified flex sheet name with dot in flex sheet name and dot in flex field name' => [
1080  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/flexField_2',
1081  [
1082  'field_1' => [
1083  'data' => [
1084  'sheet.1' => [
1085  'lDEF' => [
1086  'flexField.1' => [
1087  'vDEF' => [
1088  0 => 'foo',
1089  ],
1090  ],
1091  ],
1092  ],
1093  ],
1094  ],
1095  ],
1096  [
1097  'columns' => [
1098  'field_1' => [
1099  'config' => [
1100  'type' => 'flex',
1101  'ds' => [
1102  'sheets' => [
1103  'sheet.1' => [
1104  'ROOT' => [
1105  'el' => [
1106  'flexField.1' => [],
1107  'flexField_2' => [
1108  'displayCond' => 'FIELD:sheet.1.flexField.1:!=:foo',
1109  ],
1110  ],
1111  ],
1112  ],
1113  ],
1114  ],
1115  ],
1116  ],
1117  ],
1118  ],
1119  ],
1120 
1121  // flex field to flex field value on other sheet tests
1122  'remove flex form field by flex field value on other flex sheet' => [
1123  'columns/field_1/config/ds/sheets/sheet_2/ROOT/el/flexField_1',
1124  [
1125  'field_1' => [
1126  'data' => [
1127  'sheet_1' => [
1128  'lDEF' => [
1129  'flexField_1' => [
1130  'vDEF' => [
1131  0 => 'foo',
1132  ],
1133  ],
1134  ],
1135  ],
1136  ],
1137  ],
1138  ],
1139  [
1140  'columns' => [
1141  'field_1' => [
1142  'config' => [
1143  'type' => 'flex',
1144  'ds' => [
1145  'sheets' => [
1146  'sheet_1' => [
1147  'ROOT' => [
1148  'el' => [
1149  'flexField_1' => [],
1150  ],
1151  ],
1152  ],
1153  'sheet_2' => [
1154  'ROOT' => [
1155  'el' => [
1156  'flexField_1' => [
1157  'displayCond' => 'FIELD:sheet_1.flexField_1:!=:foo',
1158  ],
1159  ],
1160  ],
1161  ],
1162  ],
1163  ],
1164  ],
1165  ],
1166  ],
1167  ],
1168  ],
1169 
1170  'remove flex form field by flex field value on other flex sheet with dot in flex sheet name' => [
1171  'columns/field_1/config/ds/sheets/sheet_2/ROOT/el/flexField_1',
1172  [
1173  'field_1' => [
1174  'data' => [
1175  'sheet.1' => [
1176  'lDEF' => [
1177  'flexField_1' => [
1178  'vDEF' => [
1179  0 => 'foo',
1180  ],
1181  ],
1182  ],
1183  ],
1184  ],
1185  ],
1186  ],
1187  [
1188  'columns' => [
1189  'field_1' => [
1190  'config' => [
1191  'type' => 'flex',
1192  'ds' => [
1193  'sheets' => [
1194  'sheet.1' => [
1195  'ROOT' => [
1196  'el' => [
1197  'flexField_1' => [],
1198  ],
1199  ],
1200  ],
1201  'sheet_2' => [
1202  'ROOT' => [
1203  'el' => [
1204  'flexField_1' => [
1205  'displayCond' => 'FIELD:sheet.1.flexField_1:!=:foo',
1206  ],
1207  ],
1208  ],
1209  ],
1210  ],
1211  ],
1212  ],
1213  ],
1214  ],
1215  ],
1216  ],
1217 
1218  'remove flex form field by flex field value on other flex sheet with dot in flex field name' => [
1219  'columns/field_1/config/ds/sheets/sheet_2/ROOT/el/flexField_1',
1220  [
1221  'field_1' => [
1222  'data' => [
1223  'sheet_1' => [
1224  'lDEF' => [
1225  'flexField.1' => [
1226  'vDEF' => [
1227  0 => 'foo',
1228  ],
1229  ],
1230  ],
1231  ],
1232  ],
1233  ],
1234  ],
1235  [
1236  'columns' => [
1237  'field_1' => [
1238  'config' => [
1239  'type' => 'flex',
1240  'ds' => [
1241  'sheets' => [
1242  'sheet_1' => [
1243  'ROOT' => [
1244  'el' => [
1245  'flexField.1' => [],
1246  ],
1247  ],
1248  ],
1249  'sheet_2' => [
1250  'ROOT' => [
1251  'el' => [
1252  'flexField_1' => [
1253  'displayCond' => 'FIELD:sheet_1.flexField.1:!=:foo',
1254  ],
1255  ],
1256  ],
1257  ],
1258  ],
1259  ],
1260  ],
1261  ],
1262  ],
1263  ],
1264  ],
1265 
1266  'remove flex form field by flex field value on other flex sheet with dot in flex sheet name and dot in flex field name' => [
1267  'columns/field_1/config/ds/sheets/sheet_2/ROOT/el/flexField_1',
1268  [
1269  'field_1' => [
1270  'data' => [
1271  'sheet.1' => [
1272  'lDEF' => [
1273  'flexField.1' => [
1274  'vDEF' => [
1275  0 => 'foo',
1276  ],
1277  ],
1278  ],
1279  ],
1280  ],
1281  ],
1282  ],
1283  [
1284  'columns' => [
1285  'field_1' => [
1286  'config' => [
1287  'type' => 'flex',
1288  'ds' => [
1289  'sheets' => [
1290  'sheet.1' => [
1291  'ROOT' => [
1292  'el' => [
1293  'flexField.1' => [],
1294  ],
1295  ],
1296  ],
1297  'sheet_2' => [
1298  'ROOT' => [
1299  'el' => [
1300  'flexField_1' => [
1301  'displayCond' => 'FIELD:sheet.1.flexField.1:!=:foo',
1302  ],
1303  ],
1304  ],
1305  ],
1306  ],
1307  ],
1308  ],
1309  ],
1310  ],
1311  ],
1312  ],
1313 
1314  // flex sheet to tca field value tests
1315  'remove flex form sheet by tca field value' => [
1316  'columns/field_2/config/ds/sheets/sheet_1',
1317  [
1318  'field_1' => 'foo',
1319  ],
1320  [
1321  'columns' => [
1322  'field_2' => [
1323  'config' => [
1324  'type' => 'flex',
1325  'ds' => [
1326  'sheets' => [
1327  'sheet_1' => [
1328  'ROOT' => [
1329  'displayCond' => 'FIELD:parentRec.field_1:!=:foo',
1330  ],
1331  ],
1332  ],
1333  ],
1334  ],
1335  ],
1336  ],
1337  ],
1338  ],
1339 
1340  // flex sheet to flex field value tests
1341  'remove flex form sheet by flex field value on different flex sheet' => [
1342  'columns/field_1/config/ds/sheets/sheet_2',
1343  [
1344  'field_1' => [
1345  'data' => [
1346  'sheet_1' => [
1347  'lDEF' => [
1348  'flexField_1' => [
1349  'vDEF' => [
1350  0 => 'foo',
1351  ],
1352  ],
1353  ],
1354  ],
1355  ],
1356  ],
1357  ],
1358  [
1359  'columns' => [
1360  'field_1' => [
1361  'config' => [
1362  'type' => 'flex',
1363  'ds' => [
1364  'sheets' => [
1365  'sheet_1' => [
1366  'ROOT' => [
1367  'el' => [
1368  'flexField_1' => [],
1369  ],
1370  ],
1371  ],
1372  'sheet_2' => [
1373  'ROOT' => [
1374  'displayCond' => 'FIELD:sheet_1.flexField_1:!=:foo',
1375  ],
1376  ],
1377  ],
1378  ],
1379  ],
1380  ],
1381  ],
1382  ],
1383  ],
1384 
1385  'remove flex form sheet by flex field value on different flex sheet with dot in flex sheet name' => [
1386  'columns/field_1/config/ds/sheets/sheet.2',
1387  [
1388  'field_1' => [
1389  'data' => [
1390  'sheet.1' => [
1391  'lDEF' => [
1392  'flexField_1' => [
1393  'vDEF' => [
1394  0 => 'foo',
1395  ],
1396  ],
1397  ],
1398  ],
1399  ],
1400  ],
1401  ],
1402  [
1403  'columns' => [
1404  'field_1' => [
1405  'config' => [
1406  'type' => 'flex',
1407  'ds' => [
1408  'sheets' => [
1409  'sheet.1' => [
1410  'ROOT' => [
1411  'el' => [
1412  'flexField_1' => [],
1413  ],
1414  ],
1415  ],
1416  'sheet.2' => [
1417  'ROOT' => [
1418  'displayCond' => 'FIELD:sheet.1.flexField_1:!=:foo',
1419  ],
1420  ],
1421  ],
1422  ],
1423  ],
1424  ],
1425  ],
1426  ],
1427  ],
1428 
1429  'remove flex form sheet by flex field value on different flex sheet with dot in flex field name' => [
1430  'columns/field_1/config/ds/sheets/sheet_2',
1431  [
1432  'field_1' => [
1433  'data' => [
1434  'sheet_1' => [
1435  'lDEF' => [
1436  'flexField.1' => [
1437  'vDEF' => [
1438  0 => 'foo',
1439  ],
1440  ],
1441  ],
1442  ],
1443  ],
1444  ],
1445  ],
1446  [
1447  'columns' => [
1448  'field_1' => [
1449  'config' => [
1450  'type' => 'flex',
1451  'ds' => [
1452  'sheets' => [
1453  'sheet_1' => [
1454  'ROOT' => [
1455  'el' => [
1456  'flexField.1' => [],
1457  ],
1458  ],
1459  ],
1460  'sheet_2' => [
1461  'ROOT' => [
1462  'displayCond' => 'FIELD:sheet_1.flexField.1:!=:foo',
1463  ],
1464  ],
1465  ],
1466  ],
1467  ],
1468  ],
1469  ],
1470  ],
1471  ],
1472 
1473  'remove flex form sheet by flex field value on different flex sheet with dot in flex sheet name and dot in flex field name' => [
1474  'columns/field_1/config/ds/sheets/sheet.2',
1475  [
1476  'field_1' => [
1477  'data' => [
1478  'sheet.1' => [
1479  'lDEF' => [
1480  'flexField.1' => [
1481  'vDEF' => [
1482  0 => 'foo',
1483  ],
1484  ],
1485  ],
1486  ],
1487  ],
1488  ],
1489  ],
1490  [
1491  'columns' => [
1492  'field_1' => [
1493  'config' => [
1494  'type' => 'flex',
1495  'ds' => [
1496  'sheets' => [
1497  'sheet.1' => [
1498  'ROOT' => [
1499  'el' => [
1500  'flexField.1' => [],
1501  ],
1502  ],
1503  ],
1504  'sheet.2' => [
1505  'ROOT' => [
1506  'displayCond' => 'FIELD:sheet.1.flexField.1:!=:foo',
1507  ],
1508  ],
1509  ],
1510  ],
1511  ],
1512  ],
1513  ],
1514  ],
1515  ],
1516 
1517  // flex section container field to tca value tests
1518  'remove flex section container field by tca field value' => [
1519  'columns/field_2/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/containerField_1',
1520  [
1521  'field_1' => 'foo',
1522  'field_2' => [
1523  'data' => [
1524  'sheet_1' => [
1525  'lDEF' => [
1526  'section_1' => [
1527  'el' => [
1528  '1' => [],
1529  ],
1530  ],
1531  ],
1532  ],
1533  ],
1534  ],
1535  ],
1536  [
1537  'columns' => [
1538  'field_2' => [
1539  'config' => [
1540  'type' => 'flex',
1541  'ds' => [
1542  'sheets' => [
1543  'sheet_1' => [
1544  'ROOT' => [
1545  'el' => [
1546  'section_1' => [
1547  'type' => 'array',
1548  'section' => 1,
1549  'children' => [
1550  '1' => [
1551  'el' => [
1552  'containerField_1' => [
1553  'displayCond' => 'FIELD:parentRec.field_1:!=:foo',
1554  ],
1555  ],
1556  ],
1557  ],
1558  ],
1559  ],
1560  ],
1561  ],
1562  ],
1563  ],
1564  ],
1565  ],
1566  ],
1567  ],
1568  ],
1569 
1570  // flex section container field to flex field value of same sheet
1571  'remove flex section container field by flex field value on same flex sheet' => [
1572  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/containerField_1',
1573  [
1574  'field_1' => [
1575  'data' => [
1576  'sheet_1' => [
1577  'lDEF' => [
1578  'flexField_1' => [
1579  'vDEF' => [
1580  0 => 'foo',
1581  ],
1582  ],
1583  'section_1' => [
1584  'el' => [
1585  '1' => [],
1586  ],
1587  ],
1588  ],
1589  ],
1590  ],
1591  ],
1592  ],
1593  [
1594  'columns' => [
1595  'field_1' => [
1596  'config' => [
1597  'type' => 'flex',
1598  'ds' => [
1599  'sheets' => [
1600  'sheet_1' => [
1601  'ROOT' => [
1602  'el' => [
1603  'flexField_1' => [],
1604  'section_1' => [
1605  'type' => 'array',
1606  'section' => 1,
1607  'children' => [
1608  '1' => [
1609  'el' => [
1610  'containerField_1' => [
1611  'displayCond' => 'FIELD:flexField_1:!=:foo',
1612  ],
1613  ],
1614  ],
1615  ],
1616  ],
1617  ],
1618  ],
1619  ],
1620  ],
1621  ],
1622  ],
1623  ],
1624  ],
1625  ],
1626  ],
1627 
1628  'remove flex section container field by flex field value on same flex sheet with dot in flex sheet name' => [
1629  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/containerField_1',
1630  [
1631  'field_1' => [
1632  'data' => [
1633  'sheet.1' => [
1634  'lDEF' => [
1635  'flexField_1' => [
1636  'vDEF' => [
1637  0 => 'foo',
1638  ],
1639  ],
1640  'section_1' => [
1641  'el' => [
1642  '1' => [],
1643  ],
1644  ],
1645  ],
1646  ],
1647  ],
1648  ],
1649  ],
1650  [
1651  'columns' => [
1652  'field_1' => [
1653  'config' => [
1654  'type' => 'flex',
1655  'ds' => [
1656  'sheets' => [
1657  'sheet.1' => [
1658  'ROOT' => [
1659  'el' => [
1660  'flexField_1' => [],
1661  'section_1' => [
1662  'type' => 'array',
1663  'section' => 1,
1664  'children' => [
1665  '1' => [
1666  'el' => [
1667  'containerField_1' => [
1668  'displayCond' => 'FIELD:flexField_1:!=:foo',
1669  ],
1670  ],
1671  ],
1672  ],
1673  ],
1674  ],
1675  ],
1676  ],
1677  ],
1678  ],
1679  ],
1680  ],
1681  ],
1682  ],
1683  ],
1684 
1685  'remove flex section container field by flex field value on same flex sheet with dot in flex field name' => [
1686  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/containerField_1',
1687  [
1688  'field_1' => [
1689  'data' => [
1690  'sheet_1' => [
1691  'lDEF' => [
1692  'flexField.1' => [
1693  'vDEF' => [
1694  0 => 'foo',
1695  ],
1696  ],
1697  'section_1' => [
1698  'el' => [
1699  '1' => [],
1700  ],
1701  ],
1702  ],
1703  ],
1704  ],
1705  ],
1706  ],
1707  [
1708  'columns' => [
1709  'field_1' => [
1710  'config' => [
1711  'type' => 'flex',
1712  'ds' => [
1713  'sheets' => [
1714  'sheet_1' => [
1715  'ROOT' => [
1716  'el' => [
1717  'flexField.1' => [],
1718  'section_1' => [
1719  'type' => 'array',
1720  'section' => 1,
1721  'children' => [
1722  '1' => [
1723  'el' => [
1724  'containerField_1' => [
1725  'displayCond' => 'FIELD:flexField.1:!=:foo',
1726  ],
1727  ],
1728  ],
1729  ],
1730  ],
1731  ],
1732  ],
1733  ],
1734  ],
1735  ],
1736  ],
1737  ],
1738  ],
1739  ],
1740  ],
1741 
1742  'remove flex section container field by flex field value on same flex sheet with dot in flex sheet name and dot in flex field name' => [
1743  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/containerField_1',
1744  [
1745  'field_1' => [
1746  'data' => [
1747  'sheet.1' => [
1748  'lDEF' => [
1749  'flexField.1' => [
1750  'vDEF' => [
1751  0 => 'foo',
1752  ],
1753  ],
1754  'section_1' => [
1755  'el' => [
1756  '1' => [],
1757  ],
1758  ],
1759  ],
1760  ],
1761  ],
1762  ],
1763  ],
1764  [
1765  'columns' => [
1766  'field_1' => [
1767  'config' => [
1768  'type' => 'flex',
1769  'ds' => [
1770  'sheets' => [
1771  'sheet.1' => [
1772  'ROOT' => [
1773  'el' => [
1774  'flexField.1' => [],
1775  'section_1' => [
1776  'type' => 'array',
1777  'section' => 1,
1778  'children' => [
1779  '1' => [
1780  'el' => [
1781  'containerField_1' => [
1782  'displayCond' => 'FIELD:flexField.1:!=:foo',
1783  ],
1784  ],
1785  ],
1786  ],
1787  ],
1788  ],
1789  ],
1790  ],
1791  ],
1792  ],
1793  ],
1794  ],
1795  ],
1796  ],
1797  ],
1798 
1799  'remove flex section container field by flex field value on same flex sheet with specified flex sheet name' => [
1800  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/containerField_1',
1801  [
1802  'field_1' => [
1803  'data' => [
1804  'sheet_1' => [
1805  'lDEF' => [
1806  'flexField_1' => [
1807  'vDEF' => [
1808  0 => 'foo',
1809  ],
1810  ],
1811  'section_1' => [
1812  'el' => [
1813  '1' => [],
1814  ],
1815  ],
1816  ],
1817  ],
1818  ],
1819  ],
1820  ],
1821  [
1822  'columns' => [
1823  'field_1' => [
1824  'config' => [
1825  'type' => 'flex',
1826  'ds' => [
1827  'sheets' => [
1828  'sheet_1' => [
1829  'ROOT' => [
1830  'el' => [
1831  'flexField_1' => [],
1832  'section_1' => [
1833  'type' => 'array',
1834  'section' => 1,
1835  'children' => [
1836  '1' => [
1837  'el' => [
1838  'containerField_1' => [
1839  'displayCond' => 'FIELD:sheet_1.flexField_1:!=:foo',
1840  ],
1841  ],
1842  ],
1843  ],
1844  ],
1845  ],
1846  ],
1847  ],
1848  ],
1849  ],
1850  ],
1851  ],
1852  ],
1853  ],
1854  ],
1855 
1856  'remove flex section container field by flex field value on same flex sheet with specified flex sheet name with dot in flex sheet name' => [
1857  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/containerField_1',
1858  [
1859  'field_1' => [
1860  'data' => [
1861  'sheet.1' => [
1862  'lDEF' => [
1863  'flexField_1' => [
1864  'vDEF' => [
1865  0 => 'foo',
1866  ],
1867  ],
1868  'section_1' => [
1869  'el' => [
1870  '1' => [],
1871  ],
1872  ],
1873  ],
1874  ],
1875  ],
1876  ],
1877  ],
1878  [
1879  'columns' => [
1880  'field_1' => [
1881  'config' => [
1882  'type' => 'flex',
1883  'ds' => [
1884  'sheets' => [
1885  'sheet.1' => [
1886  'ROOT' => [
1887  'el' => [
1888  'flexField_1' => [],
1889  'section_1' => [
1890  'type' => 'array',
1891  'section' => 1,
1892  'children' => [
1893  '1' => [
1894  'el' => [
1895  'containerField_1' => [
1896  'displayCond' => 'FIELD:sheet.1.flexField_1:!=:foo',
1897  ],
1898  ],
1899  ],
1900  ],
1901  ],
1902  ],
1903  ],
1904  ],
1905  ],
1906  ],
1907  ],
1908  ],
1909  ],
1910  ],
1911  ],
1912 
1913  'remove flex section container field by flex field value on same flex sheet with specified flex sheet name with dot in flex field name' => [
1914  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/containerField_1',
1915  [
1916  'field_1' => [
1917  'data' => [
1918  'sheet_1' => [
1919  'lDEF' => [
1920  'flexField.1' => [
1921  'vDEF' => [
1922  0 => 'foo',
1923  ],
1924  ],
1925  'section_1' => [
1926  'el' => [
1927  '1' => [],
1928  ],
1929  ],
1930  ],
1931  ],
1932  ],
1933  ],
1934  ],
1935  [
1936  'columns' => [
1937  'field_1' => [
1938  'config' => [
1939  'type' => 'flex',
1940  'ds' => [
1941  'sheets' => [
1942  'sheet_1' => [
1943  'ROOT' => [
1944  'el' => [
1945  'flexField.1' => [],
1946  'section_1' => [
1947  'type' => 'array',
1948  'section' => 1,
1949  'children' => [
1950  '1' => [
1951  'el' => [
1952  'containerField_1' => [
1953  'displayCond' => 'FIELD:sheet_1.flexField.1:!=:foo',
1954  ],
1955  ],
1956  ],
1957  ],
1958  ],
1959  ],
1960  ],
1961  ],
1962  ],
1963  ],
1964  ],
1965  ],
1966  ],
1967  ],
1968  ],
1969 
1970  'remove flex section container field by flex field value on same flex sheet with specified flex sheet name with dot in flex sheet name and dot in flex field name' => [
1971  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/containerField_1',
1972  [
1973  'field_1' => [
1974  'data' => [
1975  'sheet.1' => [
1976  'lDEF' => [
1977  'flexField.1' => [
1978  'vDEF' => [
1979  0 => 'foo',
1980  ],
1981  ],
1982  'section_1' => [
1983  'el' => [
1984  '1' => [],
1985  ],
1986  ],
1987  ],
1988  ],
1989  ],
1990  ],
1991  ],
1992  [
1993  'columns' => [
1994  'field_1' => [
1995  'config' => [
1996  'type' => 'flex',
1997  'ds' => [
1998  'sheets' => [
1999  'sheet.1' => [
2000  'ROOT' => [
2001  'el' => [
2002  'flexField.1' => [],
2003  'section_1' => [
2004  'type' => 'array',
2005  'section' => 1,
2006  'children' => [
2007  '1' => [
2008  'el' => [
2009  'containerField_1' => [
2010  'displayCond' => 'FIELD:sheet.1.flexField.1:!=:foo',
2011  ],
2012  ],
2013  ],
2014  ],
2015  ],
2016  ],
2017  ],
2018  ],
2019  ],
2020  ],
2021  ],
2022  ],
2023  ],
2024  ],
2025  ],
2026 
2027  // flex section container field to flex field value of other sheet
2028  'remove flex section container field by flex field value on other flex sheet' => [
2029  'columns/field_1/config/ds/sheets/sheet_2/ROOT/el/section_1/children/1/el/containerField_1',
2030  [
2031  'field_1' => [
2032  'data' => [
2033  'sheet_1' => [
2034  'lDEF' => [
2035  'flexField_1' => [
2036  'vDEF' => [
2037  0 => 'foo',
2038  ],
2039  ],
2040  ],
2041  ],
2042  'sheet_2' => [
2043  'lDEF' => [
2044  'section_1' => [
2045  'el' => [
2046  '1' => [],
2047  ],
2048  ],
2049  ],
2050  ],
2051  ],
2052  ],
2053  ],
2054  [
2055  'columns' => [
2056  'field_1' => [
2057  'config' => [
2058  'type' => 'flex',
2059  'ds' => [
2060  'sheets' => [
2061  'sheet_1' => [
2062  'ROOT' => [
2063  'el' => [
2064  'flexField_1' => [],
2065  ],
2066  ],
2067  ],
2068  'sheet_2' => [
2069  'ROOT' => [
2070  'el' => [
2071  'section_1' => [
2072  'type' => 'array',
2073  'section' => 1,
2074  'children' => [
2075  '1' => [
2076  'el' => [
2077  'containerField_1' => [
2078  'displayCond' => 'FIELD:sheet_1.flexField_1:!=:foo',
2079  ],
2080  ],
2081  ],
2082  ],
2083  ],
2084  ],
2085  ],
2086  ],
2087  ],
2088  ],
2089  ],
2090  ],
2091  ],
2092  ],
2093  ],
2094 
2095  'remove flex section container field by flex field value on other flex sheet with dot in flex sheet name' => [
2096  'columns/field_1/config/ds/sheets/sheet_2/ROOT/el/section_1/children/1/el/containerField_1',
2097  [
2098  'field_1' => [
2099  'data' => [
2100  'sheet.1' => [
2101  'lDEF' => [
2102  'flexField_1' => [
2103  'vDEF' => [
2104  0 => 'foo',
2105  ],
2106  ],
2107  ],
2108  ],
2109  'sheet_2' => [
2110  'lDEF' => [
2111  'section_1' => [
2112  'el' => [
2113  '1' => [],
2114  ],
2115  ],
2116  ],
2117  ],
2118  ],
2119  ],
2120  ],
2121  [
2122  'columns' => [
2123  'field_1' => [
2124  'config' => [
2125  'type' => 'flex',
2126  'ds' => [
2127  'sheets' => [
2128  'sheet.1' => [
2129  'ROOT' => [
2130  'el' => [
2131  'flexField_1' => [],
2132  ],
2133  ],
2134  ],
2135  'sheet_2' => [
2136  'ROOT' => [
2137  'el' => [
2138  'section_1' => [
2139  'type' => 'array',
2140  'section' => 1,
2141  'children' => [
2142  '1' => [
2143  'el' => [
2144  'containerField_1' => [
2145  'displayCond' => 'FIELD:sheet.1.flexField_1:!=:foo',
2146  ],
2147  ],
2148  ],
2149  ],
2150  ],
2151  ],
2152  ],
2153  ],
2154  ],
2155  ],
2156  ],
2157  ],
2158  ],
2159  ],
2160  ],
2161 
2162  'remove flex section container field by flex field value on other flex sheet with dot in flex field name' => [
2163  'columns/field_1/config/ds/sheets/sheet_2/ROOT/el/section_1/children/1/el/containerField_1',
2164  [
2165  'field_1' => [
2166  'data' => [
2167  'sheet_1' => [
2168  'lDEF' => [
2169  'flexField.1' => [
2170  'vDEF' => [
2171  0 => 'foo',
2172  ],
2173  ],
2174  ],
2175  ],
2176  'sheet_2' => [
2177  'lDEF' => [
2178  'section_1' => [
2179  'el' => [
2180  '1' => [],
2181  ],
2182  ],
2183  ],
2184  ],
2185  ],
2186  ],
2187  ],
2188  [
2189  'columns' => [
2190  'field_1' => [
2191  'config' => [
2192  'type' => 'flex',
2193  'ds' => [
2194  'sheets' => [
2195  'sheet_1' => [
2196  'ROOT' => [
2197  'el' => [
2198  'flexField.1' => [],
2199  ],
2200  ],
2201  ],
2202  'sheet_2' => [
2203  'ROOT' => [
2204  'el' => [
2205  'section_1' => [
2206  'type' => 'array',
2207  'section' => 1,
2208  'children' => [
2209  '1' => [
2210  'el' => [
2211  'containerField_1' => [
2212  'displayCond' => 'FIELD:sheet_1.flexField.1:!=:foo',
2213  ],
2214  ],
2215  ],
2216  ],
2217  ],
2218  ],
2219  ],
2220  ],
2221  ],
2222  ],
2223  ],
2224  ],
2225  ],
2226  ],
2227  ],
2228 
2229  'remove flex section container field by flex field value on other flex sheet with dot in flex sheet name and dot in flex field name' => [
2230  'columns/field_1/config/ds/sheets/sheet_2/ROOT/el/section_1/children/1/el/containerField_1',
2231  [
2232  'field_1' => [
2233  'data' => [
2234  'sheet.1' => [
2235  'lDEF' => [
2236  'flexField.1' => [
2237  'vDEF' => [
2238  0 => 'foo',
2239  ],
2240  ],
2241  ],
2242  ],
2243  'sheet_2' => [
2244  'lDEF' => [
2245  'section_1' => [
2246  'el' => [
2247  '1' => [],
2248  ],
2249  ],
2250  ],
2251  ],
2252  ],
2253  ],
2254  ],
2255  [
2256  'columns' => [
2257  'field_1' => [
2258  'config' => [
2259  'type' => 'flex',
2260  'ds' => [
2261  'sheets' => [
2262  'sheet.1' => [
2263  'ROOT' => [
2264  'el' => [
2265  'flexField.1' => [],
2266  ],
2267  ],
2268  ],
2269  'sheet_2' => [
2270  'ROOT' => [
2271  'el' => [
2272  'section_1' => [
2273  'type' => 'array',
2274  'section' => 1,
2275  'children' => [
2276  '1' => [
2277  'el' => [
2278  'containerField_1' => [
2279  'displayCond' => 'FIELD:sheet.1.flexField.1:!=:foo',
2280  ],
2281  ],
2282  ],
2283  ],
2284  ],
2285  ],
2286  ],
2287  ],
2288  ],
2289  ],
2290  ],
2291  ],
2292  ],
2293  ],
2294  ],
2295 
2296  // flex section container field to flex field value of same container
2297  'remove flex section container field by flex container field value of same container' => [
2298  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/containerField_2',
2299  [
2300  'field_1' => [
2301  'data' => [
2302  'sheet_1' => [
2303  'lDEF' => [
2304  'section_1' => [
2305  'el' => [
2306  '1' => [
2307  'container_1' => [
2308  'el' => [
2309  'containerField_1' => [
2310  'vDEF' => 'foo',
2311  ],
2312  ],
2313  ],
2314  ],
2315  ],
2316  ],
2317  ],
2318  ],
2319  ],
2320  ],
2321  ],
2322  [
2323  'columns' => [
2324  'field_1' => [
2325  'config' => [
2326  'type' => 'flex',
2327  'ds' => [
2328  'sheets' => [
2329  'sheet_1' => [
2330  'ROOT' => [
2331  'el' => [
2332  'section_1' => [
2333  'type' => 'array',
2334  'section' => 1,
2335  'children' => [
2336  '1' => [
2337  'el' => [
2338  'containerField_1' => [],
2339  'containerField_2' => [
2340  'displayCond' => 'FIELD:containerField_1:!=:foo',
2341  ],
2342  ],
2343  ],
2344  ],
2345  ],
2346  ],
2347  ],
2348  ],
2349  ],
2350  ],
2351  ],
2352  ],
2353  ],
2354  ],
2355  ],
2356 
2357  'remove flex section container field by flex container field value of same container with dot in flex sheet name' => [
2358  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/containerField_2',
2359  [
2360  'field_1' => [
2361  'data' => [
2362  'sheet.1' => [
2363  'lDEF' => [
2364  'section_1' => [
2365  'el' => [
2366  '1' => [
2367  'container_1' => [
2368  'el' => [
2369  'containerField_1' => [
2370  'vDEF' => 'foo',
2371  ],
2372  ],
2373  ],
2374  ],
2375  ],
2376  ],
2377  ],
2378  ],
2379  ],
2380  ],
2381  ],
2382  [
2383  'columns' => [
2384  'field_1' => [
2385  'config' => [
2386  'type' => 'flex',
2387  'ds' => [
2388  'sheets' => [
2389  'sheet.1' => [
2390  'ROOT' => [
2391  'el' => [
2392  'section_1' => [
2393  'type' => 'array',
2394  'section' => 1,
2395  'children' => [
2396  '1' => [
2397  'el' => [
2398  'containerField_1' => [],
2399  'containerField_2' => [
2400  'displayCond' => 'FIELD:containerField_1:!=:foo',
2401  ],
2402  ],
2403  ],
2404  ],
2405  ],
2406  ],
2407  ],
2408  ],
2409  ],
2410  ],
2411  ],
2412  ],
2413  ],
2414  ],
2415  ],
2416 
2417  'remove flex section container field by flex container field value of same container with dot in container flex field name' => [
2418  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/containerField_2',
2419  [
2420  'field_1' => [
2421  'data' => [
2422  'sheet_1' => [
2423  'lDEF' => [
2424  'section_1' => [
2425  'el' => [
2426  '1' => [
2427  'container_1' => [
2428  'el' => [
2429  'containerField.1' => [
2430  'vDEF' => 'foo',
2431  ],
2432  ],
2433  ],
2434  ],
2435  ],
2436  ],
2437  ],
2438  ],
2439  ],
2440  ],
2441  ],
2442  [
2443  'columns' => [
2444  'field_1' => [
2445  'config' => [
2446  'type' => 'flex',
2447  'ds' => [
2448  'sheets' => [
2449  'sheet_1' => [
2450  'ROOT' => [
2451  'el' => [
2452  'section_1' => [
2453  'type' => 'array',
2454  'section' => 1,
2455  'children' => [
2456  '1' => [
2457  'el' => [
2458  'containerField.1' => [],
2459  'containerField_2' => [
2460  'displayCond' => 'FIELD:containerField.1:!=:foo',
2461  ],
2462  ],
2463  ],
2464  ],
2465  ],
2466  ],
2467  ],
2468  ],
2469  ],
2470  ],
2471  ],
2472  ],
2473  ],
2474  ],
2475  ],
2476 
2477  'remove flex section container field by flex container field value of same container with dot in flex sheet name and dot in container flex field name' => [
2478  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/containerField_2',
2479  [
2480  'field_1' => [
2481  'data' => [
2482  'sheet.1' => [
2483  'lDEF' => [
2484  'section_1' => [
2485  'el' => [
2486  '1' => [
2487  'container_1' => [
2488  'el' => [
2489  'containerField.1' => [
2490  'vDEF' => 'foo',
2491  ],
2492  ],
2493  ],
2494  ],
2495  ],
2496  ],
2497  ],
2498  ],
2499  ],
2500  ],
2501  ],
2502  [
2503  'columns' => [
2504  'field_1' => [
2505  'config' => [
2506  'type' => 'flex',
2507  'ds' => [
2508  'sheets' => [
2509  'sheet.1' => [
2510  'ROOT' => [
2511  'el' => [
2512  'section_1' => [
2513  'type' => 'array',
2514  'section' => 1,
2515  'children' => [
2516  '1' => [
2517  'el' => [
2518  'containerField.1' => [],
2519  'containerField_2' => [
2520  'displayCond' => 'FIELD:containerField.1:!=:foo',
2521  ],
2522  ],
2523  ],
2524  ],
2525  ],
2526  ],
2527  ],
2528  ],
2529  ],
2530  ],
2531  ],
2532  ],
2533  ],
2534  ],
2535  ],
2536 
2537  'remove flex section container field by flex container field value of same container with specified flex sheet name' => [
2538  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/containerField_2',
2539  [
2540  'field_1' => [
2541  'data' => [
2542  'sheet_1' => [
2543  'lDEF' => [
2544  'section_1' => [
2545  'el' => [
2546  '1' => [
2547  'container_1' => [
2548  'el' => [
2549  'containerField_1' => [
2550  'vDEF' => 'foo',
2551  ],
2552  ],
2553  ],
2554  ],
2555  ],
2556  ],
2557  ],
2558  ],
2559  ],
2560  ],
2561  ],
2562  [
2563  'columns' => [
2564  'field_1' => [
2565  'config' => [
2566  'type' => 'flex',
2567  'ds' => [
2568  'sheets' => [
2569  'sheet_1' => [
2570  'ROOT' => [
2571  'el' => [
2572  'section_1' => [
2573  'type' => 'array',
2574  'section' => 1,
2575  'children' => [
2576  '1' => [
2577  'el' => [
2578  'containerField_1' => [],
2579  'containerField_2' => [
2580  'displayCond' => 'FIELD:sheet_1.containerField_1:!=:foo',
2581  ],
2582  ],
2583  ],
2584  ],
2585  ],
2586  ],
2587  ],
2588  ],
2589  ],
2590  ],
2591  ],
2592  ],
2593  ],
2594  ],
2595  ],
2596 
2597  'remove flex section container field by flex container field value of same container with specified flex sheet name with dot in flex sheet name' => [
2598  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/containerField_2',
2599  [
2600  'field_1' => [
2601  'data' => [
2602  'sheet.1' => [
2603  'lDEF' => [
2604  'section_1' => [
2605  'el' => [
2606  '1' => [
2607  'container_1' => [
2608  'el' => [
2609  'containerField_1' => [
2610  'vDEF' => 'foo',
2611  ],
2612  ],
2613  ],
2614  ],
2615  ],
2616  ],
2617  ],
2618  ],
2619  ],
2620  ],
2621  ],
2622  [
2623  'columns' => [
2624  'field_1' => [
2625  'config' => [
2626  'type' => 'flex',
2627  'ds' => [
2628  'sheets' => [
2629  'sheet.1' => [
2630  'ROOT' => [
2631  'el' => [
2632  'section_1' => [
2633  'type' => 'array',
2634  'section' => 1,
2635  'children' => [
2636  '1' => [
2637  'el' => [
2638  'containerField_1' => [],
2639  'containerField_2' => [
2640  'displayCond' => 'FIELD:sheet.1.containerField_1:!=:foo',
2641  ],
2642  ],
2643  ],
2644  ],
2645  ],
2646  ],
2647  ],
2648  ],
2649  ],
2650  ],
2651  ],
2652  ],
2653  ],
2654  ],
2655  ],
2656 
2657  'remove flex section container field by flex container field value of same container with specified flex sheet name with dot in container flex field name' => [
2658  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/containerField_2',
2659  [
2660  'field_1' => [
2661  'data' => [
2662  'sheet_1' => [
2663  'lDEF' => [
2664  'section_1' => [
2665  'el' => [
2666  '1' => [
2667  'container_1' => [
2668  'el' => [
2669  'containerField.1' => [
2670  'vDEF' => 'foo',
2671  ],
2672  ],
2673  ],
2674  ],
2675  ],
2676  ],
2677  ],
2678  ],
2679  ],
2680  ],
2681  ],
2682  [
2683  'columns' => [
2684  'field_1' => [
2685  'config' => [
2686  'type' => 'flex',
2687  'ds' => [
2688  'sheets' => [
2689  'sheet_1' => [
2690  'ROOT' => [
2691  'el' => [
2692  'section_1' => [
2693  'type' => 'array',
2694  'section' => 1,
2695  'children' => [
2696  '1' => [
2697  'el' => [
2698  'containerField.1' => [],
2699  'containerField_2' => [
2700  'displayCond' => 'FIELD:sheet_1.containerField.1:!=:foo',
2701  ],
2702  ],
2703  ],
2704  ],
2705  ],
2706  ],
2707  ],
2708  ],
2709  ],
2710  ],
2711  ],
2712  ],
2713  ],
2714  ],
2715  ],
2716 
2717  'remove flex section container field by flex container field value of same container with specified flex sheet name with dot in flex sheet name and dot in container flex field name' => [
2718  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/containerField_2',
2719  [
2720  'field_1' => [
2721  'data' => [
2722  'sheet.1' => [
2723  'lDEF' => [
2724  'section_1' => [
2725  'el' => [
2726  '1' => [
2727  'container_1' => [
2728  'el' => [
2729  'containerField.1' => [
2730  'vDEF' => 'foo',
2731  ],
2732  ],
2733  ],
2734  ],
2735  ],
2736  ],
2737  ],
2738  ],
2739  ],
2740  ],
2741  ],
2742  [
2743  'columns' => [
2744  'field_1' => [
2745  'config' => [
2746  'type' => 'flex',
2747  'ds' => [
2748  'sheets' => [
2749  'sheet.1' => [
2750  'ROOT' => [
2751  'el' => [
2752  'section_1' => [
2753  'type' => 'array',
2754  'section' => 1,
2755  'children' => [
2756  '1' => [
2757  'el' => [
2758  'containerField.1' => [],
2759  'containerField_2' => [
2760  'displayCond' => 'FIELD:sheet.1.containerField.1:!=:foo',
2761  ],
2762  ],
2763  ],
2764  ],
2765  ],
2766  ],
2767  ],
2768  ],
2769  ],
2770  ],
2771  ],
2772  ],
2773  ],
2774  ],
2775  ],
2776 
2777  // flex section container field to flex field value of same container with naming clash to flex field value of same sheet
2778  'remove flex section container field by flex container field value of same container with naming clash' => [
2779  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/field_2',
2780  [
2781  'field_1' => [
2782  'data' => [
2783  'sheet_1' => [
2784  'lDEF' => [
2785  'field_1' => [
2786  'vDEF' => [
2787  0 => 'bar',
2788  ],
2789  ],
2790  'section_1' => [
2791  'el' => [
2792  '1' => [
2793  'container_1' => [
2794  'el' => [
2795  'field_1' => [
2796  'vDEF' => 'foo',
2797  ],
2798  ],
2799  ],
2800  ],
2801  ],
2802  ],
2803  ],
2804  ],
2805  ],
2806  ],
2807  ],
2808  [
2809  'columns' => [
2810  'field_1' => [
2811  'config' => [
2812  'type' => 'flex',
2813  'ds' => [
2814  'sheets' => [
2815  'sheet_1' => [
2816  'ROOT' => [
2817  'el' => [
2818  'section_1' => [
2819  'type' => 'array',
2820  'section' => 1,
2821  'children' => [
2822  '1' => [
2823  'el' => [
2824  'field_1' => [],
2825  'field_2' => [
2826  'displayCond' => 'FIELD:field_1:!=:foo',
2827  ],
2828  ],
2829  ],
2830  ],
2831  ],
2832  ],
2833  ],
2834  ],
2835  ],
2836  ],
2837  ],
2838  ],
2839  ],
2840  ],
2841  ],
2842 
2843  'remove flex section container field by flex container field value of same container with naming clash with dot in flex sheet name' => [
2844  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/field_2',
2845  [
2846  'field_1' => [
2847  'data' => [
2848  'sheet.1' => [
2849  'lDEF' => [
2850  'field_1' => [
2851  'vDEF' => [
2852  0 => 'bar',
2853  ],
2854  ],
2855  'section_1' => [
2856  'el' => [
2857  '1' => [
2858  'container_1' => [
2859  'el' => [
2860  'field_1' => [
2861  'vDEF' => 'foo',
2862  ],
2863  ],
2864  ],
2865  ],
2866  ],
2867  ],
2868  ],
2869  ],
2870  ],
2871  ],
2872  ],
2873  [
2874  'columns' => [
2875  'field_1' => [
2876  'config' => [
2877  'type' => 'flex',
2878  'ds' => [
2879  'sheets' => [
2880  'sheet.1' => [
2881  'ROOT' => [
2882  'el' => [
2883  'section_1' => [
2884  'type' => 'array',
2885  'section' => 1,
2886  'children' => [
2887  '1' => [
2888  'el' => [
2889  'field_1' => [],
2890  'field_2' => [
2891  'displayCond' => 'FIELD:field_1:!=:foo',
2892  ],
2893  ],
2894  ],
2895  ],
2896  ],
2897  ],
2898  ],
2899  ],
2900  ],
2901  ],
2902  ],
2903  ],
2904  ],
2905  ],
2906  ],
2907 
2908  'remove flex section container field by flex container field value of same container with naming clash with dot in flex field name' => [
2909  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/field_2',
2910  [
2911  'field_1' => [
2912  'data' => [
2913  'sheet_1' => [
2914  'lDEF' => [
2915  'field.1' => [
2916  'vDEF' => [
2917  0 => 'bar',
2918  ],
2919  ],
2920  'section_1' => [
2921  'el' => [
2922  '1' => [
2923  'container_1' => [
2924  'el' => [
2925  'field.1' => [
2926  'vDEF' => 'foo',
2927  ],
2928  ],
2929  ],
2930  ],
2931  ],
2932  ],
2933  ],
2934  ],
2935  ],
2936  ],
2937  ],
2938  [
2939  'columns' => [
2940  'field_1' => [
2941  'config' => [
2942  'type' => 'flex',
2943  'ds' => [
2944  'sheets' => [
2945  'sheet_1' => [
2946  'ROOT' => [
2947  'el' => [
2948  'section_1' => [
2949  'type' => 'array',
2950  'section' => 1,
2951  'children' => [
2952  '1' => [
2953  'el' => [
2954  'field.1' => [],
2955  'field_2' => [
2956  'displayCond' => 'FIELD:field.1:!=:foo',
2957  ],
2958  ],
2959  ],
2960  ],
2961  ],
2962  ],
2963  ],
2964  ],
2965  ],
2966  ],
2967  ],
2968  ],
2969  ],
2970  ],
2971  ],
2972 
2973  'remove flex section container field by flex container field value of same container with naming clash with dot in flex sheet name and dot in flex field name' => [
2974  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/field_2',
2975  [
2976  'field_1' => [
2977  'data' => [
2978  'sheet.1' => [
2979  'lDEF' => [
2980  'field.1' => [
2981  'vDEF' => [
2982  0 => 'bar',
2983  ],
2984  ],
2985  'section_1' => [
2986  'el' => [
2987  '1' => [
2988  'container_1' => [
2989  'el' => [
2990  'field.1' => [
2991  'vDEF' => 'foo',
2992  ],
2993  ],
2994  ],
2995  ],
2996  ],
2997  ],
2998  ],
2999  ],
3000  ],
3001  ],
3002  ],
3003  [
3004  'columns' => [
3005  'field_1' => [
3006  'config' => [
3007  'type' => 'flex',
3008  'ds' => [
3009  'sheets' => [
3010  'sheet.1' => [
3011  'ROOT' => [
3012  'el' => [
3013  'section_1' => [
3014  'type' => 'array',
3015  'section' => 1,
3016  'children' => [
3017  '1' => [
3018  'el' => [
3019  'field.1' => [],
3020  'field_2' => [
3021  'displayCond' => 'FIELD:field.1:!=:foo',
3022  ],
3023  ],
3024  ],
3025  ],
3026  ],
3027  ],
3028  ],
3029  ],
3030  ],
3031  ],
3032  ],
3033  ],
3034  ],
3035  ],
3036  ],
3037 
3038  'remove flex section container field by flex container field value of same container with naming clash with specified flex sheet name' => [
3039  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/field_2',
3040  [
3041  'field_1' => [
3042  'data' => [
3043  'sheet_1' => [
3044  'lDEF' => [
3045  'field_1' => [
3046  'vDEF' => [
3047  0 => 'bar',
3048  ],
3049  ],
3050  'section_1' => [
3051  'el' => [
3052  '1' => [
3053  'container_1' => [
3054  'el' => [
3055  'field_1' => [
3056  'vDEF' => 'foo',
3057  ],
3058  ],
3059  ],
3060  ],
3061  ],
3062  ],
3063  ],
3064  ],
3065  ],
3066  ],
3067  ],
3068  [
3069  'columns' => [
3070  'field_1' => [
3071  'config' => [
3072  'type' => 'flex',
3073  'ds' => [
3074  'sheets' => [
3075  'sheet_1' => [
3076  'ROOT' => [
3077  'el' => [
3078  'section_1' => [
3079  'type' => 'array',
3080  'section' => 1,
3081  'children' => [
3082  '1' => [
3083  'el' => [
3084  'field_1' => [],
3085  'field_2' => [
3086  'displayCond' => 'FIELD:sheet_1.field_1:!=:foo',
3087  ],
3088  ],
3089  ],
3090  ],
3091  ],
3092  ],
3093  ],
3094  ],
3095  ],
3096  ],
3097  ],
3098  ],
3099  ],
3100  ],
3101  ],
3102 
3103  'remove flex section container field by flex container field value of same container with naming clash with specified flex sheet name with dot in flex sheet name' => [
3104  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/field_2',
3105  [
3106  'field_1' => [
3107  'data' => [
3108  'sheet.1' => [
3109  'lDEF' => [
3110  'field_1' => [
3111  'vDEF' => [
3112  0 => 'bar',
3113  ],
3114  ],
3115  'section_1' => [
3116  'el' => [
3117  '1' => [
3118  'container_1' => [
3119  'el' => [
3120  'field_1' => [
3121  'vDEF' => 'foo',
3122  ],
3123  ],
3124  ],
3125  ],
3126  ],
3127  ],
3128  ],
3129  ],
3130  ],
3131  ],
3132  ],
3133  [
3134  'columns' => [
3135  'field_1' => [
3136  'config' => [
3137  'type' => 'flex',
3138  'ds' => [
3139  'sheets' => [
3140  'sheet.1' => [
3141  'ROOT' => [
3142  'el' => [
3143  'section_1' => [
3144  'type' => 'array',
3145  'section' => 1,
3146  'children' => [
3147  '1' => [
3148  'el' => [
3149  'field_1' => [],
3150  'field_2' => [
3151  'displayCond' => 'FIELD:sheet.1.field_1:!=:foo',
3152  ],
3153  ],
3154  ],
3155  ],
3156  ],
3157  ],
3158  ],
3159  ],
3160  ],
3161  ],
3162  ],
3163  ],
3164  ],
3165  ],
3166  ],
3167 
3168  'remove flex section container field by flex container field value of same container with naming clash with specified flex sheet name with dot in flex field name' => [
3169  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1/children/1/el/field_2',
3170  [
3171  'field_1' => [
3172  'data' => [
3173  'sheet_1' => [
3174  'lDEF' => [
3175  'field.1' => [
3176  'vDEF' => [
3177  0 => 'bar',
3178  ],
3179  ],
3180  'section_1' => [
3181  'el' => [
3182  '1' => [
3183  'container_1' => [
3184  'el' => [
3185  'field.1' => [
3186  'vDEF' => 'foo',
3187  ],
3188  ],
3189  ],
3190  ],
3191  ],
3192  ],
3193  ],
3194  ],
3195  ],
3196  ],
3197  ],
3198  [
3199  'columns' => [
3200  'field_1' => [
3201  'config' => [
3202  'type' => 'flex',
3203  'ds' => [
3204  'sheets' => [
3205  'sheet_1' => [
3206  'ROOT' => [
3207  'el' => [
3208  'section_1' => [
3209  'type' => 'array',
3210  'section' => 1,
3211  'children' => [
3212  '1' => [
3213  'el' => [
3214  'field.1' => [],
3215  'field_2' => [
3216  'displayCond' => 'FIELD:sheet_1.field.1:!=:foo',
3217  ],
3218  ],
3219  ],
3220  ],
3221  ],
3222  ],
3223  ],
3224  ],
3225  ],
3226  ],
3227  ],
3228  ],
3229  ],
3230  ],
3231  ],
3232 
3233  'remove flex section container field by flex container field value of same container with naming clash with specified flex sheet name with dot in flex sheet name and dot in flex field name' => [
3234  'columns/field_1/config/ds/sheets/sheet.1/ROOT/el/section_1/children/1/el/field_2',
3235  [
3236  'field_1' => [
3237  'data' => [
3238  'sheet.1' => [
3239  'lDEF' => [
3240  'field.1' => [
3241  'vDEF' => [
3242  0 => 'bar',
3243  ],
3244  ],
3245  'section_1' => [
3246  'el' => [
3247  '1' => [
3248  'container_1' => [
3249  'el' => [
3250  'field.1' => [
3251  'vDEF' => 'foo',
3252  ],
3253  ],
3254  ],
3255  ],
3256  ],
3257  ],
3258  ],
3259  ],
3260  ],
3261  ],
3262  ],
3263  [
3264  'columns' => [
3265  'field_1' => [
3266  'config' => [
3267  'type' => 'flex',
3268  'ds' => [
3269  'sheets' => [
3270  'sheet.1' => [
3271  'ROOT' => [
3272  'el' => [
3273  'section_1' => [
3274  'type' => 'array',
3275  'section' => 1,
3276  'children' => [
3277  '1' => [
3278  'el' => [
3279  'field.1' => [],
3280  'field_2' => [
3281  'displayCond' => 'FIELD:sheet.1.field.1:!=:foo',
3282  ],
3283  ],
3284  ],
3285  ],
3286  ],
3287  ],
3288  ],
3289  ],
3290  ],
3291  ],
3292  ],
3293  ],
3294  ],
3295  ],
3296  ],
3297 
3298  // Some special scenarios
3299  'remove flex sheet by nested OR condition' => [
3300  'columns/field_1/config/ds/sheets/sheet_2',
3301  [
3302  'field_1' => [
3303  'data' => [
3304  'sheet_1' => [
3305  'lDEF' => [
3306  'field_1' => [
3307  'vDEF' => [
3308  0 => 'foo',
3309  ],
3310  ],
3311  ],
3312  ],
3313  ],
3314  ],
3315  ],
3316  [
3317  'columns' => [
3318  'field_1' => [
3319  'config' => [
3320  'type' => 'flex',
3321  'ds' => [
3322  'sheets' => [
3323  'sheet_1' => [
3324  'ROOT' => [
3325  'type' => 'array',
3326  'el' => [
3327  'field_1' => [],
3328  ],
3329  ],
3330  ],
3331  'sheet_2' => [
3332  'ROOT' => [
3333  'type' => 'array',
3334  'el' => [],
3335  'displayCond' => [
3336  'OR' => [
3337  'FIELD:sheet_1.field_1:=:LIST',
3338  'FIELD:sheet_1.field_1:!=:foo',
3339  ],
3340  ],
3341  ],
3342  ],
3343  ],
3344  ],
3345  ],
3346  ],
3347  ],
3348  ],
3349  ],
3350 
3351  // flex section container has a display condition
3352  'remove flex section container' => [
3353  'columns/field_1/config/ds/sheets/sheet_1/ROOT/el/section_1',
3354  [
3355  'field_1' => [
3356  'data' => [
3357  'sheet_1' => [
3358  'lDEF' => [
3359  'field_1' => [
3360  'vDEF' => [
3361  0 => 'foo',
3362  ],
3363  ],
3364  ],
3365  ],
3366  ],
3367  ],
3368  ],
3369  [
3370  'columns' => [
3371  'field_1' => [
3372  'config' => [
3373  'type' => 'flex',
3374  'ds' => [
3375  'sheets' => [
3376  'sheet_1' => [
3377  'ROOT' => [
3378  'el' => [
3379  'field_1' => [],
3380  'section_1' => [
3381  'type' => 'array',
3382  'section' => 1,
3383  'displayCond' => 'FIELD:field_1:!=:foo',
3384  'children' => [],
3385  ],
3386  ],
3387  ],
3388  ],
3389  ],
3390  ],
3391  ],
3392  ],
3393  ],
3394  ],
3395  ],
3396 
3397  // field name to sheet name overlap
3398  'remove flex field even if sheet name and field name overlap' => [
3399  'columns/field_1/config/ds/sheets/field_1/ROOT/el/field_2',
3400  [
3401  'field_1' => [
3402  'data' => [
3403  'field_1' => [
3404  'lDEF' => [
3405  'field_1' => [
3406  'vDEF' => [
3407  0 => 'foo',
3408  ],
3409  ],
3410  ],
3411  ],
3412  ],
3413  ],
3414  ],
3415  [
3416  'columns' => [
3417  'field_1' => [
3418  'config' => [
3419  'type' => 'flex',
3420  'ds' => [
3421  'sheets' => [
3422  'field_1' => [
3423  'ROOT' => [
3424  'el' => [
3425  'field_1' => [],
3426  'field_2' => [
3427  'displayCond' => 'FIELD:field_1.field_1:!=:foo',
3428  ],
3429  ],
3430  ],
3431  ],
3432  ],
3433  ],
3434  ],
3435  ],
3436  ],
3437  ],
3438  ],
3439 
3440  ];
3441  }
3442 
3443  #[DataProvider('addDataRemovesTcaReferencingOtherFieldsInDisplayConditionDataProvider')]
3444  #[Test]
3445  public function ‪addDataRemovesTcaReferencingOtherFieldsInDisplayCondition(string $processedTcaFieldToBeRemovedPath, array $databaseRow, array $processedTca): void
3446  {
3447  $input = [
3448  'databaseRow' => $databaseRow,
3449  'processedTca' => $processedTca,
3450  ];
3451  $expected = ‪ArrayUtility::removeByPath($input, 'processedTca/' . $processedTcaFieldToBeRemovedPath);
3452  self::assertSame($expected, (new ‪EvaluateDisplayConditions())->addData($input));
3453  }
3454 
3462  public static function ‪conditionStringDataProvider(): array
3463  {
3464  return [
3465  'Field is not greater zero if not given' => [
3466  'FIELD:uid:>:0',
3467  [],
3468  false,
3469  ],
3470  'Field is not equal 0 if not given' => [
3471  'FIELD:uid:=:0',
3472  [],
3473  false,
3474  ],
3475  'Field is not greater zero if empty array given' => [
3476  'FIELD:foo:>:0',
3477  ['foo' => []],
3478  false,
3479  ],
3480  'Field is not greater than or equal to zero if empty array given' => [
3481  'FIELD:foo:>=:0',
3482  ['foo' => []],
3483  false,
3484  ],
3485  'Field is less than 1 if empty array given' => [
3486  'FIELD:foo:<:1',
3487  ['foo' => []],
3488  true,
3489  ],
3490  'Field is less than or equal to 1 if empty array given' => [
3491  'FIELD:foo:<=:1',
3492  ['foo' => []],
3493  true,
3494  ],
3495  'Field does not equal 0 if empty array given' => [
3496  'FIELD:foo:=:0',
3497  ['foo' => []],
3498  false,
3499  ],
3500  'Field value string comparison' => [
3501  'FIELD:foo:=:bar',
3502  ['foo' => 'bar'],
3503  true,
3504  ],
3505  'Field value string comparison against list' => [
3506  'FIELD:foo:IN:bar,baz',
3507  ['foo' => 'baz'],
3508  true,
3509  ],
3510  'Field value comparison of 1 against multi-value field of 5 returns true' => [
3511  'FIELD:content:BIT:1',
3512  ['content' => '5'],
3513  true,
3514  ],
3515  'Field value comparison of 2 against multi-value field of 5 returns false' => [
3516  'FIELD:content:BIT:2',
3517  ['content' => '5'],
3518  false,
3519  ],
3520  'Field value of 5 negated comparison against multi-value field of 5 returns false' => [
3521  'FIELD:content:!BIT:5',
3522  ['content' => '5'],
3523  false,
3524  ],
3525  'Field value comparison for required value is false for different value' => [
3526  'FIELD:foo:REQ:FALSE',
3527  ['foo' => 'bar'],
3528  false,
3529  ],
3530  'Field value string not equal comparison' => [
3531  'FIELD:foo:!=:baz',
3532  ['foo' => 'bar'],
3533  true,
3534  ],
3535  'Field value string not equal comparison against list' => [
3536  'FIELD:foo:!IN:bar,baz',
3537  ['foo' => 'foo'],
3538  true,
3539  ],
3540  'Field value in range' => [
3541  'FIELD:uid:-:3-42',
3542  ['uid' => '23'],
3543  true,
3544  ],
3545  'Field value greater than' => [
3546  'FIELD:uid:>=:42',
3547  ['uid' => '23'],
3548  false,
3549  ],
3550  'Field value containing colons' => [
3551  'FIELD:foo:=:x:y:z',
3552  ['foo' => 'x:y:z'],
3553  true,
3554  ],
3555  'New is TRUE for new comparison with TRUE' => [
3556  'REC:NEW:TRUE',
3557  ['uid' => null],
3558  true,
3559  ],
3560  'New is FALSE for new comparison with FALSE' => [
3561  'REC:NEW:FALSE',
3562  ['uid' => null],
3563  false,
3564  ],
3565  'New is FALSE for not new element' => [
3566  'REC:NEW:TRUE',
3567  ['uid' => 42],
3568  false,
3569  ],
3570  'New is TRUE for not new element compared to FALSE' => [
3571  'REC:NEW:FALSE',
3572  ['uid' => 42],
3573  true,
3574  ],
3575  'Version is TRUE for versioned row' => [
3576  'VERSION:IS:TRUE',
3577  [
3578  'uid' => 42,
3579  't3ver_oid' => 12,
3580  ],
3581  true,
3582  ],
3583  'Version is TRUE for not versioned row compared with FALSE' => [
3584  'VERSION:IS:FALSE',
3585  [
3586  'uid' => 42,
3587  't3ver_oid' => 0,
3588  ],
3589  true,
3590  ],
3591  'Version is TRUE for NULL row compared with TRUE' => [
3592  'VERSION:IS:TRUE',
3593  [
3594  'uid' => null,
3595  'pid' => null,
3596  ],
3597  false,
3598  ],
3599  'Single condition with AND compares to TRUE if the one is OK' => [
3600  [
3601  'AND' => [
3602  'FIELD:testField:>:9',
3603  ],
3604  ],
3605  [
3606  'testField' => 10,
3607  ],
3608  true,
3609  ],
3610  'Multiple conditions with AND compare to TRUE if all are OK' => [
3611  [
3612  'AND' => [
3613  'FIELD:testField:>:9',
3614  'FIELD:testField:<:11',
3615  ],
3616  ],
3617  [
3618  'testField' => 10,
3619  ],
3620  true,
3621  ],
3622  'Multiple conditions with AND compare to FALSE if one fails' => [
3623  [
3624  'AND' => [
3625  'FIELD:testField:>:9',
3626  'FIELD:testField:<:11',
3627  ],
3628  ],
3629  [
3630  'testField' => 99,
3631  ],
3632  false,
3633  ],
3634  'Single condition with OR compares to TRUE if the one is OK' => [
3635  [
3636  'OR' => [
3637  'FIELD:testField:>:9',
3638  ],
3639  ],
3640  [
3641  'testField' => 10,
3642  ],
3643  true,
3644  ],
3645  'Multiple conditions with OR compare to TRUE if one is OK' => [
3646  [
3647  'OR' => [
3648  'FIELD:testField:<:9',
3649  'FIELD:testField:<:11',
3650  ],
3651  ],
3652  [
3653  'testField' => 10,
3654  ],
3655  true,
3656  ],
3657  'Multiple conditions with OR compare to FALSE is all fail' => [
3658  [
3659  'OR' => [
3660  'FIELD:testField:<:9',
3661  'FIELD:testField:<:11',
3662  ],
3663  ],
3664  [
3665  'testField' => 99,
3666  ],
3667  false,
3668  ],
3669  'Multiple nested conditions evaluate to TRUE' => [
3670  [
3671  'AND' => [
3672  'FIELD:testField:>:9',
3673  'OR' => [
3674  'FIELD:testField:<:100',
3675  'FIELD:testField:>:-100',
3676  ],
3677  ],
3678  ],
3679  [
3680  'testField' => 10,
3681  ],
3682  true,
3683  ],
3684  'Multiple nested conditions evaluate to FALSE' => [
3685  [
3686  'AND' => [
3687  'FIELD:testField:>:9',
3688  'OR' => [
3689  'FIELD:testField:<:100',
3690  'FIELD:testField:>:-100',
3691  ],
3692  ],
3693  ],
3694  [
3695  'testField' => -999,
3696  ],
3697  false,
3698  ],
3699  ];
3700  }
3701 
3706  #[DataProvider('conditionStringDataProvider')]
3707  #[Test]
3708  public function ‪matchConditionStrings($condition, array ‪$record, $expectedResult): void
3709  {
3710  $input = [
3711  'databaseRow' => ‪$record,
3712  'processedTca' => [
3713  'columns' => [
3714  'testField' => [
3715  'displayCond' => $condition,
3716  'config' => [
3717  'type' => 'input',
3718  ],
3719  ],
3720  ],
3721  ],
3722  ];
3723 
3724  ‪$GLOBALS['BE_USER'] = $this->createMock(BackendUserAuthentication::class);
3725 
3726  $expected = $input;
3727  if ($expectedResult) {
3728  // displayCond vanished from result array after this data provider is done
3729  unset($expected['processedTca']['columns']['testField']['displayCond']);
3730  } else {
3731  unset($expected['processedTca']['columns']['testField']);
3732  }
3733  self::assertSame($expected, (new ‪EvaluateDisplayConditions())->addData($input));
3734  }
3735 
3740  #[DataProvider('conditionStringDataProvider')]
3741  #[Test]
3742  public function ‪matchConditionStringsWithRecordTestFieldBeingArray($condition, array ‪$record, $expectedResult): void
3743  {
3744  $input = [
3745  'processedTca' => [
3746  'columns' => [
3747  'testField' => [
3748  'displayCond' => $condition,
3749  'config' => [
3750  'type' => 'input',
3751  ],
3752  ],
3753  ],
3754  ],
3755  ];
3756 
3757  $input['databaseRow'] = ‪$record;
3758  if (!empty(‪$record['testField'])) {
3759  $input['databaseRow'] = [
3760  'testField' => [
3761  'key' => ‪$record['testField'],
3762  ],
3763  ];
3764  }
3765 
3766  ‪$GLOBALS['BE_USER'] = $this->createMock(BackendUserAuthentication::class);
3767 
3768  $expected = $input;
3769  if ($expectedResult) {
3770  // displayCond vanished from result array after this data provider is done
3771  unset($expected['processedTca']['columns']['testField']['displayCond']);
3772  } else {
3773  unset($expected['processedTca']['columns']['testField']);
3774  }
3775  self::assertSame($expected, (new ‪EvaluateDisplayConditions())->addData($input));
3776  }
3777 
3778  #[Test]
3780  {
3781  $input = [
3782  'databaseRow' => [],
3783  'processedTca' => [
3784  'columns' => [
3785  'aField' => [
3786  'displayCond' => 'HIDE_FOR_NON_ADMINS',
3787  'config' => [
3788  'type' => 'input',
3789  ],
3790  ],
3791  ],
3792  ],
3793  ];
3794 
3795  $backendUserMock = $this->createMock(BackendUserAuthentication::class);
3796  ‪$GLOBALS['BE_USER'] = $backendUserMock;
3797  $backendUserMock->expects(self::atLeastOnce())->method('isAdmin')->willReturn(true);
3798 
3799  $expected = $input;
3800  unset($expected['processedTca']['columns']['aField']['displayCond']);
3801 
3802  self::assertSame($expected, (new ‪EvaluateDisplayConditions())->addData($input));
3803  }
3804 
3805  #[Test]
3807  {
3808  $input = [
3809  'databaseRow' => [],
3810  'processedTca' => [
3811  'columns' => [
3812  'aField' => [
3813  'displayCond' => 'HIDE_FOR_NON_ADMINS',
3814  'config' => [
3815  'type' => 'input',
3816  ],
3817  ],
3818  ],
3819  ],
3820  ];
3821 
3822  $backendUserMock = $this->createMock(BackendUserAuthentication::class);
3823  ‪$GLOBALS['BE_USER'] = $backendUserMock;
3824  $backendUserMock->expects(self::atLeastOnce())->method('isAdmin')->willReturn(false);
3825 
3826  $expected = $input;
3827  unset($expected['processedTca']['columns']['aField']);
3828  self::assertSame($expected, (new ‪EvaluateDisplayConditions())->addData($input));
3829  }
3830 }
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfConditionTypeIsUnknown
‪addDataThrowsExceptionIfConditionTypeIsUnknown()
Definition: EvaluateDisplayConditionsTest.php:92
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfMultipleConditionsAreNotCombinedWithAndOrOr
‪addDataThrowsExceptionIfMultipleConditionsAreNotCombinedWithAndOrOr()
Definition: EvaluateDisplayConditionsTest.php:31
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFlexSheetNameAndFieldNameCombinationsOverlap
‪addDataThrowsExceptionIfFlexSheetNameAndFieldNameCombinationsOverlap()
Definition: EvaluateDisplayConditionsTest.php:504
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfRecordConditionHasNoNewKeyword
‪addDataThrowsExceptionIfRecordConditionHasNoNewKeyword()
Definition: EvaluateDisplayConditionsTest.php:254
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFieldConditionRangeComparisonHasInvalidOperand
‪addDataThrowsExceptionIfFieldConditionRangeComparisonHasInvalidOperand()
Definition: EvaluateDisplayConditionsTest.php:218
‪TYPO3\CMS\Core\Utility\ArrayUtility\removeByPath
‪static array removeByPath(array $array, string $path, string $delimiter='/')
Definition: ArrayUtility.php:303
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfVersionConditionHasNoUidInDatabaseRow
‪addDataThrowsExceptionIfVersionConditionHasNoUidInDatabaseRow()
Definition: EvaluateDisplayConditionsTest.php:416
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\matchConditionStringsWithRecordTestFieldBeingArray
‪matchConditionStringsWithRecordTestFieldBeingArray($condition, array $record, $expectedResult)
Definition: EvaluateDisplayConditionsTest.php:3742
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest
Definition: EvaluateDisplayConditionsTest.php:29
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfRecordConditionHasNoUidInDatabaseRow
‪addDataThrowsExceptionIfRecordConditionHasNoUidInDatabaseRow()
Definition: EvaluateDisplayConditionsTest.php:326
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFlexFieldReferencingFlexFieldIsNotFoundInFieldValue
‪addDataThrowsExceptionIfFlexFieldReferencingFlexFieldIsNotFoundInFieldValue()
Definition: EvaluateDisplayConditionsTest.php:638
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFlexSheetConditionReferencesFieldFromSameSheet
‪addDataThrowsExceptionIfFlexSheetConditionReferencesFieldFromSameSheet()
Definition: EvaluateDisplayConditionsTest.php:542
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfRecordConditionHasNoOperand
‪addDataThrowsExceptionIfRecordConditionHasNoOperand()
Definition: EvaluateDisplayConditionsTest.php:290
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfVersionConditionHasNoIsKeyword
‪addDataThrowsExceptionIfVersionConditionHasNoIsKeyword()
Definition: EvaluateDisplayConditionsTest.php:344
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\matchConditionStrings
‪matchConditionStrings($condition, array $record, $expectedResult)
Definition: EvaluateDisplayConditionsTest.php:3708
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfVersionConditionHasInvalidOperand
‪addDataThrowsExceptionIfVersionConditionHasInvalidOperand()
Definition: EvaluateDisplayConditionsTest.php:398
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFieldConditionRangeComparisonHasInvalidMaxOperand
‪addDataThrowsExceptionIfFieldConditionRangeComparisonHasInvalidMaxOperand()
Definition: EvaluateDisplayConditionsTest.php:236
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\matchHideForNonAdminsReturnsTrueIfBackendUserIsAdmin
‪matchHideForNonAdminsReturnsTrueIfBackendUserIsAdmin()
Definition: EvaluateDisplayConditionsTest.php:3779
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFieldConditionHasNoFieldName
‪addDataThrowsExceptionIfFieldConditionHasNoFieldName()
Definition: EvaluateDisplayConditionsTest.php:110
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataEvaluatesUserCondition
‪addDataEvaluatesUserCondition()
Definition: EvaluateDisplayConditionsTest.php:452
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFlexFieldFieldConditionReferencesNotExistingFieldValue
‪addDataThrowsExceptionIfFlexFieldFieldConditionReferencesNotExistingFieldValue()
Definition: EvaluateDisplayConditionsTest.php:604
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFieldConditionHasNoOperand
‪addDataThrowsExceptionIfFieldConditionHasNoOperand()
Definition: EvaluateDisplayConditionsTest.php:164
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\matchHideForNonAdminsReturnsFalseIfBackendUserIsNotAdmin
‪matchHideForNonAdminsReturnsFalseIfBackendUserIsNotAdmin()
Definition: EvaluateDisplayConditionsTest.php:3806
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfVersionConditionHasInvalidIsKeyword
‪addDataThrowsExceptionIfVersionConditionHasInvalidIsKeyword()
Definition: EvaluateDisplayConditionsTest.php:362
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataRemovesTcaReferencingOtherFieldsInDisplayCondition
‪addDataRemovesTcaReferencingOtherFieldsInDisplayCondition(string $processedTcaFieldToBeRemovedPath, array $databaseRow, array $processedTca)
Definition: EvaluateDisplayConditionsTest.php:3445
‪TYPO3\CMS\Webhooks\Message\$record
‪identifier readonly int readonly array $record
Definition: PageModificationMessage.php:36
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFieldConditionHasInvalidOperator
‪addDataThrowsExceptionIfFieldConditionHasInvalidOperator()
Definition: EvaluateDisplayConditionsTest.php:146
‪TYPO3\CMS\Core\Authentication\BackendUserAuthentication
Definition: BackendUserAuthentication.php:62
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfConditionIsNotStringOrArray
‪addDataThrowsExceptionIfConditionIsNotStringOrArray()
Definition: EvaluateDisplayConditionsTest.php:74
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfVersionConditionHasNoOperand
‪addDataThrowsExceptionIfVersionConditionHasNoOperand()
Definition: EvaluateDisplayConditionsTest.php:380
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFlexSectionContainerFoundNoReferencedFieldValue
‪addDataThrowsExceptionIfFlexSectionContainerFoundNoReferencedFieldValue()
Definition: EvaluateDisplayConditionsTest.php:671
‪TYPO3\CMS\Backend\Form\FormDataProvider\EvaluateDisplayConditions
Definition: EvaluateDisplayConditions.php:31
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataTrowsExceptionIfFlexFieldSheetConditionReferencesNotExistingFieldValue
‪addDataTrowsExceptionIfFlexFieldSheetConditionReferencesNotExistingFieldValue()
Definition: EvaluateDisplayConditionsTest.php:574
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFieldConditionReqHasInvalidOperand
‪addDataThrowsExceptionIfFieldConditionReqHasInvalidOperand()
Definition: EvaluateDisplayConditionsTest.php:182
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataPassesFlexContextToUserCondition
‪addDataPassesFlexContextToUserCondition()
Definition: EvaluateDisplayConditionsTest.php:470
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfUserConditionHasNoUserfuncSpecified
‪addDataThrowsExceptionIfUserConditionHasNoUserfuncSpecified()
Definition: EvaluateDisplayConditionsTest.php:434
‪TYPO3\CMS\Core\Utility\ArrayUtility
Definition: ArrayUtility.php:26
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataRemovesTcaReferencingOtherFieldsInDisplayConditionDataProvider
‪static addDataRemovesTcaReferencingOtherFieldsInDisplayConditionDataProvider()
Definition: EvaluateDisplayConditionsTest.php:732
‪$GLOBALS
‪$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['adminpanel']['modules']
Definition: ext_localconf.php:25
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFieldConditionNumberComparisonHasInvalidOperand
‪addDataThrowsExceptionIfFieldConditionNumberComparisonHasInvalidOperand()
Definition: EvaluateDisplayConditionsTest.php:200
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfFieldConditionHasNoOperator
‪addDataThrowsExceptionIfFieldConditionHasNoOperator()
Definition: EvaluateDisplayConditionsTest.php:128
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfRecordConditionHasInvalidNewKeyword
‪addDataThrowsExceptionIfRecordConditionHasInvalidNewKeyword()
Definition: EvaluateDisplayConditionsTest.php:272
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIAConditionHasNoStringAsKey
‪addDataThrowsExceptionIAConditionHasNoStringAsKey()
Definition: EvaluateDisplayConditionsTest.php:54
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\addDataThrowsExceptionIfRecordConditionHasInvalidOperand
‪addDataThrowsExceptionIfRecordConditionHasInvalidOperand()
Definition: EvaluateDisplayConditionsTest.php:308
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\Fixtures\EvaluateDisplayConditionsTestClass
Definition: EvaluateDisplayConditionsTestClass.php:21
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider\EvaluateDisplayConditionsTest\conditionStringDataProvider
‪static conditionStringDataProvider()
Definition: EvaluateDisplayConditionsTest.php:3462
‪TYPO3\CMS\Backend\Tests\Unit\Form\FormDataProvider
Definition: DatabaseDefaultLanguagePageRowTest.php:18