Skip to content
Snippets Groups Projects
Commit 1c8e97c8 authored by JediKev's avatar JediKev
Browse files

issue: Canned Response Variables

This addresses issue 4756 where the `%{recipient.ticket_link}` variable is
not being replaced when the canned response is loaded in the reply box; all
other link variables work. This is due to the recipient object not being
passed to the variableReplacer which means the ticket_link is not available.
This adds the recipient object to the variableReplacer so the ticket_link
variable is properly replaced like the others on load.
parent 2cbcff69
No related branches found
No related tags found
No related merge requests found
...@@ -364,7 +364,7 @@ class TicketsAjaxAPI extends AjaxController { ...@@ -364,7 +364,7 @@ class TicketsAjaxAPI extends AjaxController {
$format.='.plain'; $format.='.plain';
$varReplacer = function (&$var) use($ticket) { $varReplacer = function (&$var) use($ticket) {
return $ticket->replaceVars($var); return $ticket->replaceVars($var, array('recipient' => $ticket->getOwner()));
}; };
include_once(INCLUDE_DIR.'class.canned.php'); include_once(INCLUDE_DIR.'class.canned.php');
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment