From 61750d67203fe798e117a0041721c9a6e2400dcf Mon Sep 17 00:00:00 2001 From: Deepak Srivastava Date: Thu, 18 Jul 2013 16:14:35 +0530 Subject: [PATCH] CRM-12912 ---------------------------------------- * CRM-12912: http://issues.civicrm.org/jira/browse/CRM-12912 --- CRM/Core/BAO/UFField.php | 3 +++ CRM/UF/Form/Field.php | 2 ++ 2 files changed, 5 insertions(+) diff --git a/CRM/Core/BAO/UFField.php b/CRM/Core/BAO/UFField.php index 43093458cf..d5d627c31d 100644 --- a/CRM/Core/BAO/UFField.php +++ b/CRM/Core/BAO/UFField.php @@ -824,6 +824,9 @@ SELECT id 'Organization' => CRM_Contact_BAO_Contact::importableFields('Organization', FALSE, FALSE, TRUE, TRUE, TRUE), ); + // include hook injected fields + $fields['Contact'] = array_merge($fields['Contact'], CRM_Contact_BAO_Query_Hook::singleton()->getFields()); + // add current employer for individuals $fields['Individual']['current_employer'] = array( 'name' => 'organization_name', diff --git a/CRM/UF/Form/Field.php b/CRM/UF/Form/Field.php index ae941873df..1c7849f2c3 100644 --- a/CRM/UF/Form/Field.php +++ b/CRM/UF/Form/Field.php @@ -149,6 +149,8 @@ class CRM_UF_Form_Field extends CRM_Core_Form { $this->_fields = array_merge(CRM_Event_BAO_Query::getParticipantFields(), $this->_fields); } + $this->_fields = array_merge($this->_fields, CRM_Contact_BAO_Query_Hook::singleton()->getFields()); + $this->_selectFields = array(); foreach ($this->_fields as $name => $field) { // lets skip note for now since we dont support it -- 2.25.1