@extends('layouts.master') @section('title') Create Order @endsection @section('css') @endsection @section('content') @if (session('success')) @endif

Manage Cash Order

@csrf
Salesman
Salesman ID
@if($order->refund_receipt)
@endif
# Product Details
Price
QTY Amount (RM)
Estimated Tax (12.5%)
Discount
Shipping Charge
Sub Total
Total Amount
@if($order->status == 3 && $order->sales_type != 9)
Order Cancelled
@endif @if($order->status == 6)
Price Request Rejected
@endif @if($order->status == 9)
Expired
@endif @if($voucherInfo)
Applied Voucher Details
Voucher Code
{{ $voucherInfo['code'] }}
-RM {{ number_format($voucherInfo['discount_amount'], 2) }}
Applied on {{ \Carbon\Carbon::parse($voucherInfo['payment_date'])->format('d M Y, h:i A') }}
@endif @if($order->status != 6 && $order->status != 9)
@if($order->status == 2)
@endif @if($order->status != 1 && $order->status != 9) @endif @if($order->status == 2)
Date Method Approval Code Paid Amount (RM)
Sub total
Paid
Balance
@else @foreach($payments as $payment) @php $paymentDetails = json_decode($payment->payment_details, true) ?? []; $paymentStatus = ''; if($payment->status == 1){ $paymentStatus = "SUCCESS"; }elseif($payment->status == 2){ $paymentStatus = "FAILED"; }else{ $paymentStatus = "PENDING"; } @endphp @if(count($paymentDetails) > 0) @foreach($paymentDetails as $index => $detail) @endforeach @else @endif @if($payment->voucher_amount) @endif @endforeach @if($voucher_amount) @else @endif @if($order->totalAmount < 0) @endif
Date Ref No Status Payment Code Paid Amount (RM)
{{ $payment->document_date }} @if($detail['payment_code'] == 'MEMBER VC') {{ $detail['approval_code'] ?? 'N/A' }} @else {{ $payment->receipt_number }} @endif {!! $paymentStatus !!} @if($detail['payment_code'] == 'MEMBER VC') {{ $detail['payment_code'] }} @else {{ $detail['payment_code'] }} @endif @if($detail['payment_code'] == 'MEMBER VC') {{ number_format($detail['payment_amount'], 2) }} @else {{ number_format($detail['payment_amount'], 2) }} @endif
{{ $payment->document_date }} {{ $payment->receipt_number }} {!! $paymentStatus !!} N/A {{ number_format($payment->total_amount, 2) }}
{{ $payment->document_date }} {{ $payment->receipt_number }} {!! $paymentStatus !!} MEMBER VC {{ number_format($payment->voucher_amount, 2) }}
Paid {{ $sum_payment }}
Balance{{ number_format($balance_payment-$voucher_amount,2) }}{{ $balance_payment }}
Refund {{ $order->totalAmount }}
@endif
@endif {{-- Modal QR --}} {{-- End Modal QR --}}
@if($order->status != 6 && $order->status != 9) @if($order->status == 1) Print @elseif($order->status == 2) @else Print @endif @if (!empty($qrcode)) @endif @endif
@endsection @section('script')