ILIAS  release_9 Revision v9.13-25-g2c18ec4c24f
ILIAS\LegalDocuments\SmoothTableConfig Class Reference

This class takes care of the order in which the methods must be called. More...

+ Inheritance diagram for ILIAS\LegalDocuments\SmoothTableConfig:
+ Collaboration diagram for ILIAS\LegalDocuments\SmoothTableConfig:

Public Member Functions

 __construct (private readonly ilTable2GUI $target)
 
 setTitle (string $a_title, string $a_icon="", string $a_icon_alt="")
 
 setExternalSorting (bool $a_val)
 
 setDefaultOrderField (string $a_defaultorderfield)
 
 setDefaultOrderDirection (string $a_defaultorderdirection)
 
 setSelectableColumns (... $names)
 
 addMultiCommand (string $a_cmd, string $a_text)
 
 addCommandButton (string $a_cmd, string $a_text, string $a_onclick='', string $a_id="", string $a_class="")
 
 asFilter (string $reset_command)
 
 flush ()
 

Private Attributes

array $later = []
 

Detailed Description

This class takes care of the order in which the methods must be called.

Definition at line 28 of file SmoothTableConfig.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\LegalDocuments\SmoothTableConfig::__construct ( private readonly ilTable2GUI  $target)

Definition at line 33 of file SmoothTableConfig.php.

34  {
35  }

Member Function Documentation

◆ addCommandButton()

ILIAS\LegalDocuments\SmoothTableConfig::addCommandButton ( string  $a_cmd,
string  $a_text,
string  $a_onclick = '',
string  $a_id = "",
string  $a_class = "" 
)

Implements ILIAS\LegalDocuments\TableConfig.

Definition at line 70 of file SmoothTableConfig.php.

76  : void {
77  $args = func_get_args();
78  $this->later[] = fn() => $this->target->addCommandButton(...$args);
79  }

◆ addMultiCommand()

ILIAS\LegalDocuments\SmoothTableConfig::addMultiCommand ( string  $a_cmd,
string  $a_text 
)

Implements ILIAS\LegalDocuments\TableConfig.

Definition at line 65 of file SmoothTableConfig.php.

65  : void
66  {
67  $this->later[] = fn() => $this->target->addMultiCommand($a_cmd, $a_text);
68  }

◆ asFilter()

ILIAS\LegalDocuments\SmoothTableConfig::asFilter ( string  $reset_command)

Implements ILIAS\LegalDocuments\TableConfig.

Definition at line 81 of file SmoothTableConfig.php.

81  : TableFilter
82  {
83  $filter = new SmoothTableFilter($this->target, $reset_command);
84  $this->later[] = $filter->flush(...);
85  return $filter;
86  }

◆ flush()

ILIAS\LegalDocuments\SmoothTableConfig::flush ( )

Definition at line 88 of file SmoothTableConfig.php.

88  : void
89  {
90  array_map(fn($proc) => $proc(), $this->later);
91  $this->later = [];
92  }

◆ setDefaultOrderDirection()

ILIAS\LegalDocuments\SmoothTableConfig::setDefaultOrderDirection ( string  $a_defaultorderdirection)

Implements ILIAS\LegalDocuments\TableConfig.

Definition at line 55 of file SmoothTableConfig.php.

55  : void
56  {
57  $this->target->setDefaultOrderDirection($a_defaultorderdirection);
58  }

◆ setDefaultOrderField()

ILIAS\LegalDocuments\SmoothTableConfig::setDefaultOrderField ( string  $a_defaultorderfield)

Implements ILIAS\LegalDocuments\TableConfig.

Definition at line 50 of file SmoothTableConfig.php.

50  : void
51  {
52  $this->target->setDefaultOrderField($a_defaultorderfield);
53  }

◆ setExternalSorting()

ILIAS\LegalDocuments\SmoothTableConfig::setExternalSorting ( bool  $a_val)

Implements ILIAS\LegalDocuments\TableConfig.

Definition at line 45 of file SmoothTableConfig.php.

45  : void
46  {
47  $this->target->setExternalSorting($a_val);
48  }

◆ setSelectableColumns()

ILIAS\LegalDocuments\SmoothTableConfig::setSelectableColumns (   $names)

Implements ILIAS\LegalDocuments\TableConfig.

Definition at line 60 of file SmoothTableConfig.php.

60  : void
61  {
62  $this->target->setSelectableColumns(...$names);
63  }

◆ setTitle()

ILIAS\LegalDocuments\SmoothTableConfig::setTitle ( string  $a_title,
string  $a_icon = "",
string  $a_icon_alt = "" 
)

Implements ILIAS\LegalDocuments\TableConfig.

Definition at line 37 of file SmoothTableConfig.php.

41  : void {
42  $this->target->setTitle(...func_get_args());
43  }

Field Documentation

◆ $later

array ILIAS\LegalDocuments\SmoothTableConfig::$later = []
private

Definition at line 31 of file SmoothTableConfig.php.


The documentation for this class was generated from the following file: