From ee1ccac5c892fbce328fe747d0909b9a3f5385b7 Mon Sep 17 00:00:00 2001 From: Ellen Hendricks Date: Thu, 21 Apr 2016 13:17:12 -0500 Subject: [PATCH] CRM-18459 - Case activity emails not sent to any added Case Resources Correct the php and template files so the checkboxes are indexed correctly. ---------------------------------------- * CRM-18459: Case activity emails not sent to any added Case Resources https://issues.civicrm.org/jira/browse/CRM-18459 --- CRM/Case/Form/Activity.php | 4 +++- templates/CRM/Case/Form/Activity.tpl | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CRM/Case/Form/Activity.php b/CRM/Case/Form/Activity.php index 4aef5c0270..9147cfb02c 100644 --- a/CRM/Case/Form/Activity.php +++ b/CRM/Case/Form/Activity.php @@ -307,7 +307,9 @@ class CRM_Case_Form_Activity extends CRM_Activity_Form_Activity { if (!empty($this->_relatedContacts)) { $checkBoxes = array(); foreach ($this->_relatedContacts as $id => $row) { - $checkBoxes[$id] = $this->addElement('checkbox', $id, NULL, NULL, array('class' => 'select-row')); + foreach ($row as $key => $value) { + $checkBoxes[$key] = $this->addElement('checkbox', $key, NULL, NULL, array('class' => 'select-row')); + } } $this->addGroup($checkBoxes, 'contact_check'); diff --git a/templates/CRM/Case/Form/Activity.tpl b/templates/CRM/Case/Form/Activity.tpl index 1f1baa6c8b..6d3669eee2 100644 --- a/templates/CRM/Case/Form/Activity.tpl +++ b/templates/CRM/Case/Form/Activity.tpl @@ -216,7 +216,7 @@ {foreach from=$searchRows item=row key=id} {foreach from=$searchRows.$id item=row1 key=id1} - {$form.contact_check[$id].html} + {$form.contact_check[$id1].html} {$row1.role} {$row1.display_name} {$row1.email} -- 2.25.1