{ * tooltip: string, * icon_classes: string, * js_row_action: string, * confirmation => { * message: string, * message_row_data: string, * remember_choice_pref_key: string * } * } */ protected $aRowActions; /** * Set row actions. * * @param array $aRowActions * * @return $this */ public function SetRowActions(array $aRowActions) { $this->aRowActions = $aRowActions; return $this; } /** * Get row actions. * * @return array|null */ public function GetRowActions(): ?array { return $this->aRowActions; } /** * Return true if row actions is set and not empty. * * @return bool */ public function HasRowActions(): bool { return isset($this->aRowActions) && count($this->aRowActions); } /** * Return row actions template. * * @return \Combodo\iTop\Application\UI\Base\Component\Template\Template */ public function GetRowActionsTemplate() { return DataTableUIBlockFactory::MakeActionRowToolbarTemplate($this); } /** * GetRowActionsConfirmDialog. * * @return \Combodo\iTop\Application\UI\Base\Component\Html\Html */ public function GetRowActionsConfirmDialog() { static::$bDialogInitialized = true; $oDialog = DialogUIBlockFactory::MakeNeutral('', '
', 'table-row-action-confirmation-dialog'); $oContent = UIContentBlockUIBlockFactory::MakeStandard(); $oContent->AddCSSClass('ibo-row-action--confirmation--do-not-show-again'); $checkBox = InputUIBlockFactory::MakeStandard('checkbox', 'do_not_show_again', false); $checkBox->AddCSSClass('ibo-row-action--confirmation--do-not-show-again--checkbox'); $checkBox->SetLabel(\Dict::S('UI:UserPref:DoNotShowAgain')); $oContent->AddSubBlock($checkBox); $oDialog->AddSubBlock($oContent); return $oDialog; } public function GetRowActionsConfirmDialogInitializedFlag() { return static::$bDialogInitialized; } }