From f26c7f76360e66bb184b1785b8a48b73db93e668 Mon Sep 17 00:00:00 2001 From: Igor Manjencic Date: Wed, 13 Dec 2023 17:25:13 +0100 Subject: [PATCH] feat(ZMS-1711): fix template --- zmsentities/src/Zmsentities/Helper/Messaging.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/zmsentities/src/Zmsentities/Helper/Messaging.php b/zmsentities/src/Zmsentities/Helper/Messaging.php index 9040d17df..73a8a2304 100644 --- a/zmsentities/src/Zmsentities/Helper/Messaging.php +++ b/zmsentities/src/Zmsentities/Helper/Messaging.php @@ -196,8 +196,8 @@ public static function getNotificationContent(Process $process, Config $config, protected static function getTemplate($type, $status, ?Process $process = null) { if ($process) { - $provider = $process->getFirstAppointment()->getScope()->getProvider(); - $providerName = $provider->getDisplayName() ?? $provider->getName(); + $provider = $process->scope->provider; + $providerName = $provider->displayName; $providerTemplateName = self::getProviderTemplateName($providerName); $providerTemplate = 'custom/' . $type . '/' . $status . '/' . $providerTemplateName . '.twig';