@php if($ratings->count == 0 ){ $scr = 0; } else{ $scr= $ratings->score/$ratings->count; } $scr = round($scr * 2)/2; $tempscr = $scr; if(in_array($scr,[0.5,1.5,2.5,3.5,4.5 ])){ $tempscr = $tempscr +1; } @endphp
@for($i=1;$i<=$tempscr;$i++) @if($tempscr - $i != 0.5) @else @endif @endfor @for($i=1;$i<=5-$scr;$i++) @endfor {{$scr}}
Your Rating
{{__('rating')}}
{{$result[0]->m_title}} {{__('average')}} {{$scr}} / 5 ({{$ratings->count}} {{__('vote')}})
{{__('order')}}
@if(isset($ranking->count))
{{$rankings}}, {{$ranking->count}} {{__('view')}}
@else
Təyin olunmayıb , 0 {{__('view')}}
@endif
@isset( $manga_id->m_alternative )
{{__('alternatives')}}
{{$manga_id->m_alternative}}
@endisset @isset( $manga_id->m_author )
{{__('authors')}}
@php // Handle both single ID and comma-separated list of IDs $authorIds = is_array($manga_id->m_author) ? $manga_id->m_author : (strpos($manga_id->m_author, ',') !== false ? explode(',', $manga_id->m_author) : [$manga_id->m_author]); // Filter out empty values and convert to integers $authorIds = array_filter(array_map(function($id) { return trim($id); }, $authorIds), function($id) { return !empty($id) && is_numeric($id); }); // Convert to integers for consistent key matching $authorIds = array_map('intval', $authorIds); // Fetch all authors in a single query $authors = !empty($authorIds) ? \App\Author::whereIn('id', $authorIds)->get()->keyBy('id') : collect(); @endphp @foreach($authorIds as $index => $authorId) @php $author = isset($authors[$authorId]) ? $authors[$authorId] : null; @endphp @if( $author && isset($author->fullname) ) @if( $index < count($authorIds) - 1 ), @endif @endif @endforeach {{-- ,--}} {{-- --}}
@endisset @isset( $manga_id->m_artist )
{{__('artists')}}
@php // Handle both single ID and comma-separated list of IDs $artistIds = is_array($manga_id->m_artist) ? $manga_id->m_artist : (strpos($manga_id->m_artist, ',') !== false ? explode(',', $manga_id->m_artist) : [$manga_id->m_artist]); // Filter out empty values and convert to integers $artistIds = array_filter(array_map(function($id) { return trim($id); }, $artistIds), function($id) { return !empty($id) && is_numeric($id); }); // Convert to integers for consistent key matching $artistIds = array_map('intval', $artistIds); // Fetch all artists in a single query $artists = !empty($artistIds) ? \App\Artist::whereIn('id', $artistIds)->get()->keyBy('id') : collect(); @endphp @foreach($artistIds as $index => $artistId) @php $artist = isset($artists[$artistId]) ? $artists[$artistId] : null; @endphp @if( $artist && isset($artist->fullname) ) @if( $index < count($artistIds) - 1 ), @endif @endif @endforeach {{-- ,
@endisset @isset( $manga_id->m_category_id )
{{__('categories')}}
@foreach(explode(',', $manga_id->m_category_id) as $item) @php $temp = \App\MangaCategory::where('id','=',$item)->first(); @endphp @if( isset($temp->m_name) ) @if( !$loop->last and isset($temp->$loc)), @endif @endif @endforeach {{-- ,--}} {{-- ,
@endisset {{--
--}} {{--
Type
--}} {{--
Updating
--}} {{--
--}}