diff --git a/frontend/src/views/loans/LoansView.vue b/frontend/src/views/loans/LoansView.vue index e21ce33..e10d982 100644 --- a/frontend/src/views/loans/LoansView.vue +++ b/frontend/src/views/loans/LoansView.vue @@ -287,8 +287,9 @@ const loanAccounts = computed(() => const filteredSchedule = computed(() => { if (!loanDetail.value) return [] if (showPastPayments.value) return loanDetail.value.amortizationSchedule - const today = new Date().toISOString().split('T')[0] - return loanDetail.value.amortizationSchedule.filter(e => e.paymentDate.split('T')[0] >= today) + const now = new Date() + const monthStart = `${now.getFullYear()}-${String(now.getMonth() + 1).padStart(2, '0')}-01` + return loanDetail.value.amortizationSchedule.filter(e => e.paymentDate.split('T')[0] >= monthStart) }) const payoffAmount = computed(() => {