import React from 'react'
import { Head, Link } from '@inertiajs/react'
import AuthenticatedLayout from '@/Layouts/AuthenticatedLayout'
import { formatIDR } from '@/utils'
const SaleItem = ({ item, index }) => {
const { voucher } = JSON.parse(item.additional_info_json)
return (
<>
{index + 1}
|
{voucher.location_profile.location.name}
|
{voucher.location_profile.name}
|
{voucher.username}
|
{voucher.comment}
|
{voucher.location_profile.quota}
|
{voucher.location_profile.display_expired}
|
>
)
}
export default function Detail(props) {
const { sale } = props
return (
Customer |
: |
{sale.customer.name}
|
Metode Pembayaran
|
: |
{sale.payment_with} |
Total |
: |
{formatIDR(sale.amount)} |
Voucher
No
|
Lokasi
|
Profile
|
Kode
|
Comment
|
Kuota
|
Masa Aktif
|
{sale.items.map((item, index) => (
))}
)
}