From e066681dfad3025f9edb1681ceb4a263b913b1c2 Mon Sep 17 00:00:00 2001 From: Seamus Lee Date: Tue, 25 Aug 2020 17:57:32 +1000 Subject: [PATCH] [REF] Ensure that the form param _id is set when adding a new group with the newly created group id so that consumers of the hook_civicrm_postProcess can access the id --- CRM/Group/Form/Edit.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CRM/Group/Form/Edit.php b/CRM/Group/Form/Edit.php index d9be20cdfb..e384dc36cc 100644 --- a/CRM/Group/Form/Edit.php +++ b/CRM/Group/Form/Edit.php @@ -371,7 +371,8 @@ WHERE title = %1 ); $group = CRM_Contact_BAO_Group::create($params); - + // Set the entity id so it is available to postProcess hook consumers + $this->setEntityId($group->id); //Remove any parent groups requested to be removed if (!empty($this->_groupValues['parents'])) { $parentGroupIds = explode(',', $this->_groupValues['parents']); -- 2.25.1