@extends('admin.layout') @section('content')
{{ __('Messages') }}
@includeIf('admin.partials.languages')
@if (count($messages) == 0)

{{ __('NO MESSAGE FOUND') . '!' }}

@else
@foreach ($messages as $message) @php $product_content = App\Models\Listing\ListingProductContent::where( 'listing_product_id', $message->product_id, ) ->where('language_id', $language->id) ->first(); $listing_content = App\Models\Listing\ListingContent::where([ ['listing_id', @$product_content->listing_id], ['language_id', $language->id], ])->first(); @endphp @endforeach
{{ __('Listing Title') }} {{ __('Product Title') }} {{ __('Name') }} {{ __('Email ID') }} {{ __('Actions') }}
@if (!empty($listing_content)) {{ strlen($listing_content->title) > 40 ? mb_substr($listing_content->title, 0, 40, 'utf-8') . '...' : $listing_content->title }} @endif @if (!empty($product_content)) {{ strlen($product_content->title) > 40 ? mb_substr($product_content->title, 0, 40, 'utf-8') . '...' : $product_content->title }} @endif {{ $message->name }} {{ $message->email }}
@csrf
@endif
@include('admin.message.message') @endsection