Unverified Commit 4e2d3adb authored by colemanw's avatar colemanw Committed by GitHub

Merge pull request #13473 from deb1990/C51-384-add-case-token-in-email

C51-384: Added case tokens on Email Activity Modal
parents 4e6e5cc7 d7e297be
......@@ -163,6 +163,13 @@ class CRM_Contact_Form_Task_Email extends CRM_Contact_Form_Task {
*/
public function listTokens() {
$tokens = CRM_Core_SelectValues::contactTokens();
if (isset($this->_caseId) || isset($this->_caseIds)) {
// For a single case, list tokens relevant for only that case type
$caseTypeId = isset($this->_caseId) ? CRM_Core_DAO::getFieldValue('CRM_Case_DAO_Case', $this->_caseId, 'case_type_id') : NULL;
$tokens += CRM_Core_SelectValues::caseTokens($caseTypeId);
}
return $tokens;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment