import { FC } from "react" import { Bill } from "@/app/lib/db-types" import { TicketIcon } from "@heroicons/react/24/outline" export interface BillBadgeProps { locationId: string, bill: Pick, onClick?: () => void }; export const BillToggleBadge:FC = ({ bill: { name, paid, hasAttachment, proofOfPayment }, onClick}) => { const className = `badge badge-lg ${paid?"badge-success":" badge-outline"} ${ !paid && hasAttachment ? "btn-outline btn-success" : "" } cursor-pointer`; return (
{name} { proofOfPayment?.uploadedAt ? : null }
); }