import React, { useEffect, Suspense } from 'react' import { isEmpty } from 'lodash' import AuthenticatedLayout from '@/Layouts/AuthenticatedLayout' import FormInput from '@/Components/FormInput' import Button from '@/Components/Button' import { Head, useForm } from '@inertiajs/react' import FormFile from '@/Components/FormFile' import { formatIDR } from '@/utils' const SaleItem = ({ item, index }) => { const { voucher } = JSON.parse(item.additional_info_json) console.log(voucher) 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.payed_with}
Total : {formatIDR(sale.amount)}
Voucher
{sale.items.map((item, index) => ( ))}
No Lokasi Profile Kode Comment Kuota Masa Aktif
) }