From d80f338e86cc9f0312a486fd873a2dcdba645a21 Mon Sep 17 00:00:00 2001 From: tdgao Date: Thu, 1 Jan 2026 14:36:09 -0800 Subject: [PATCH 1/4] convert string to num --- apps/frontend/src/pages/dashboard/revenue/index.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/frontend/src/pages/dashboard/revenue/index.vue b/apps/frontend/src/pages/dashboard/revenue/index.vue index 64c2923825..df726ffe17 100644 --- a/apps/frontend/src/pages/dashboard/revenue/index.vue +++ b/apps/frontend/src/pages/dashboard/revenue/index.vue @@ -439,9 +439,9 @@ const processingDate = computed<{ date: string; amount: number }>(() => { return { date: '', amount: 0 } }) -const grandTotal = computed(() => - userBalance.value ? userBalance.value.available + userBalance.value.pending : 0, -) +const grandTotal = computed(() => { + return userBalance.value ? Number(userBalance.value.available) + Number(userBalance.value.pending) : 0 +}) const hasTinMismatch = computed(() => { const bal = userBalance.value From 58e33c53e519fc69df98f4eb2e35b0cc11842d35 Mon Sep 17 00:00:00 2001 From: tdgao Date: Thu, 1 Jan 2026 14:46:42 -0800 Subject: [PATCH 2/4] another potentional string addition --- apps/frontend/src/pages/dashboard/revenue/index.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/frontend/src/pages/dashboard/revenue/index.vue b/apps/frontend/src/pages/dashboard/revenue/index.vue index df726ffe17..f565bebef0 100644 --- a/apps/frontend/src/pages/dashboard/revenue/index.vue +++ b/apps/frontend/src/pages/dashboard/revenue/index.vue @@ -508,7 +508,7 @@ const segments = computed(() => { const upcoming = processing.date ? dates.filter((d) => d.date !== processing.date) : dates const totalPending = userBalance.value?.pending ?? 0 - const total = available + totalPending + const total = Number(available) + Number(totalPending) if (total <= 0) return [] as RevenueBarSegment[] From 998043a8f14d2dcef1b20dc9c5f52e8b9d568baf Mon Sep 17 00:00:00 2001 From: tdgao Date: Thu, 1 Jan 2026 14:48:17 -0800 Subject: [PATCH 3/4] remove return statement --- apps/frontend/src/pages/dashboard/revenue/index.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/frontend/src/pages/dashboard/revenue/index.vue b/apps/frontend/src/pages/dashboard/revenue/index.vue index f565bebef0..e4ee5f8071 100644 --- a/apps/frontend/src/pages/dashboard/revenue/index.vue +++ b/apps/frontend/src/pages/dashboard/revenue/index.vue @@ -439,9 +439,9 @@ const processingDate = computed<{ date: string; amount: number }>(() => { return { date: '', amount: 0 } }) -const grandTotal = computed(() => { - return userBalance.value ? Number(userBalance.value.available) + Number(userBalance.value.pending) : 0 -}) +const grandTotal = computed(() => + userBalance.value ? Number(userBalance.value.available) + Number(userBalance.value.pending) : 0 +) const hasTinMismatch = computed(() => { const bal = userBalance.value From a9e35418a6c30b6e269d59de27cc32cbf5d1f889 Mon Sep 17 00:00:00 2001 From: tdgao Date: Thu, 1 Jan 2026 14:52:48 -0800 Subject: [PATCH 4/4] fix formatting --- apps/frontend/src/pages/dashboard/revenue/index.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/frontend/src/pages/dashboard/revenue/index.vue b/apps/frontend/src/pages/dashboard/revenue/index.vue index e4ee5f8071..f3ec3ab4e0 100644 --- a/apps/frontend/src/pages/dashboard/revenue/index.vue +++ b/apps/frontend/src/pages/dashboard/revenue/index.vue @@ -440,7 +440,7 @@ const processingDate = computed<{ date: string; amount: number }>(() => { }) const grandTotal = computed(() => - userBalance.value ? Number(userBalance.value.available) + Number(userBalance.value.pending) : 0 + userBalance.value ? Number(userBalance.value.available) + Number(userBalance.value.pending) : 0, ) const hasTinMismatch = computed(() => {