From 793d4ee43f963935919f2ebf4b743e924c169e33 Mon Sep 17 00:00:00 2001 From: zuojincheng <lf_zuo@163.com> Date: 星期一, 31 三月 2025 09:59:20 +0800 Subject: [PATCH] feat(search): 新增用户搜索功能并优化用户体验 --- generallibrary/src/main/res/layout/item_user_list.xml | 88 +++++++++++++++++++++++++++++++++++++++---- 1 files changed, 79 insertions(+), 9 deletions(-) diff --git a/generallibrary/src/main/res/layout/item_user_list.xml b/generallibrary/src/main/res/layout/item_user_list.xml index e93821a..f2e4eab 100644 --- a/generallibrary/src/main/res/layout/item_user_list.xml +++ b/generallibrary/src/main/res/layout/item_user_list.xml @@ -1,13 +1,83 @@ <?xml version="1.0" encoding="utf-8"?> -<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" +<androidx.cardview.widget.CardView + xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="wrap_content" - android:orientation="vertical" - android:padding="12dp"> + android:layout_marginBottom="8dp" + app:cardCornerRadius="8dp" + app:cardElevation="2dp"> - <TextView android:id="@+id/tvCardCount" android:layout_width="match_parent" android:layout_height="wrap_content" /> - <TextView android:id="@+id/tvFarmerId" android:layout_width="match_parent" android:layout_height="wrap_content" /> - <TextView android:id="@+id/tvIdCard" android:layout_width="match_parent" android:layout_height="wrap_content" /> - <TextView android:id="@+id/tvName" android:layout_width="match_parent" android:layout_height="wrap_content" /> - <TextView android:id="@+id/tvPhone" android:layout_width="match_parent" android:layout_height="wrap_content" /> -</LinearLayout> \ No newline at end of file + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical" + android:padding="16dp"> + + <TextView + android:id="@+id/tvName" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:textSize="18sp" + android:textStyle="bold" + android:textColor="#333333" + android:layout_marginBottom="8dp"/> + + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="horizontal"> + + <TextView + android:id="@+id/tvFarmerId" + android:layout_width="0dp" + android:layout_weight="1" + android:layout_height="wrap_content" + android:textSize="14sp" + android:textColor="#666666" + android:layout_marginBottom="4dp"/> + + <TextView + android:id="@+id/tvCardCount" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textSize="14sp" + android:textColor="#4CAF50" + android:layout_marginBottom="4dp"/> + </LinearLayout> + + <TextView + android:id="@+id/tvIdCard" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:textSize="14sp" + android:textColor="#666666" + android:layout_marginBottom="4dp"/> + + <TextView + android:id="@+id/tvPhone" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:textSize="14sp" + android:textColor="#666666" + android:layout_marginBottom="4dp"/> + + <TextView + android:id="@+id/tvAddress" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:textSize="14sp" + android:textColor="#666666" + android:layout_marginBottom="4dp" + android:visibility="gone"/> + + <TextView + android:id="@+id/tvOperateDate" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:textSize="12sp" + android:textColor="#999999" + android:layout_marginTop="4dp" + android:visibility="gone"/> + </LinearLayout> +</androidx.cardview.widget.CardView> \ No newline at end of file -- Gitblit v1.8.0