From a0d47864d872d7418c4565820986b1e1e69616c7 Mon Sep 17 00:00:00 2001 From: yovinchen Date: Thu, 5 Dec 2024 11:43:44 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E5=88=86=E7=B1=BB?= =?UTF-8?q?=E8=A7=86=E5=9B=BE=E5=B1=95=E7=A4=BA=E9=80=BB=E8=BE=91=E9=94=99?= =?UTF-8?q?=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../yovinchen/bookkeeping/ui/screen/CategoryDetailScreen.kt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/com/yovinchen/bookkeeping/ui/screen/CategoryDetailScreen.kt b/app/src/main/java/com/yovinchen/bookkeeping/ui/screen/CategoryDetailScreen.kt index 2f6f2be..78b12ab 100644 --- a/app/src/main/java/com/yovinchen/bookkeeping/ui/screen/CategoryDetailScreen.kt +++ b/app/src/main/java/com/yovinchen/bookkeeping/ui/screen/CategoryDetailScreen.kt @@ -132,7 +132,11 @@ fun CategoryDetailScreen( modifier = Modifier .fillMaxWidth() .height(200.dp), - onCategoryClick = { memberName -> onNavigateToMemberDetail(memberName) } + onCategoryClick = { memberName -> + if (records.isNotEmpty() && records.first().type == TransactionType.EXPENSE) { + onNavigateToMemberDetail(memberName) + } + } ) } }