@extends('layouts.main') @section('content')
| Order ID: | #{{ $order->id }} |
|---|---|
| Reference ID: | {{ $order->order_id }} |
| Transaction ID: | {{ $order->transaction_id ?? '-' }} |
| Subtotal: | Rp {{ number_format($order->subtotal ?? $order->total_amount, 0, ',', '.') }} |
| Diskon: |
- Rp {{ number_format($order->promo_discount_amount, 0, ',', '.') }}
@if($order->promo_code)
{{ $order->promo_code }} @if($order->promo_discount_type) Tipe: {{ ucfirst($order->promo_discount_type) }} @if($order->promo_discount_value) ({{ $order->promo_discount_type == 'percentage' ? $order->promo_discount_value . '%' : 'Rp ' . number_format($order->promo_discount_value, 0, ',', '.') }}) @endif @endif @endif |
| Ongkir: | @if($order->shipping_cost > 0) + Rp {{ number_format($order->shipping_cost, 0, ',', '.') }} @else GRATIS @endif |
| Total Akhir: | Rp {{ number_format($order->grand_total ?? $order->total_amount, 0, ',', '.') }} |
| Status: | @if($order->status == 'paid') Lunas @elseif($order->status == 'pending') Pending @elseif($order->status == 'failed') Gagal @elseif($order->status == 'expired') Expired @else {{ ucfirst($order->status) }} @endif |
| Status Order: | @if($order->status_order == 'completed') Selesai @elseif($order->status_order == 'delivered') Terkirim @elseif($order->status_order == 'delivering') Dalam Pengiriman @elseif($order->status_order == 'waiting_pickup') Menunggu Pickup @else {{ ucfirst(str_replace('_', ' ', $order->status_order)) }} @endif |
| Payment Method: | {{ strtoupper($order->payment_method ?? 'N/A') }} |
|---|---|
| Paid At: | {{ $order->paid_at ? $order->paid_at->format('d/m/Y H:i:s') : '-' }} |
| Created At: | {{ $order->created_at->format('d/m/Y H:i:s') }} |
| Updated At: | {{ $order->updated_at->format('d/m/Y H:i:s') }} |
| Kurir: |
{{ $courier->name }}
{{ $courier->email }} |
| Produk | Variant | Quantity | Harga Satuan | Total |
|---|---|---|---|---|
| {{ $item['product_name'] ?? '-' }} | {{ $item['variant_name'] ?? '-' }} | {{ $item['quantity'] ?? 0 }} | Rp {{ number_format($item['unit_price'] ?? 0, 0, ',', '.') }} | Rp {{ number_format($item['total_price'] ?? 0, 0, ',', '.') }} |
| Subtotal Item: | Rp {{ number_format($order->subtotal ?? $order->total_amount, 0, ',', '.') }} | |||
| Diskon @if($order->promo_code)({{ $order->promo_code }})@endif: | - Rp {{ number_format($order->promo_discount_amount, 0, ',', '.') }} | |||
| Ongkir: | @if($order->shipping_cost > 0) + Rp {{ number_format($order->shipping_cost, 0, ',', '.') }} @else GRATIS @endif | |||
| Total Akhir: | Rp {{ number_format($order->grand_total ?? $order->total_amount, 0, ',', '.') }} | |||
| Nama: | {{ ($customerDetails['first_name'] ?? '') . ' ' . ($customerDetails['last_name'] ?? '') }} |
|---|---|
| Email: | {{ $customerDetails['email'] ?? '-' }} |
| Phone: | {{ $customerDetails['phone'] ?? '-' }} |
| Penerima: | {{ $customerDetails['penerima'] ?? '-' }} |
| Alamat: | {{ $customerDetails['detail'] ?? '-' }} |
| Nama Alamat: | {{ $customerDetails['nama_alamat'] ?? '-' }} |
| Koordinat: |
{{ $customerDetails['lat'] ?? '-' }}, {{ $customerDetails['lon'] ?? '-' }}
@if($customerDetails['lat'] && $customerDetails['lon'])
Lihat di Maps @endif |
| User ID: | {{ $order->user->id }} |
|---|---|
| Nama: | {{ $order->user->name }} |
| Email: | {{ $order->user->email }} |
{{ json_encode($midtransData, JSON_PRETTY_PRINT) }}