@extends('layouts.app')
@section('title')
Press Release
@parent
@stop
@section('content')
<style>
    news-entry {
        cursor: pointer;
    }

    news-text,
    news-id {
        display: none;
    }
</style>
<main id="static">

    <section>
        <div class="container">
            <div class="d-flex justify-content-between">
                <h3 class="h4">Press Release</h3>
                <div class="col-md-6 px-0">
                    {{ Form::open(array('route' => array('press-release'),'method'=> 'get' )) }}
                    @csrf
                    <div class="d-flex w-100">
                        <input type="text" name="search" class="form-control w-100" placeholder="Search for...">
                        <button class="btn btn-info bg-siteblue border-0" type="submit"> <i class="fa fa-search"></i></button>
                    </div>
                    {{ Form::close() }}
                </div>
            </div>
            <hr>
            @if (count($press_release) > 0)
            @foreach ($press_release as $press_release_list)
            <news-list news-list-type="order">
                <a target="_blank" href="/press-release-detail/{{$press_release_list->press_release_id}}">
                    <news-entry class="card card-body py-2 w-100 mb-2 border shadow-sm h6 border-primary-light">
                        <news-title>{{$press_release_list->title}}</news-title>
                        <news-history>
                            <publication-date class="small badge bg-primary-light float-right text-white py-1" media-type="print">
                                {{gmdate("Y-F-d", $press_release_list->press_release_date)}}
                            </publication-date>
                        </news-history>
                    </news-entry>
                </a>
            </news-list>
            @endforeach
            @else
            <div>
                <center>No Record</center>
            </div>
            @endif
        </div>
        @if (count($press_release) > 0)
        <div class="d-flex justify-content-center">{{ $press_release->appends(request()->input())->links() }}</dib>
            @endif
    </section>
</main>
<!----Main Section Ends---->
@endsection