Преглед изворни кода

修改老师端个人中心部分点击区域

Pq пре 3 година
родитељ
комит
85113f2a81

+ 7 - 12
teacher/src/main/java/com/cooleshow/teacher/ui/main/MineFragment.java

@@ -48,15 +48,13 @@ public class MineFragment extends BaseMVPFragment<FragmentMineLayoutBinding, Min
         mViewBinding.tvFeedback.setOnClickListener(this);
         mViewBinding.tvAuthentication.setOnClickListener(this);
         mViewBinding.tvOpenLive.setOnClickListener(this);
-        mViewBinding.tvFansNum.setOnClickListener(this);
-        mViewBinding.tvFansTitle.setOnClickListener(this);
         mViewBinding.tvMyAccount.setOnClickListener(this);
         mViewBinding.tvNetworkMonitoring.setOnClickListener(this);
         mViewBinding.tvEquipmentTesting.setOnClickListener(this);
-        mViewBinding.tvCourseNumCompleted.setOnClickListener(this);
-        mViewBinding.tvCourseNumCompletedTitle.setOnClickListener(this);
-        mViewBinding.tvCourseNumNotStartTitle.setOnClickListener(this);
-        mViewBinding.tvCourseNumNotStart.setOnClickListener(this);
+        mViewBinding.viewFans.setOnClickListener(this);
+        mViewBinding.viewCourseNumCompleted.setOnClickListener(this);
+        mViewBinding.viewCourseNumNotStart.setOnClickListener(this);
+
         mViewBinding.ivGoodsOrder.setOnClickListener(this);
         mViewBinding.viewVipBg.setOnClickListener(this);
         mViewBinding.tvTradeRecord.setOnClickListener(this);
@@ -232,8 +230,7 @@ public class MineFragment extends BaseMVPFragment<FragmentMineLayoutBinding, Min
                 }
 
                 break;
-            case R.id.tv_fans_title:
-            case R.id.tv_fans_num:
+            case R.id.view_fans:
                 ARouter.getInstance()
                         .build(RouterPath.WebCenter.ACTIVITY_HTML)
                         .withString(WebConstants.WEB_URL, WebConstants.TEACHER_MY_FANS)
@@ -252,10 +249,8 @@ public class MineFragment extends BaseMVPFragment<FragmentMineLayoutBinding, Min
                 //设备检测
                 checkPermission();
                 break;
-            case R.id.tv_course_num_not_start:
-            case R.id.tv_course_num_completed:
-            case R.id.tv_course_num_not_start_title:
-            case R.id.tv_course_num_completed_title:
+            case R.id.view_course_num_not_start:
+            case R.id.view_course_num_completed:
             case R.id.tv_mine_course:
                 ARouter.getInstance().build(RouterPath.CourseCenter.TEACHER_MINE_COURSE)
                         .navigation();

+ 52 - 21
teacher/src/main/res/layout/fragment_mine_layout.xml

@@ -207,25 +207,36 @@
             android:layout_height="28dp"
             android:layout_marginStart="29dp"
             android:layout_marginTop="1dp"
-            android:gravity="center"
             android:layout_marginBottom="10dp"
+            android:gravity="center"
             android:includeFontPadding="false"
             android:text="粉丝"
-            app:layout_constraintHorizontal_chainStyle="spread_inside"
             android:textColor="@color/color_999999"
             android:textSize="@dimen/sp_14"
             app:layout_constraintBottom_toBottomOf="@+id/view_other_info_bg"
+            app:layout_constraintHorizontal_chainStyle="spread_inside"
             app:layout_constraintLeft_toLeftOf="@+id/view_other_info_bg"
             app:layout_constraintRight_toLeftOf="@+id/tv_course_num_completed_title" />
 
         <View
+            android:id="@+id/view_fans"
+            android:layout_width="0dp"
+            android:layout_height="0dp"
+            app:layout_constraintBottom_toBottomOf="@+id/view_other_info_bg"
+            app:layout_constraintLeft_toLeftOf="@+id/view_other_info_bg"
+            app:layout_constraintRight_toLeftOf="@+id/view_line1"
+            app:layout_constraintTop_toTopOf="@+id/view_other_info_bg" />
+
+
+        <View
+            android:id="@+id/view_line1"
+            android:layout_width="0.5dp"
+            android:layout_height="24dp"
             android:background="@color/color_eaeaea"
             app:layout_constraintBottom_toBottomOf="@+id/view_other_info_bg"
-            app:layout_constraintTop_toTopOf="@+id/view_other_info_bg"
-            app:layout_constraintRight_toLeftOf="@+id/tv_course_num_completed_title"
             app:layout_constraintLeft_toRightOf="@+id/tv_fans_title"
-            android:layout_width="0.5dp"
-            android:layout_height="24dp"/>
+            app:layout_constraintRight_toLeftOf="@+id/tv_course_num_completed_title"
+            app:layout_constraintTop_toTopOf="@+id/view_other_info_bg" />
 
         <TextView
             android:id="@+id/tv_course_num_completed_title"
@@ -242,21 +253,31 @@
             app:layout_constraintTop_toTopOf="@+id/tv_fans_title" />
 
         <View
+            android:id="@+id/view_course_num_completed"
+            android:layout_width="0dp"
+            android:layout_height="0dp"
+            app:layout_constraintBottom_toBottomOf="@+id/view_other_info_bg"
+            app:layout_constraintLeft_toRightOf="@+id/view_line1"
+            app:layout_constraintRight_toLeftOf="@+id/view_line2"
+            app:layout_constraintTop_toTopOf="@+id/view_other_info_bg" />
+
+        <View
+            android:id="@+id/view_line2"
+            android:layout_width="0.5dp"
+            android:layout_height="24dp"
             android:background="@color/color_eaeaea"
             app:layout_constraintBottom_toBottomOf="@+id/view_other_info_bg"
-            app:layout_constraintTop_toTopOf="@+id/view_other_info_bg"
-            app:layout_constraintRight_toLeftOf="@+id/tv_course_num_not_start_title"
             app:layout_constraintLeft_toRightOf="@+id/tv_course_num_completed_title"
-            android:layout_width="0.5dp"
-            android:layout_height="24dp"/>
+            app:layout_constraintRight_toLeftOf="@+id/tv_course_num_not_start_title"
+            app:layout_constraintTop_toTopOf="@+id/view_other_info_bg" />
 
 
         <TextView
             android:id="@+id/tv_course_num_not_start_title"
             android:layout_width="58dp"
             android:layout_height="28dp"
-            android:layout_marginEnd="29dp"
             android:layout_marginTop="1dp"
+            android:layout_marginEnd="29dp"
             android:gravity="center"
             android:includeFontPadding="false"
             android:text="未上课时"
@@ -266,19 +287,29 @@
             app:layout_constraintRight_toRightOf="@+id/view_other_info_bg"
             app:layout_constraintTop_toTopOf="@+id/tv_fans_title" />
 
+        <View
+            android:id="@+id/view_course_num_not_start"
+            android:layout_width="0dp"
+            android:layout_height="0dp"
+            app:layout_constraintBottom_toBottomOf="@+id/view_other_info_bg"
+            app:layout_constraintLeft_toRightOf="@+id/view_line2"
+            app:layout_constraintRight_toRightOf="@+id/view_other_info_bg"
+            app:layout_constraintTop_toTopOf="@+id/view_other_info_bg" />
+
+
         <TextView
             android:id="@+id/tv_fans_num"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
+            android:layout_marginBottom="1dp"
             android:includeFontPadding="false"
             android:text="0"
-            android:layout_marginBottom="1dp"
-            app:layout_constraintBottom_toTopOf="@+id/tv_fans_title"
-            app:layout_constraintRight_toRightOf="@+id/tv_fans_title"
-            app:layout_constraintLeft_toLeftOf="@+id/tv_fans_title"
             android:textColor="@color/color_333333"
             android:textSize="@dimen/sp_22"
             android:textStyle="bold"
+            app:layout_constraintBottom_toTopOf="@+id/tv_fans_title"
+            app:layout_constraintLeft_toLeftOf="@+id/tv_fans_title"
+            app:layout_constraintRight_toRightOf="@+id/tv_fans_title"
             tools:text="1181" />
 
         <TextView
@@ -287,12 +318,12 @@
             android:layout_height="wrap_content"
             android:includeFontPadding="false"
             android:text="0"
-            app:layout_constraintRight_toRightOf="@+id/tv_course_num_completed_title"
-            app:layout_constraintLeft_toLeftOf="@+id/tv_course_num_completed_title"
-            app:layout_constraintTop_toTopOf="@+id/tv_fans_num"
             android:textColor="@color/color_333333"
             android:textSize="@dimen/sp_22"
             android:textStyle="bold"
+            app:layout_constraintLeft_toLeftOf="@+id/tv_course_num_completed_title"
+            app:layout_constraintRight_toRightOf="@+id/tv_course_num_completed_title"
+            app:layout_constraintTop_toTopOf="@+id/tv_fans_num"
             tools:text="118" />
 
 
@@ -302,12 +333,12 @@
             android:layout_height="wrap_content"
             android:includeFontPadding="false"
             android:text="0"
-            app:layout_constraintRight_toRightOf="@+id/tv_course_num_not_start_title"
-            app:layout_constraintLeft_toLeftOf="@+id/tv_course_num_not_start_title"
-            app:layout_constraintTop_toTopOf="@+id/tv_fans_num"
             android:textColor="@color/color_333333"
             android:textSize="@dimen/sp_22"
             android:textStyle="bold"
+            app:layout_constraintLeft_toLeftOf="@+id/tv_course_num_not_start_title"
+            app:layout_constraintRight_toRightOf="@+id/tv_course_num_not_start_title"
+            app:layout_constraintTop_toTopOf="@+id/tv_fans_num"
             tools:text="118" />