@if($result['opportunities']->thread_type == "accounts") @endif @if(count((array) $result['opportunities']['accounts'])>0 && !empty($result['opportunities']['accounts']['customers']->customers_telephone) && $result['opportunities']->thread_type == "accounts") @endif @if(count((array) $result['opportunities']['accounts'])>0 && !empty($result['opportunities']['accounts']['customers']->customers_firstname) && $result['opportunities']->thread_type == "leads") @endif @if(count((array) $result['opportunities']['accounts'])>0 && !empty($result['opportunities']['accounts']['customers']->customers_telephone) && $result['opportunities']->thread_type == "leads") @endif @if(count((array) $result['opportunities'])>0 && !empty($result['opportunities']->id)) @endif @if(count((array) $result['opportunities'])>0 && !empty($result['opportunities']->subject)) @endif @if(count((array) $result['opportunities'])>0 && !empty($result['opportunities']['tickets_categories']->name)) @endif @if(count((array) $result['opportunities'])>0 && !empty($result['opportunities']['tickets_prioritys']->name)) @endif @if(count((array) $result['opportunities'])>0 && !empty($result['opportunities']['tickets_status']->name)) @endif @if(count((array) $result['opportunities']['managed_by'])>0 && !empty($result['opportunities']['managed_by']->first_name)) @endif @if(count((array) $result['opportunities'])>0 && !empty($result['opportunities']['assigned_to_user']->first_name)) @endif @if(count((array) $result['opportunities'])>0 && !empty($result['opportunities']->tickets_created_at)) @endif @if(count((array) $result['opportunities']['comments'])>0) @endif
Account Number: @if(!empty($result['opportunities']['accounts']->name)) {{ $result['opportunities']['accounts']->name }} @else {{ implode(', ', $accountNumber) }} @endif
Telephone: {{$result['opportunities']['accounts']['customers']->customers_telephone}}
Leads: {{$result['opportunities']['accounts']['customers']->customers_firstname}} {{$result['opportunities']['accounts']['customers']->customers_lastname}}
Telephone: {{$result['opportunities']['accounts']['customers']->customers_telephone}}
Tickets Number: {{$result['opportunities']->tickets_number}}
Subject: {{$result['opportunities']->subject}}
Categories: {{$result['opportunities']['tickets_categories']->name}}
Priorities: {{$result['opportunities']['tickets_prioritys']->name}}
Status: {{$result['opportunities']['tickets_status']->name}}
Assigned by: {{$result['opportunities']['managed_by']->first_name}} {{$result['opportunities']['managed_by']->last_name}}
Assigned to: {{$result['opportunities']['assigned_to_user']->first_name}} {{$result['opportunities']['assigned_to_user']->last_name}}
Created date: {{date('d-m-Y H:i:s', strtotime($result['opportunities']->tickets_created_at))}}
Description: @foreach ($result['opportunities']['comments'] as $cmVal) @if(!empty($cmVal->description))
{{$cmVal['managed_by']->first_name}} {{$cmVal['managed_by']->last_name}} updated on {{date('d-m-Y H:i:s', strtotime($cmVal->created_at))}}@if(!empty($cmVal->talk_time)), Call Time: {{$cmVal->talk_time}} @endif
{!!nl2br($cmVal->description)!!}
@endif @endforeach