@extends("admin/layouts.master-soyuz") @section('title','Block Detail Page Advertising | ') @section("body")
List Block Detail Page Ads
@can('blockadvertisments.create') + Add New Block Detail Advertise @endcan
@foreach($details as $key => $detail) @endforeach
ID Preview Ad Position Details Status Action
{{ $key+1 }} @if($detail->linkby != 'adsense') @else Google adsense preview not available ! @endif @if($detail->position == 'category')

On Category Page

@else

On Product Detail Page

@endif

Display On: @php $detailpage = App\Category::where('id',$detail->linked_id)->first(); if(!isset($detailpage)){ $detailpage = App\Product::where('id',$detail->linked_id)->first(); } @endphp @if(isset($detailpage)) @if(isset($detailpage['name'])) {{ $detailpage['name'] ?? '-' }} @else {{ $detailpage['title'] ?? '-' }} @endif @endif

Linked To: @if(isset($detailpage)) @if($detail->linkby == 'detail') {{ $detail->product['name'] ?? '-' }} @elseif($detail->linkby == 'category') {{ $detail->category['title'] ?? '-' }} @elseif($detail->linkby == 'url') Custom URL @elseif($detail->linkby == 'adsense') Google Adsense Script @endif

@if($detail->top_heading !='')

Heading Text: {{ $detail->top_heading }}

@endif @if($detail->btn_text != '')

Button text: {{ $detail->btn_text }}

@endif @endif
@can('blockadvertisments.edit')
{{csrf_field()}}
@endcan
@can('blockadvertisments.edit') @endcan @can('blockadvertisments.delete') @endcan
@can('blockadvertisments.delete') @foreach($details as $detail) @endforeach @endcan @endsection