import type { Prisma } from '@prisma/client';

/** Payments waiting on the office to approve or refuse: every pending receipt
 *  and deposit receipt except the overpaid part of a payment, which is approved
 *  and refused with its receipt and so is never a decision of its own. One
 *  definition for the approvals inbox and the sidebar counts, so they agree. */
export function awaitingReview(organizationId: string | undefined): Prisma.ReceiptWhereInput {
  return { organizationId, status: 'PENDING', sourceReceiptId: null };
}
