Fixed gh-394 so to be able to target the component instead of a single view.

This commit is contained in:
2019-05-06 03:05:15 +02:00
parent d7b555e7af
commit a23f1fe79a
7 changed files with 48 additions and 30 deletions

View File

@ -2700,7 +2700,10 @@ class Fields extends Structure
$otherViews = $view_name_list;
$otherView = $view_name_single;
}
$this->categoryBuilder[$view_name_list] = array('code' => $name, 'name' => $listLangName);
// get the xml extension name
$_extension = $this->setPlaceholders(ComponentbuilderHelper::getBetween($field['settings']->xml, 'extension="', '"'), $this->placeholders);
// load the category builder
$this->categoryBuilder[$view_name_list] = array('code' => $name, 'name' => $listLangName, 'extension' => $_extension);
// also set code name for title alias fix
$this->catCodeBuilder[$view_name_single] = array('code' => $name, 'views' => $otherViews, 'view' => $otherView);
}