CRM_Core_Form_Tag::buildQuickForm was previously being passed an array of [id => name]
but it was wastefully ignoring the passed ids and looking it up from the name.
Now due to
bcf668d is being passed an array of [id => label] which is all it needs,
just had to remove the wasteful id lookup when it's already there.
$form->assign('isTagset', FALSE);
$mode = NULL;
- foreach ($parentNames as &$parentNameItem) {
- // get the parent id for tag list input for keyword
- $parentId = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_Tag', $parentNameItem, 'id', 'name');
-
+ foreach ($parentNames as $parentId => $parentNameItem) {
// check if parent exists
if ($parentId) {
$tagsetItem = $tagsetElementName . 'parentId_' . $parentId;