mirror of
https://github.com/Combodo/iTop.git
synced 2026-08-30 09:58:17 +02:00
N°2737 - Migrate table to DataTables plugin to be iso with the end-users portal - fix actions doesn't work after class change
This commit is contained in:
@@ -309,6 +309,10 @@ function ReloadSearchForm(divId, sClassName, sBaseClass, sContext, sTableId, sEx
|
||||
{
|
||||
oMap.table_inner_id = sExtraParams['table_inner_id'];
|
||||
}
|
||||
else{
|
||||
oMap.table_inner_id = sTableId;
|
||||
}
|
||||
|
||||
$.post(GetAbsoluteUrlAppRoot()+'pages/ajax.render.php?'+sContext, oMap,
|
||||
function (data) {
|
||||
oDiv.empty();
|
||||
|
||||
@@ -214,7 +214,7 @@ function DisplaySearchSet($oP, $oFilter, $bSearchForm = true, $sBaseClass = '',
|
||||
//search block
|
||||
$oBlockForm = null;
|
||||
if ($bSearchForm) {
|
||||
$aParams = array('open' => $bSearchFormOpen, 'table_id' => '1');
|
||||
$aParams = array('open' => $bSearchFormOpen, 'table_id' => 'result_1');
|
||||
if (!empty($sBaseClass)) {
|
||||
$aParams['baseClass'] = $sBaseClass;
|
||||
}
|
||||
@@ -245,7 +245,7 @@ function DisplaySearchSet($oP, $oFilter, $bSearchForm = true, $sBaseClass = '',
|
||||
$sTableId = 'result_1';
|
||||
}
|
||||
$aExtraParams['table_id'] = $sTableId;
|
||||
$oUIBlockForm = $oBlockForm->GetDisplay($oP, 'search_1');
|
||||
$oUIBlockForm = $oBlockForm->GetDisplay($oP, 'search_1',$aExtraParams);
|
||||
//add result block
|
||||
$oUIBlock = $oBlock->GetDisplay($oP, $sTableId);
|
||||
$oUIBlock->AddCSSClasses("display_block sf_results_area");
|
||||
|
||||
@@ -804,7 +804,7 @@ try
|
||||
$sSelectionMode = utils::ReadParam('selection_mode', null,false,'raw_data');
|
||||
$sResultListOuterSelector = utils::ReadParam('result_list_outer_selector', null,false,'raw_data');
|
||||
$scssCount = utils::ReadParam('css_count', null,false,'raw_data');
|
||||
$sTableInnerId = utils::ReadParam('table_inner_id', null,false,'raw_data');
|
||||
$sTableInnerId = utils::ReadParam('table_inner_id', $sTableId,false,'raw_data');
|
||||
|
||||
$oFilter = new DBObjectSearch($sClass);
|
||||
$oSet = new CMDBObjectSet($oFilter);
|
||||
|
||||
@@ -21,7 +21,7 @@ class DataTable extends UIContentBlock
|
||||
// Overloaded constants
|
||||
public const BLOCK_CODE = 'ibo-datatable';
|
||||
public const DEFAULT_HTML_TEMPLATE_REL_PATH = 'base/components/datatable/layout';
|
||||
public const DEFAULT_JS_TEMPLATE_REL_PATH = 'base/components/datatable/layout';
|
||||
public const DEFAULT_JS_ON_READY_TEMPLATE_REL_PATH = 'base/components/datatable/layout';
|
||||
public const DEFAULT_JS_LIVE_TEMPLATE_REL_PATH = 'base/components/datatable/layout';
|
||||
public const DEFAULT_JS_FILES_REL_PATH = [
|
||||
'lib/datatables/js/jquery.dataTables.min.js',
|
||||
|
||||
Reference in New Issue
Block a user