mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-23 10:38:45 +02:00
N°3551 - Migrate module to new UIBlock system : Customer Survey
This commit is contained in:
@@ -168,4 +168,19 @@ class DataTable extends UIContentBlock
|
||||
return "$('#".$this->sId."').DataTable().clearPipeline();
|
||||
$('#".$this->sId."').DataTable().ajax.reload(null, false);";
|
||||
}
|
||||
|
||||
public function GetDisabledSelect(): array
|
||||
{
|
||||
$aExtraParams = $this->aAjaxData['extra_params'];
|
||||
if(isset($aExtraParams['selection_enabled']) ){
|
||||
$aListDisabled = [];
|
||||
foreach( $aExtraParams['selection_enabled'] as $sKey=>$bValue){
|
||||
if ($bValue == false) {
|
||||
$aListDisabled[] = $sKey;
|
||||
}
|
||||
}
|
||||
return $aListDisabled;
|
||||
}
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
@@ -884,6 +884,8 @@ class DataTableUIBlockFactory extends AbstractUIBlockFactory
|
||||
'selected_rows', /** array list of Ids already selected when displaying the datatable */
|
||||
'display_aliases', /** string comma separated list of class aliases to display */
|
||||
'list_id', /** string list outer id */
|
||||
'selection_enabled', /** list of id in witch select is allowed, if not exists all lines are selectable */
|
||||
'id_for_select', /**give definition of id for select checkbox*/
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user