@php $decodedData = is_string($data->data) ? json_decode($data->data, true) : $data->data; // Safely access data with optional handling $notificationGroup = $decodedData['subject'] ?? '-'; $subject = $decodedData['subject'] ?? ''; $notification = \Modules\NotificationTemplate\Models\NotificationTemplateContentMapping::where('subject', $subject)->first(); $notificationMessage = $notification->notification_message ?? 'Message not found'; @endphp
{{ $notificationGroup }}
{{ $notificationMessage }}