From d711dda7ea1c991fe5b6515e412d8c91d5ae6885 Mon Sep 17 00:00:00 2001 From: Pradeep Nayak Date: Sat, 22 Aug 2020 14:53:02 +0100 Subject: [PATCH] Batch Update via Profile does not supply data for editing when custom fields created after participant added to event --- CRM/Event/Form/Task/Batch.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/CRM/Event/Form/Task/Batch.php b/CRM/Event/Form/Task/Batch.php index 9a52015e42..f39d72ac20 100644 --- a/CRM/Event/Form/Task/Batch.php +++ b/CRM/Event/Form/Task/Batch.php @@ -171,24 +171,22 @@ class CRM_Event_Form_Task_Batch extends CRM_Event_Form_Task { $customValue['extends_entity_column_value'] ); } - $entityColumnValueRole = $entityColumnValue[$roleId] ?? NULL; - $entityColumnValueEventType = in_array($eventTypeId, $entityColumnValue) ? $eventTypeId : NULL; if (($this->_roleCustomDataTypeID == $customValue['extends_entity_column_id']) && - ($entityColumnValueRole) + in_array($roleId, $entityColumnValue) ) { CRM_Core_BAO_UFGroup::buildProfile($this, $field, NULL, $participantId); } elseif (($this->_eventNameCustomDataTypeID == $customValue['extends_entity_column_id']) && - ($eventId == $entityColumnValueRole) + in_array($eventId, $entityColumnValue) ) { CRM_Core_BAO_UFGroup::buildProfile($this, $field, NULL, $participantId); } elseif ($this->_eventTypeCustomDataTypeID == $customValue['extends_entity_column_id'] && - ($entityColumnValueEventType == $eventTypeId) + in_array($eventTypeId, $entityColumnValue) ) { CRM_Core_BAO_UFGroup::buildProfile($this, $field, NULL, $participantId); } - elseif (CRM_Utils_System::isNull($entityColumnValueRole)) { + elseif (CRM_Utils_System::isNull($entityColumnValue)) { CRM_Core_BAO_UFGroup::buildProfile($this, $field, NULL, $participantId); } } -- 2.25.1