@extends('layouts.master') @section('page_title', 'Call Status Details') @section('title', 'Call Status Details') @section('main_item', 'Oder') @section('sub_item', 'Call Status Details') @section('content')

Filter

business_location != '1') style="display: none" @endif>
order_batch_enable != '1') style="display: none" @endif>
product_filter_enable != '1') style="display: none" @endif>
Reset
{{--
Download Excel
--}}
{{-- --}} @foreach ($sales as $sale) {{-- --}} @endforeach
Action Call Status Order ID Waybill No Resources Orders CountBusiness LocationCustomer Mobile No Address City Invoice Total Product Name Product Sku Last Status Remark Next Call Date Call Attempt Sale Date Updated
{{ ucfirst(str_replace('_', ' ', $sale->call_status)) }} @if ($sale->call_status != 'cancel') @endif {{ $sale->invoice_no ?? $sale->ref_no ?? 'N/A' }} {{ $sale->waybill_no ? $sale->waybill_prefix . $sale->waybill_no . $sale->waybill_postfix : 'N/A' }} @php $resource_badges = [ 'whats_app' => ['color' => 'warning'], 'face_book_leeds' => ['color' => 'success'], 'face_book_massenger' => ['color' => 'secondary'], 'bulk_order' => ['color' => 'danger'], 'daraz' => ['color' => 'primary'], 'follow_up' => ['color' => 'primary', 'bg' => '#996633'], 'tamil_order' => ['color' => 'primary', 'bg' => '#6600ff'], 'missed_call' => ['color' => 'primary', 'bg' => '#cc9900'], 'call_order' => ['color' => '', 'bg' => '#897004', 'text' => 'white'], 'voucher' => ['color' => 'primary', 'bg' => '#16a085'], 'flagship_store' => ['color' => 'primary', 'bg' => '#1e3799'], 'meta' => ['color' => 'primary', 'bg' => '#0e6655'], 'online' => ['color' => 'primary', 'bg' => '#922b21'], 'tiktok_order' => ['color' => 'primary', 'bg' => '#fcbe8f'] ]; $resource = $sale->resources ?? 'N/A'; $badge = $resource_badges[$resource] ?? ['color' => 'info']; $bgColor = $badge['bg'] ?? ''; $textColor = $badge['text'] ?? 'white'; @endphp {{ ucfirst(str_replace('_', ' ', $resource)) }} @if ($sale->call_status != 'cancel') @endif {{ $sale->customerOrdersCount() }} {{ $sale->business_locations->name ?? 'N/A' }} {{ $sale->customer->name }} {{ $sale->customer->mobile }}
{{ $sale->customer->mobile_2 }}
{{ $sale->customer->landmark }} {{ $sale->getCustomerCityName() ?? 'N/A' }} {{ number_format($sale->invoice_nettotal, 2) }} {{ $sale->saleItems->pluck('product.product_name')->implode(', ') }} {{ $sale->saleItems->pluck('product.sku')->implode(', ') }} {{ $sale->callStatuses->last()->call_status_reason ?? 'N/A' }} {{ $sale->callStatuses->first()->remark ?? 'N/A' }} {{ optional($sale->callStatuses->first())->next_call_date ? \Carbon\Carbon::parse($sale->callStatuses->first()->next_call_date)->format('Y-m-d') : 'N/A' }} {{ $sale->callStatuses->count() }} {{ Carbon\Carbon::parse($sale->sale_date)->toDateString() }} {{ Carbon\Carbon::parse($sale->updated_at)->toDateString() }}
Total
{{ $sales->appends($_GET)->links() }}
@php $count = $sales->count(); @endphp
Total Count   {{ $count }}
@endsection @section('scripts') @endsection