55 lines
2.2 KiB
PHP
55 lines
2.2 KiB
PHP
@extends('administrator.layout.master')
|
|
@push('plugin-styles')
|
|
@foreach (config('assets.datatable.css') as $datatable)
|
|
<link href="{{ asset($datatable) }}" rel="stylesheet" />
|
|
@endforeach
|
|
@endpush
|
|
|
|
@section('breadcrumb')
|
|
@php
|
|
$breadcrumbItems = [
|
|
['label' => 'Order'],
|
|
['label' => 'Order Management'],
|
|
['label' => 'Order List', 'active' => true],
|
|
];
|
|
@endphp
|
|
<x-admin-breadcrumb :items="$breadcrumbItems" />
|
|
@endsection
|
|
|
|
@section('content')
|
|
@if(auth()->guard('admins')->user()->can("manager order"))
|
|
<div class="card card-primary card-outline rounded-4 shadow-none">
|
|
<div class="card-header bg-white d-flex justify-content-end gap-2 rounded-top-4">
|
|
<a href="{{ route('administrator.pages.order.create') }}" class="btn btn-primary btn-sm">
|
|
<i class="fas fa-plus"></i> Add New Order
|
|
</a>
|
|
</div>
|
|
<div class="card-body p-0">
|
|
@php
|
|
$orderColumns = [
|
|
['key' => 'order_num', 'label' => 'Order #'],
|
|
['key' => 'date', 'label' => 'Date'],
|
|
['key' => 'customer', 'label' => 'Client Name'],
|
|
['key' => 'payment', 'label' => 'Payment Method'],
|
|
['key' => 'amount', 'label' => 'Total'],
|
|
['key' => 'invoice_status', 'label' => 'Payment Status'],
|
|
['key' => 'status', 'label' => 'Status'],
|
|
['key' => 'action', 'label' => 'Action'],
|
|
];
|
|
@endphp
|
|
<x-datatable id="orderTable" ajax="{{ route('administrator.pages.order.datatable') }}" :columns="$orderColumns" />
|
|
</div>
|
|
</div>
|
|
@else
|
|
<div class="alert alert-danger alert-dismissible">
|
|
<h5 class="mb-0"><i class="icon fas fa-ban"></i> Access Denied - You are not assigned to any Order
|
|
management department</h5>
|
|
</div>
|
|
@endif
|
|
@endsection
|
|
@push('plugin-scripts')
|
|
@foreach (config('assets.datatable.js') as $datatable)
|
|
<script src="{{ asset($datatable) }}"></script>
|
|
@endforeach
|
|
@endpush
|