@extends('core::base.layouts.master') @section('title') {{ translate('Post Category') }} @endsection @section('custom_css') @include('core::base.includes.data_table.css') @endsection @section('main_content')

{{ translate('Post Categories') }}

{{-- Category Filter Buttons --}}
@php $count = ['tl_blog_categories.id', '!=', null]; if (request()->search) { $if_search = '&search=' . request()->search; $all_blog_request = '?status=search_text&search=' . request()->search; $search = request()->search; } else { $if_search = ''; $all_blog_request = ''; $search = ''; } @endphp {{ translate('All') }}( {{ count(getCategory(null, $search)) }} ) {{ translate('Featured') }}({{ count(getCategory([['is_featured', '1']], $search)) }}) @if (request()->input('search')) {{ translate('Result For') }} : ({{ request()->input('search') }}) @endif
{{-- Category Filter Buttons Ends --}}
@php $key = 1; @endphp @foreach ($bcategories as $bcategory) @php $key++; @endphp @endforeach
{{ translate('Name') }} {{ translate('Parent') }} {{ translate('Featured') }} {{ translate('Status') }} {{ translate('Actions') }}
{{ $bcategory->translation('name', getLocale()) }} @if ($bcategory->parentCategory != null) {{ $bcategory->parentCategory->name }} @endif @if ($bcategory->permalink !== 'uncategorized') @endif @if ($bcategory->permalink !== 'uncategorized') @endif @if ($bcategory->permalink !== 'uncategorized') @endif
@if (!(request()->input('page') && request()->input('page') > $bcategories->lastPage())) {{-- pagination --}}
{{-- Blog Page Count Info --}}

{{ translate('Showing') }} @if (!request()->input('page') || request()->input('page') == 1) 1 to {{ count($bcategories) }} @else @php if (request()->input('per_page')) { $per_page_count = request()->input('per_page'); } else { $per_page_count = 10; } $start_count = ((int) request()->input('page') - 1) * $per_page_count + 1; if (request()->input('page') == $bcategories->lastPage()) { $end_count = $bcategories->total(); } else { $end_count = (int) request()->input('page') * $per_page_count; } @endphp {{ $start_count . ' to ' . $end_count }} @endif {{ translate('items of') }} {{ $bcategories->total() }}

@endif
@endsection @section('custom_scripts') @include('core::base.includes.data_table.script') @endsection