(refactor) dbTypes: added utilBillsProofOfPaymentUploadedAt to BillingLocation

This commit is contained in:
Knee Cola
2025-11-23 22:13:09 +01:00
parent 7a01dad5e7
commit fcecaaa901
4 changed files with 28 additions and 17 deletions

View File

@@ -23,7 +23,7 @@ export const LocationCard: FC<LocationCardProps> = ({ location, currency }) => {
bills,
seenByTenant,
// NOTE: only the fileName is projected from the DB to reduce data transfer
utilBillsProofOfPaymentAttachment
utilBillsProofOfPaymentUploadedAt
} = location;
const t = useTranslations("home-page.location-card");
@@ -58,7 +58,7 @@ export const LocationCard: FC<LocationCardProps> = ({ location, currency }) => {
</div>
{monthlyExpense > 0 || seenByTenant || utilBillsProofOfPaymentAttachment ?
{monthlyExpense > 0 || seenByTenant || utilBillsProofOfPaymentUploadedAt ?
<fieldset className="card card-compact card-bordered border-1 border-neutral p-3 mt-2 mr-[3.5rem]">
<legend className="fieldset-legend px-2 text-sm font-semibold uppercase">{t("monthly-statement-legend")}</legend>
@@ -78,7 +78,7 @@ export const LocationCard: FC<LocationCardProps> = ({ location, currency }) => {
<CheckCircleIcon className="h-5 w-5 text-success" />
</div>
)}
{utilBillsProofOfPaymentAttachment && (
{utilBillsProofOfPaymentUploadedAt && (
<Link
href={`/share/proof-of-payment/${_id}/`}
target="_blank"