// list icon backward compat
This commit is contained in:
@@ -1846,6 +1846,7 @@ class AdminControllerCore extends Controller
|
||||
$helper->position_identifier = $this->position_identifier;
|
||||
$helper->controller_name = $this->controller_name;
|
||||
$helper->list_id = isset($this->list_id) ? $this->list_id : $this->table;
|
||||
$helper->bootstrap = $this->bootstrap;
|
||||
|
||||
// For each action, try to add the corresponding skip elements list
|
||||
$helper->list_skip_actions = $this->list_skip_actions;
|
||||
|
||||
@@ -36,6 +36,7 @@ class HelperCore
|
||||
public $show_toolbar = true;
|
||||
public $context;
|
||||
public $toolbar_scroll = false;
|
||||
public $bootstrap = false;
|
||||
|
||||
/**
|
||||
* @var Module
|
||||
|
||||
@@ -266,16 +266,24 @@ class HelperListCore extends Helper
|
||||
}
|
||||
elseif (isset($params['icon']) && isset($tr[$key]) && (isset($params['icon'][$tr[$key]]) || isset($params['icon']['default'])))
|
||||
{
|
||||
if (isset($params['icon'][$tr[$key]]) && is_array($params['icon'][$tr[$key]]))
|
||||
$this->_list[$index][$key] = array(
|
||||
'src' => $params['icon'][$tr[$key]]['src'],
|
||||
'alt' => $params['icon'][$tr[$key]]['alt'],
|
||||
);
|
||||
if (!$this->bootstrap)
|
||||
{
|
||||
if (isset($params['icon'][$tr[$key]]) && is_array($params['icon'][$tr[$key]]))
|
||||
$this->_list[$index][$key] = array(
|
||||
'src' => $params['icon'][$tr[$key]]['src'],
|
||||
'alt' => $params['icon'][$tr[$key]]['alt'],
|
||||
);
|
||||
else
|
||||
$this->_list[$index][$key] = array(
|
||||
'src' => isset($params['icon'][$tr[$key]]) ? $params['icon'][$tr[$key]] : $params['icon']['default'],
|
||||
'alt' => isset($params['icon'][$tr[$key]]) ? $params['icon'][$tr[$key]] : $params['icon']['default'],
|
||||
);
|
||||
}
|
||||
else
|
||||
$this->_list[$index][$key] = array(
|
||||
'src' => isset($params['icon'][$tr[$key]]) ? $params['icon'][$tr[$key]] : $params['icon']['default'],
|
||||
'alt' => isset($params['icon'][$tr[$key]]) ? $params['icon'][$tr[$key]] : $params['icon']['default'],
|
||||
);
|
||||
if (isset($params['icon'][$tr[$key]]))
|
||||
$this->_list[$index][$key] = array(
|
||||
'class' => $params['icon'][$tr[$key]],
|
||||
);
|
||||
}
|
||||
elseif (isset($params['type']) && $params['type'] == 'float')
|
||||
$this->_list[$index][$key] = rtrim(rtrim($tr[$key], '0'), '.');
|
||||
|
||||
Reference in New Issue
Block a user