From dde2eeddbaf07246da7c2c352e7d49ec63fddcd2 Mon Sep 17 00:00:00 2001
From: tj <1378534974@qq.com>
Date: 星期五, 28 三月 2025 14:56:29 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 app/src/main/res/layout/fragment_home.xml |  133 ++++++++++---------------------------------
 1 files changed, 32 insertions(+), 101 deletions(-)

diff --git a/app/src/main/res/layout/fragment_home.xml b/app/src/main/res/layout/fragment_home.xml
index 5df2603..18a5e11 100644
--- a/app/src/main/res/layout/fragment_home.xml
+++ b/app/src/main/res/layout/fragment_home.xml
@@ -1,8 +1,15 @@
 <?xml version="1.0" encoding="utf-8"?>
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
+<FrameLayout
+    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="match_parent">
+
+<ScrollView
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:layout_marginTop="40dp"> <!-- 留出顶部广告位的高度 -->
+    >
 
 <!--    LinearLayout的作用是按照垂直或者水平方向排列其子视图-->
 <!--    CardView组件是用于实现卡片式布局-->
@@ -15,19 +22,7 @@
         android:layout_height="wrap_content"
         android:orientation="vertical">
 
-        <!-- 顶部广告位 -->
-        <androidx.cardview.widget.CardView
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            app:cardCornerRadius="8dp"
-            app:cardElevation="2dp">
-            
-            <ImageView
-                android:id="@+id/adBanner"
-                android:layout_width="match_parent"
-                android:layout_height="80dp"
-                android:scaleType="centerCrop"/>
-        </androidx.cardview.widget.CardView>
+
 
         <!-- 快递/财务切换区域 -->
         <LinearLayout
@@ -74,97 +69,17 @@
             android:layout_height="wrap_content"
             android:layout_margin="16dp">
 
-            <!-- 快递内容 -->
-            <androidx.cardview.widget.CardView
-                android:id="@+id/expressContent"
+            <androidx.recyclerview.widget.RecyclerView
+                android:id="@+id/express_recycler"
                 android:layout_width="match_parent"
                 android:layout_height="wrap_content"
-                app:cardBackgroundColor="@color/light_blue_50"
-                app:cardCornerRadius="8dp"
-                app:cardElevation="0dp">
+                android:padding="8dp"/>
 
-                <androidx.recyclerview.widget.RecyclerView
-                    android:id="@+id/express_recycler"
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:padding="8dp"/>
-
-            </androidx.cardview.widget.CardView>
-
-            <!-- 财务内容 -->
-            <androidx.cardview.widget.CardView
-                android:id="@+id/financeContent"
+            <androidx.recyclerview.widget.RecyclerView
+                android:id="@+id/finance_recycler"
                 android:layout_width="match_parent"
                 android:layout_height="wrap_content"
-                app:cardBackgroundColor="@color/light_blue_50"
-                app:cardCornerRadius="8dp"
-                app:cardElevation="0dp">
-
-                <androidx.recyclerview.widget.RecyclerView
-                    android:id="@+id/finance_recycler"
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:padding="8dp"/>
-
-                <LinearLayout
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:orientation="vertical"
-                    android:padding="16dp">
-
-                    <!-- 花呗还款 -->
-                    <TextView
-                        android:layout_width="match_parent"
-                        android:layout_height="wrap_content"
-                        android:text="花呗"
-                        android:textSize="16sp"
-                        android:textStyle="bold"
-                        android:layout_marginBottom="8dp"/>
-
-                    <TextView
-                        android:id="@+id/huabeiAmount"
-                        android:layout_width="match_parent"
-                        android:layout_height="wrap_content"
-                        android:text="230,721 元"
-                        android:textSize="24sp"
-                        android:textColor="#FF5722"
-                        android:layout_marginBottom="4dp"/>
-
-                    <TextView
-                        android:id="@+id/huabeiDueDate"
-                        android:layout_width="match_parent"
-                        android:layout_height="wrap_content"
-                        android:text="提醒您2025.01.14 还款"
-                        android:textSize="14sp"
-                        android:layout_marginBottom="16dp"/>
-
-                    <!-- 信用卡还款 -->
-                    <TextView
-                        android:layout_width="match_parent"
-                        android:layout_height="wrap_content"
-                        android:text="中国银行信用卡"
-                        android:textSize="16sp"
-                        android:textStyle="bold"
-                        android:layout_marginBottom="8dp"/>
-
-                    <TextView
-                        android:id="@+id/creditCardAmount"
-                        android:layout_width="match_parent"
-                        android:layout_height="wrap_content"
-                        android:text="310,621 元"
-                        android:textSize="24sp"
-                        android:textColor="#FF5722"
-                        android:layout_marginBottom="4dp"/>
-
-                    <TextView
-                        android:id="@+id/creditCardDueDate"
-                        android:layout_width="match_parent"
-                        android:layout_height="wrap_content"
-                        android:text="提醒您2025.02.10 还款"
-                        android:textSize="14sp"/>
-
-                </LinearLayout>
-            </androidx.cardview.widget.CardView>
+                android:padding="8dp"/>
 
         </FrameLayout>
 
@@ -183,4 +98,20 @@
         </androidx.cardview.widget.CardView>
 
     </LinearLayout>
-</ScrollView>
\ No newline at end of file
+</ScrollView>
+
+    <!-- 顶部广告位 -->
+    <androidx.cardview.widget.CardView
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+       >
+
+        <ImageView
+            android:id="@+id/adBanner"
+            android:layout_width="match_parent"
+            android:layout_height="40dp"
+            android:scaleType="centerCrop"
+            android:src="@drawable/up"/>
+    </androidx.cardview.widget.CardView>
+
+</FrameLayout>

--
Gitblit v1.9.3