@extends('layouts.admin')
@section('content')
<!-- begin:: Content -->
<div class="kt-container kt-container--fluid kt-grid__item kt-grid__item--fluid" style="margin-top:30px">
<!--begin::Portlet-->
<div class="kt-portlet">
<div class="kt-portlet__head">
<div class="kt-portlet__head-label">
<h3 class="kt-portlet__head-title">
Pending Orders
</h3>
</div>
</div>
<div class="kt-portlet__body">
<!--begin::Section-->
<div class="kt-section">
<div class="kt-section__content">
@include('includes.admin.flash-message')
<table class="table table-striped- table-bordered table-hover table-checkable dataTable no-footer dtr-inline" id="orders_table">
<thead>
<tr>
<th>#</th>
<th>Order Number</th>
<th>Name</th>
<th>Date</th>
<th>Billing</th>
<th>Total Amount</th>
<th>Status</th>
<th>Action</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
</div>
<!--end::Section-->
</div>
</div>
<!--end::Portlet-->
</div>
<!-- end:: Content -->
@endsection
@section('scripts')
<script>
// begin first table
$(function () {
var table = $('#orders_table').DataTable({
responsive: true,
processing: true,
serverSide: true,
ajax: "{{ route('admin.ordersdata', 'pending') }}",
columns: [
{data: 'DT_RowIndex', name: 'DT_RowIndex'},
{data: 'order_number', name: 'order_number'},
{data: 'customer_name', name: 'customer_name'},
{data: 'created_at', name: 'created_at'},
{data: 'billing', name: 'email'},
{data: 'total_amount', name: 'total_amount'},
{data: 'status', name: 'status'},
{data: 'action', name: 'action', orderable: false, searchable: false},
]
});
});
</script>
@endsection |