From fe04012057d024770e0180543483d393281a542f Mon Sep 17 00:00:00 2001 From: zhujie <leon.zhu@cloudroam.com.cn> Date: 星期四, 03 四月 2025 09:18:16 +0800 Subject: [PATCH] Merge branch 'master' of http://47.96.225.205:8888/r/FirstApp2 --- app/src/main/res/layout/activity_vip.xml | 518 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 518 insertions(+), 0 deletions(-) diff --git a/app/src/main/res/layout/activity_vip.xml b/app/src/main/res/layout/activity_vip.xml new file mode 100644 index 0000000..2d46ec5 --- /dev/null +++ b/app/src/main/res/layout/activity_vip.xml @@ -0,0 +1,518 @@ +<?xml version="1.0" encoding="utf-8"?> +<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + xmlns:tools="http://schemas.android.com/tools" + android:layout_width="match_parent" + android:layout_height="match_parent" + tools:context=".activity.VipActivity"> + <androidx.core.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + xmlns:tools="http://schemas.android.com/tools" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:fillViewport="true" + tools:context=".activity.VipActivity"> + + <androidx.coordinatorlayout.widget.CoordinatorLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:fitsSystemWindows="true" + android:background="@drawable/member_background"> + + <!-- 这里是原来CoordinatorLayout中的内容,保持不变 --> + + <com.google.android.material.appbar.AppBarLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:fitsSystemWindows="true" + android:background="@android:color/transparent"> + + <com.google.android.material.appbar.MaterialToolbar + android:id="@+id/toolbar" + android:layout_width="match_parent" + android:layout_height="?attr/actionBarSize"> + <!-- 直接在Toolbar中添加TextView --> + <ImageView + android:id="@+id/ivBack" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_gravity="left" + android:layout_marginStart="16dp" + android:src="@drawable/ic_back" /> + <TextView + android:id="@+id/tvTitle" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="智信会员" + android:textColor="#FFFFFF" + android:textSize="18sp" + android:layout_gravity="left" + android:layout_marginEnd="16dp" /> + </com.google.android.material.appbar.MaterialToolbar> + + </com.google.android.material.appbar.AppBarLayout> + <!-- 引入MemberInfoCardFragment --> + <fragment + android:name="com.example.firstapp.ui.vip.MemberInfoCardFragment" + android:id="@+id/memberInfoCardFragment" + android:layout_width="match_parent" + android:layout_height="wrap_content" + app:layout_behavior="@string/appbar_scrolling_view_behavior" /> + + <!-- 滑动框 --> + <androidx.recyclerview.widget.RecyclerView + android:id="@+id/recycler_view" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginTop="165dp" + android:layout_marginLeft="15dp" + app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" + app:layout_constraintTop_toTopOf="parent" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintEnd_toEndOf="parent" + android:background="@android:color/transparent" /> + + + <!-- 会员权益--动态--> + <androidx.constraintlayout.widget.ConstraintLayout + xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + android:id="@+id/benefit_layout" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginTop="300dp" + android:layout_marginLeft="15dp" + android:layout_marginRight="15dp" + android:padding="0dp" + android:background="@android:color/transparent" + app:cardBackgroundColor="@android:color/transparent" + android:foreground="@drawable/gray_border_shape" + + tools:context=".MainActivity"> + <!-- 标题 --> + <TextView + android:id="@+id/title_text" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="会员权益" + android:textColor="#8A5C37" + android:textSize="20sp" + android:textStyle="bold" + app:layout_constraintTop_toTopOf="parent" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintEnd_toEndOf="parent" + app:layout_constraintHorizontal_bias="0.5" + android:layout_marginTop="5dp" /> + + <!-- 分割线 --> + <View + android:id="@+id/divider" + android:layout_width="0dp" + android:layout_height="1dp" + android:background="#615B7F" + app:layout_constraintTop_toBottomOf="@id/title_text" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintEnd_toEndOf="parent" + android:layout_marginTop="8dp" + android:layout_marginHorizontal="16dp" /> + <androidx.constraintlayout.widget.ConstraintLayout + xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + android:id="@+id/dynamicContainer" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:padding="10dp" + android:layout_marginTop="0dp" + android:background="@android:color/transparent" + app:layout_constraintTop_toBottomOf="@id/divider" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintEnd_toEndOf="parent" + + /> + </androidx.constraintlayout.widget.ConstraintLayout> + + <!-- 更多权益--> + + <LinearLayout + android:id="@+id/more_benefit_layout" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:background="@drawable/more_benefit_shape" + android:layout_marginTop="550dp" + android:layout_marginLeft="13dp" + android:layout_marginRight="13dp" + android:padding="15dp" + android:orientation="vertical" + android:gravity="center"> + + <TextView + android:id="@+id/more_benefit_text" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="更多权益敬请期待" + android:textColor="#D5D4DA" + android:textStyle="italic|bold" + android:textSize="16sp" + android:layout_marginBottom="10dp" + android:gravity="center" + android:layout_gravity="center"/> + + <!-- 第一项 --> + <LinearLayout + android:layout_width="200dp" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:gravity="start" + android:baselineAligned="false" + android:layout_marginBottom="8dp" + android:padding="5dp" + > + + <ImageView + android:layout_width="30dp" + android:layout_height="30dp" + android:src="@mipmap/vip_ai_ass_icon" + android:layout_marginEnd="8dp"/> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="解锁AI语音助手" + android:textColor="#93B7D9" + android:textSize="16sp" + android:gravity="start"/> + </LinearLayout> + <!-- 第二项 --> + <LinearLayout + android:layout_width="200dp" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:gravity="start" + android:baselineAligned="false" + android:layout_marginBottom="8dp" + android:padding="5dp" + > + <ImageView + android:layout_width="30dp" + android:layout_height="30dp" + android:src="@mipmap/vip_bar_sta" + android:layout_marginEnd="8dp" + /> + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="数据智能预测" + android:textColor="#93B7D9" + android:textSize="16sp" + android:gravity="start"/> + </LinearLayout> + + <!-- 第三项 --> + <LinearLayout + android:layout_width="200dp" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:gravity="start" + android:baselineAligned="false" + android:layout_marginBottom="8dp" + android:padding="5dp" + > + + <ImageView + android:layout_width="30dp" + android:layout_height="30dp" + android:src="@mipmap/vip_life_insurance" + android:layout_marginEnd="8dp"/> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="家庭分类共享" + android:textColor="#93B7D9" + android:textSize="16sp" + android:gravity="start"/> + </LinearLayout> + + <LinearLayout + android:layout_width="160dp" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:gravity="start" + android:baselineAligned="false" + android:layout_marginBottom="8dp" + android:padding="5dp" + > + + <ImageView + android:layout_width="25dp" + android:layout_height="25dp" + android:src="@mipmap/vip_more" + android:layout_marginEnd="8dp"/> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="敬请期待......" + android:textColor="#D6D5DB" + android:textSize="16sp" + android:gravity="start"/> + </LinearLayout> + + </LinearLayout> + + <View + android:id="@+id/divider2" + android:layout_width="match_parent" + android:layout_height="1dp" + android:background="#646174" + app:layout_constraintTop_toBottomOf="@id/more_benefit_layout" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintEnd_toEndOf="parent" + android:layout_marginTop="840dp" + android:layout_marginHorizontal="0dp" /> + + + + + <LinearLayout + android:layout_width="wrap_content" + android:layout_height="180dp" + android:layout_marginTop="880dp" + > + + </LinearLayout> + + + </androidx.coordinatorlayout.widget.CoordinatorLayout> + </androidx.core.widget.NestedScrollView> + + <androidx.cardview.widget.CardView + android:id="@+id/card_view_fixed" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_margin="0dp" + android:layout_marginTop="10dp" + android:layout_gravity="bottom" + app:cardCornerRadius="0dp" + app:cardElevation="6dp" + android:background="#030308" + app:cardBackgroundColor="#030308" + android:layout_alignParentBottom="true"> + + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical" + android:padding="10dp" + android:gravity="center_horizontal"> + + <LinearLayout + android:id="@+id/alipay_layout" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:background="@drawable/alipay_shape" + android:layout_marginTop="15dp" + android:layout_marginLeft="15dp" + android:layout_marginRight="15dp" + android:padding="3dp" + android:orientation="vertical" + android:gravity="center"> + + <LinearLayout + android:layout_width="250dp" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:gravity="center" + android:baselineAligned="false" + > + + <ImageView + android:layout_width="30dp" + android:layout_height="30dp" + android:src="@mipmap/vip_alipay" + android:layout_marginEnd="8dp"/> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="确认协议并支付" + android:textColor="#419AE4" + android:textSize="16sp" + android:gravity="start"/> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="¥" + android:textColor="#419AE4" + android:textSize="16sp" + android:layout_marginLeft="10dp" + android:layout_marginRight="5dp" + android:gravity="start"/> + + <TextView + android:id="@+id/alipay_amount" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="30" + android:textColor="#419AE4" + android:textSize="16sp" + android:gravity="start"/> + </LinearLayout> + + </LinearLayout> + + <LinearLayout + android:id="@+id/wechat_layout" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:background="@drawable/wechat_shape" + android:layout_marginTop="15dp" + android:layout_marginLeft="15dp" + android:layout_marginRight="15dp" + android:padding="3dp" + android:orientation="vertical" + android:gravity="center"> + + <LinearLayout + android:layout_width="250dp" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:gravity="center" + android:baselineAligned="false" + > + + <ImageView + android:layout_width="30dp" + android:layout_height="30dp" + android:src="@mipmap/vip_wechat" + android:layout_marginEnd="8dp"/> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="确认协议并支付" + android:textColor="#77E382" + android:textSize="16sp" + android:gravity="start"/> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="¥" + android:textColor="#77E382" + android:textSize="16sp" + android:layout_marginLeft="10dp" + android:layout_marginRight="5dp" + android:gravity="start"/> + + <TextView + android:id="@+id/wechat_amount" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="30" + android:textColor="#77E382" + android:textSize="16sp" + android:gravity="start"/> + </LinearLayout> + + </LinearLayout> + + <LinearLayout + android:id="@+id/xieyi_layout" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:background="@android:color/transparent" + android:layout_marginTop="15dp" + android:layout_marginLeft="15dp" + android:layout_marginRight="15dp" + android:padding="1dp" + android:orientation="vertical" + android:gravity="center"> + + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:gravity="start" + android:baselineAligned="false" + > + + <TextView + android:id="@+id/protocol_desc_layout" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="自动续费可随时取消,开通后每月按12元自动续费,可随时取消自动续费" + android:textColor="#A19FA7" + android:textSize="12sp" + android:gravity="start"/> + </LinearLayout> + + </LinearLayout> + + + <LinearLayout + android:id="@+id/protocol_layout" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:background="@android:color/transparent" + android:layout_marginTop="15dp" + android:layout_marginLeft="15dp" + android:layout_marginRight="15dp" + android:padding="1dp" + android:orientation="vertical" + android:gravity="center"> + + <LinearLayout + android:layout_width="300dp" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:gravity="center_vertical" + android:baselineAligned="false" + > + + <!-- <CheckBox--> + <!-- android:id="@+id/protocol_checkbox"--> + <!-- android:layout_width="20dp"--> + <!-- android:layout_height="20dp"--> + <!-- android:text=""--> + <!-- android:orientation="horizontal"--> + <!-- android:gravity="start"--> + <!-- />--> + + <CheckBox + android:id="@+id/protocol_checkbox" + android:layout_width="20dp" + android:layout_height="20dp" + /> + + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="已阅读并同意" + android:textColor="#7E5C3C" + android:textSize="14sp" + android:gravity="start" + android:layout_marginLeft="10dp" + android:orientation="horizontal" + /> + + <TextView + android:id="@+id/protocol_vip" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="《VIP会员服务协议》" + android:textColor="#15759E" + android:textSize="14sp" + android:gravity="start" + android:orientation="horizontal" + /> + </LinearLayout> + + </LinearLayout> + + </LinearLayout> + </androidx.cardview.widget.CardView> +</androidx.coordinatorlayout.widget.CoordinatorLayout> \ No newline at end of file -- Gitblit v1.9.3