@extends('layouts.master')
@section('page-css')
    <link rel="stylesheet" href="{{asset('assets/styles/vendor/datatables.min.css')}}">
    <link rel="stylesheet" href="{{asset('assets/styles/vendor/toastr.css')}}">
@endsection

@section('main-content')
    <div class="breadcrumb">
        <h1>لیست سفارشات</h1>
        <ul>
            <li>لیست سفارشات</li>
        </ul>
    </div>
    <div class="separator-breadcrumb border-top"></div>
    <div class="row mb-4">
        <div class="col-md-12 mb-4">
            <div class="card text-left">
                <div class="card-body">
                    <div class="table-responsive">
                        <table id="shop_datatable"
                               class="display table table-striped table-borderless border yajra-datatable"
                               style="width:100%">
                            <thead>
                            <tr>
                                <th>شماره سفارش</th>
                                <th>کاربر درخواست دهنده</th>
                                <th>پیج سفارش شده</th>
                                <th>پست سفارش شده</th>
                                <th>تعداد درخواستی</th>
                                <th>تعداد دریافتی</th>
                                <th>وضعیت</th>
                                <th>نوع سفارش</th>
                                <th>تاریخ سفارش</th>
                                <th>تنظیمات</th>
                            </tr>
                            </thead>
                            <tbody dir="ltr">
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
        </div>
        <!-- end of col -->
    </div>
    <!-- end of row -->
@endsection

@section('page-js')
    <script type="text/javascript">
        $(function () {
            var table = $('#shop_datatable').DataTable({
                processing: true,
                serverSide: true,
                ajax: "{{ route('bannerss.list') }}",
                columns: [
                    {data: 'ID', name: 'ID'},
                    {data: 'id_user_req', name: 'id_user_req'},
                    {data: 'id_user', name: 'id_user'},
                    {data: 'id_post', name: 'id_post'},
                    {data: 'darkhasti', name: 'darkhasti'},
                    {data: 'daryafti', name: 'daryafti'},
                    {data: 'status', name: 'status'},
                    {data: 'part', name: 'part'},
                    {data: 'Date', name: 'Date'},
                    {data: 'Options', name: 'Options', orderable: false, searchable: false},
                ]
            });

        });
    </script>
    <script src="{{asset('assets/js/vendor/datatables.min.js')}}"></script>
    {{--    <script src="{{asset('assets/js/datatables.script.js')}}"></script>--}}
@endsection

@section('bottom-js')
    <script src="{{asset('assets/js/vendor/toastr.min.js')}}"></script>
    {!! Brian2694\Toastr\Facades\Toastr::message() !!}

    
@endsection
