* Pass the 'method' parameter to the 'getFieldList' function in the datatableModel class to ensure the retrieval of correct field settings for the data table on the product view list page of the program module
This commit is contained in:
@@ -90,14 +90,13 @@ class datatableModel extends model
|
||||
{
|
||||
$method = $this->app->getMethodName();
|
||||
$datatableId = $module . ucfirst($method);
|
||||
|
||||
$mode = isset($this->config->datatable->$datatableId->mode) ? $this->config->datatable->$datatableId->mode : 'table';
|
||||
$cfgMethod = ($module == 'program' && $method == 'productview') ? $method : '';
|
||||
|
||||
$module = zget($this->config->datatable->moduleAlias, "$module-$method", $module);
|
||||
if(!isset($this->config->$module)) $this->loadModel($module);
|
||||
if(isset($this->config->datatable->$datatableId->cols)) $setting = json_decode($this->config->datatable->$datatableId->cols, true);
|
||||
|
||||
$fieldList = $this->getFieldList($module);
|
||||
$fieldList = $this->getFieldList($module, $cfgMethod);
|
||||
if(empty($setting))
|
||||
{
|
||||
$setting = $this->formatFields($module, $fieldList);
|
||||
|
||||
Reference in New Issue
Block a user