| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990 |
- @php
- $m = $brand->malay;
- $label = 'font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: '.$brand->color('muted').';';
- $line = 'border-bottom: 1px solid '.$brand->color('border').';';
- $address = $order->shipping_address;
- @endphp
- <x-mail.store :brand="$brand" :preheader="$m ? 'Bayaran diterima. Pesanan #'.$order->number.', '.$brand->money($order->total).'.' : 'Payment received. Order #'.$order->number.', '.$brand->money($order->total).'.'">
- <h1 style="margin: 0 0 16px; font-family: {{ $brand->headingFont }}; font-size: 26px; line-height: 1.25; font-weight: 700; color: {{ $brand->color('foreground') }};">
- {{ $m ? 'Terima kasih atas pesanan anda' : 'Thank you for your order' }}
- </h1>
- <p style="margin: 0 0 12px;">{{ $m ? 'Hai' : 'Hi' }} {{ $order->customer_name }},</p>
- <p style="margin: 0 0 24px;">
- {{ $m
- ? "Kami telah menerima bayaran anda. Ini ringkasan pesanan #{$order->number} daripada ".rtrim($store->name, '.')."."
- : "We have received your payment. Here is a summary of order #{$order->number} from ".rtrim($store->name, '.')."." }}
- </p>
-
- {{-- Order number and date --}}
- <table role="presentation" width="100%" cellpadding="0" cellspacing="0" border="0" style="margin: 0 0 24px;">
- <tr>
- <td style="{{ $label }} padding-bottom: 4px;">{{ $m ? 'Pesanan' : 'Order' }}</td>
- <td align="right" style="{{ $label }} padding-bottom: 4px;">{{ $m ? 'Dibayar pada' : 'Paid on' }}</td>
- </tr>
- <tr>
- <td style="font-weight: 600;">#{{ $order->number }}</td>
- <td align="right" style="font-weight: 600;">{{ ($order->paid_at ?? now())->timezone('Asia/Kuala_Lumpur')->locale($m ? 'ms' : 'en')->translatedFormat('j F Y') }}</td>
- </tr>
- </table>
-
- {{-- What was bought --}}
- <table role="presentation" width="100%" cellpadding="0" cellspacing="0" border="0" style="border-top: 1px solid {{ $brand->color('border') }};">
- @foreach ($order->items as $item)
- <tr>
- <td style="{{ $line }} padding: 12px 12px 12px 0; vertical-align: top;">
- <div style="font-weight: 600;">{{ $item->name }}</div>
- <div style="font-size: 13px; color: {{ $brand->color('muted') }};">{{ $item->quantity }} × {{ $brand->money($item->unit_price) }}</div>
- </td>
- <td align="right" style="{{ $line }} padding: 12px 0; vertical-align: top; white-space: nowrap;">{{ $brand->money($item->line_total) }}</td>
- </tr>
- @endforeach
- </table>
-
- {{-- Totals --}}
- <table role="presentation" width="100%" cellpadding="0" cellspacing="0" border="0" style="margin: 0 0 28px;">
- <tr>
- <td style="padding: 12px 0 4px; color: {{ $brand->color('muted') }};">{{ $m ? 'Jumlah kecil' : 'Subtotal' }}</td>
- <td align="right" style="padding: 12px 0 4px;">{{ $brand->money($order->subtotal) }}</td>
- </tr>
- @if ($order->discount_total > 0)
- <tr>
- <td style="padding: 4px 0; color: {{ $brand->color('muted') }};">
- {{ $m ? 'Diskaun' : 'Discount' }}@if ($order->discount_code ?? $order->discount_name) ({{ $order->discount_code ?? $order->discount_name }})@endif
- </td>
- <td align="right" style="padding: 4px 0;">-{{ $brand->money($order->discount_total) }}</td>
- </tr>
- @endif
- <tr>
- <td style="padding: 4px 0 12px; color: {{ $brand->color('muted') }}; {{ $line }}">{{ $m ? 'Penghantaran' : 'Shipping' }}</td>
- <td align="right" style="padding: 4px 0 12px; {{ $line }}">{{ $order->shipping_total === 0 ? ($m ? 'Percuma' : 'Free') : $brand->money($order->shipping_total) }}</td>
- </tr>
- <tr>
- <td style="padding: 14px 0 0; font-family: {{ $brand->headingFont }}; font-size: 17px; font-weight: 700;">{{ $m ? 'Jumlah dibayar' : 'Total paid' }}</td>
- <td align="right" style="padding: 14px 0 0; font-family: {{ $brand->headingFont }}; font-size: 17px; font-weight: 700; white-space: nowrap;">{{ $brand->money($order->total) }}</td>
- </tr>
- </table>
-
- {{-- Where it goes --}}
- <div style="{{ $label }} margin: 0 0 6px;">{{ $m ? 'Alamat penghantaran' : 'Delivery address' }}</div>
- <p style="margin: 0 0 28px;">
- {{ $order->customer_name }}<br>
- {{ $address['line1'] }}@if ($address['line2'] ?? null), {{ $address['line2'] }}@endif<br>
- {{ $address['postcode'] }} {{ $address['city'] }}, {{ $address['state'] }}
- </p>
-
- {{-- Buttons --}}
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin: 0 0 28px;">
- <tr>
- <td class="sf-cell"><x-mail.store-button :brand="$brand" :href="$orderUrl">{{ $m ? 'Lihat pesanan anda' : 'View your order' }}</x-mail.store-button></td>
- @if ($whatsappUrl)
- <td class="sf-gap" style="width: 10px;"></td>
- <td class="sf-cell"><x-mail.store-button :brand="$brand" :href="$whatsappUrl" outline>{{ $m ? 'Tanya di WhatsApp' : 'Ask on WhatsApp' }}</x-mail.store-button></td>
- @endif
- </tr>
- </table>
-
- <p style="margin: 0 0 20px; color: {{ $brand->color('muted') }};">
- {{ $m ? 'Kami akan e-mel anda lagi apabila pesanan anda dihantar.' : 'We will email you again when your order is on its way.' }}
- </p>
- <p style="margin: 0;">{{ $m ? 'Terima kasih,' : 'Thanks,' }}<br><strong>{{ $store->name }}</strong></p>
- </x-mail.store>
|