fix payment-and-billing vue console error

This commit is contained in:
edmondlang
2024-09-01 19:58:51 +08:00
parent 01d666d92a
commit b7c6c13bde
@@ -26,11 +26,11 @@
</div>
<div class="col" v-if="['customerPaidInvoiceComponent', 'customerPaidGroupInvoiceComponent'].includes(section)">
<p class="no-margin fs-10 all-caps">Payment Date</p>
<div> {{ item.payment_history?.[item.payment_history.length - 1]?.created_at || '-' }}</div>
<div>{{ item.payment_history && item.payment_history.length > 0 ? item.payment_history[item.payment_history.length - 1].created_at : '-' }}</div>
</div>
<div class="col" v-if="['customerPaidInvoiceComponent', 'customerPaidGroupInvoiceComponent'].includes(section)">
<p class="no-margin fs-10 all-caps">Bill Number</p>
<div>{{ item.payment_history?.[item.payment_history.length-1]?.payment_reference || '-' }}</div>
<div>{{ item.payment_history && item.payment_history.length > 0 ? item.payment_history[item.payment_history.length - 1].payment_reference : '-' }}</div>
</div>
<div class="col-auto">
<div v-if="item.documents.length">