@extends('adminlte::page')
@section('content')
Customer | Location | Products | Quantity | Harga | Order Date | Status |
---|---|---|---|---|---|---|
{{ $kunjungan->namaCustomer }} | {{ $kunjungan->lokasi }} |
@foreach ($kunjungan->orderDetails as $orderDetail)
{{ $orderDetail->produk }}
@endforeach
|
@foreach ($kunjungan->orderDetails as $orderDetail)
{{ number_format($orderDetail->harga, 0, '.', '') }}
@endforeach
|
@foreach ($kunjungan->orderDetails as $orderDetail)
{{ $orderDetail->quantity }}
@endforeach
|
{{ $kunjungan->created_at }} | @php $status = 'Belum Selesai'; foreach ($kunjungan->orderDetails as $orderDetail) { if ($orderDetail->done) { $status = 'Selesai'; break; } elseif ($orderDetail->retur) { $status = 'Retur'; break; } elseif ($orderDetail->cancel) { $status = 'Order dicancel'; break; } } @endphp {{ $status }} |