ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
base.php
Go to the documentation of this file.
1 <?php
2 
3 declare(strict_types=1);
4 
6 
10 function base()
11 {
12  global $DIC;
13  $f = $DIC->ui()->factory();
14  $r = $DIC->ui()->renderer();
15 
16  //construct with options and labels for aria and button.
17  $fs = $f->input()->viewControl()->fieldSelection(
18  [
19  'c1' => 'column 1',
20  'c2' => 'column 2',
21  'x' => '...'
22  ],
23  'shown columns',
24  'apply'
25  );
26 
27  //it's more fun to view this in a ViewControlContainer
28  $vc_container = $f->input()->container()->viewControl()->standard([$fs])
29  ->withRequest($DIC->http()->request());
30 
31  return $r->render([
32  $f->legacy('<pre>' . print_r($vc_container->getData(), true) . '</pre>'),
33  $f->divider()->horizontal(),
34  $vc_container
35  ]);
36 }
global $DIC
Definition: feed.php:28
base()
basic example of a FieldSelection ViewControl
Definition: base.php:10