浏览代码

修改老师端个人风采页面

Pq 2 年之前
父节点
当前提交
32459eac11
共有 29 个文件被更改,包括 521 次插入100 次删除
  1. 二进制
      BaseLibrary/src/main/res/drawable-xhdpi/icon_arrow_right_small.png
  2. 二进制
      BaseLibrary/src/main/res/drawable-xxhdpi/icon_arrow_right_small.png
  3. 5 0
      BaseLibrary/src/main/res/drawable/shape_66000000_10dp.xml
  4. 5 0
      BaseLibrary/src/main/res/drawable/shape_ff7938_12dp.xml
  5. 2 0
      BaseLibrary/src/main/res/values/colors.xml
  6. 二进制
      rong_im/common_im_ui/src/main/res/drawable-xhdpi/icon_teacher_default_head.png
  7. 二进制
      rong_im/common_im_ui/src/main/res/drawable-xxhdpi/icon_teacher_default_head.png
  8. 14 13
      teacher/src/main/java/com/cooleshow/teacher/adapter/MineStyleVideoAdapter.java
  9. 11 2
      teacher/src/main/java/com/cooleshow/teacher/ui/minestyle/MineStylePageActivity.java
  10. 41 0
      teacher/src/main/java/com/cooleshow/teacher/widgets/MineStyleVideoItemDecoration.java
  11. 二进制
      teacher/src/main/res/drawable-xhdpi/icon_add_style.png
  12. 二进制
      teacher/src/main/res/drawable-xhdpi/icon_avatar_select_tip.png
  13. 二进制
      teacher/src/main/res/drawable-xhdpi/icon_check_select_20dp.png
  14. 二进制
      teacher/src/main/res/drawable-xhdpi/icon_check_unselect.png
  15. 二进制
      teacher/src/main/res/drawable-xhdpi/icon_del_video.png
  16. 二进制
      teacher/src/main/res/drawable-xhdpi/icon_edit2.png
  17. 二进制
      teacher/src/main/res/drawable-xhdpi/icon_edit_nickname.png
  18. 二进制
      teacher/src/main/res/drawable-xhdpi/icon_teacher_default_head.png
  19. 二进制
      teacher/src/main/res/drawable-xxhdpi/icon_add_style.png
  20. 二进制
      teacher/src/main/res/drawable-xxhdpi/icon_avatar_select_tip.png
  21. 二进制
      teacher/src/main/res/drawable-xxhdpi/icon_check_select_20dp.png
  22. 二进制
      teacher/src/main/res/drawable-xxhdpi/icon_check_unselect.png
  23. 二进制
      teacher/src/main/res/drawable-xxhdpi/icon_del_video.png
  24. 二进制
      teacher/src/main/res/drawable-xxhdpi/icon_edit2.png
  25. 二进制
      teacher/src/main/res/drawable-xxhdpi/icon_edit_nickname.png
  26. 二进制
      teacher/src/main/res/drawable-xxhdpi/icon_teacher_default_head.png
  27. 6 0
      teacher/src/main/res/drawable/selector_normal_style.xml
  28. 376 52
      teacher/src/main/res/layout/activity_mine_style_page.xml
  29. 61 33
      teacher/src/main/res/layout/item_teacher_style_video_layout.xml

二进制
BaseLibrary/src/main/res/drawable-xhdpi/icon_arrow_right_small.png


二进制
BaseLibrary/src/main/res/drawable-xxhdpi/icon_arrow_right_small.png


+ 5 - 0
BaseLibrary/src/main/res/drawable/shape_66000000_10dp.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android">
+    <solid android:color="@color/color_66000000"/>
+    <corners android:radius="10dp"/>
+</shape>

+ 5 - 0
BaseLibrary/src/main/res/drawable/shape_ff7938_12dp.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android">
+    <solid android:color="@color/color_ff7938"/>
+    <corners android:radius="12dp"/>
+</shape>

+ 2 - 0
BaseLibrary/src/main/res/values/colors.xml

@@ -129,6 +129,7 @@
     <color name="color_e630c7ab">#E630c7ab</color>
     <color name="color_effbf9">#EFFBF9</color>
     <color name="color_f0f0f0">#f0f0f0</color>
+    <color name="color_ff7938">#ff7938</color>
 
     <color name="color_25292e">#25292E</color>
     <color name="color_F8F8F8">#F8F8F8</color>
@@ -157,5 +158,6 @@
     <color name="color_cccccc">#CCCCCC</color>
     <color name="color_fef9f4">#fef9f4</color>
     <color name="color_33000000">#33000000</color>
+    <color name="color_66000000">#66000000</color>
 
 </resources>

二进制
rong_im/common_im_ui/src/main/res/drawable-xhdpi/icon_teacher_default_head.png


二进制
rong_im/common_im_ui/src/main/res/drawable-xxhdpi/icon_teacher_default_head.png


+ 14 - 13
teacher/src/main/java/com/cooleshow/teacher/adapter/MineStyleVideoAdapter.java

@@ -40,23 +40,24 @@ public class MineStyleVideoAdapter extends BaseMultiItemQuickAdapter<TeacherSelf
             case 0:
                 //加载视频缩略图
                 ImageView iv_video_bg = holder.getView(R.id.iv_video_bg);
-                LinearLayout ll_upload_cover=holder.getView(R.id.ll_upload_cover);
-                TextView tv_upload_cover=holder.getView(R.id.tv_upload_cover);
-                ImageView iv_upload_video_cover=holder.getView(R.id.iv_upload_video_cover);
+                TextView tv_upload_cover = holder.getView(R.id.tv_upload_cover);
+                View view_no_cover_bg = holder.getView(R.id.view_no_cover_bg);
+                TextView tv_upload_cover_tip = holder.getView(R.id.tv_upload_cover_tip);
+                ImageView iv_play_video = holder.getView(R.id.iv_play_video);
                 if (TextUtils.isEmpty(styleVideoBean.cover)) {
                     GlideUtils.INSTANCE.loadVideoThumbnail(getContext(), styleVideoBean.videoUrl, iv_video_bg);
-                    tv_upload_cover.setText("上传视频封面");
-                    tv_upload_cover.setTextColor(getContext().getResources().getColor(R.color.white));
-                    ll_upload_cover.setBackgroundResource(R.drawable.shape_2dc7aa_14dp);
-                    iv_upload_video_cover.setImageResource(R.drawable.icon_upload_video_cover);
+                    tv_upload_cover.setText("上传封面");
+                    view_no_cover_bg.setVisibility(View.VISIBLE);
+                    iv_play_video.setVisibility(View.GONE);
+                    tv_upload_cover_tip.setVisibility(View.VISIBLE);
                 } else {
                     GlideUtils.INSTANCE.loadImage(getContext(), styleVideoBean.cover, iv_video_bg, com.cooleshow.base.R.drawable.bg_video_placeholder);
-                    tv_upload_cover.setText("更换视频封面");
-                    tv_upload_cover.setTextColor(getContext().getResources().getColor(com.cooleshow.base.R.color.color_2dc7aa));
-                    ll_upload_cover.setBackgroundResource(R.drawable.bg_select_2dc7aa_radius_14dp);
-                    iv_upload_video_cover.setImageResource(R.drawable.icon_replace_video_cover);
+                    tv_upload_cover.setText("更换封面");
+                    view_no_cover_bg.setVisibility(View.GONE);
+                    iv_play_video.setVisibility(View.VISIBLE);
+                    tv_upload_cover_tip.setVisibility(View.GONE);
                 }
-                ll_upload_cover.setOnClickListener(new View.OnClickListener() {
+                tv_upload_cover.setOnClickListener(new View.OnClickListener() {
                     @Override
                     public void onClick(View v) {
                         if (null != itemAddClickAction) {
@@ -65,7 +66,7 @@ public class MineStyleVideoAdapter extends BaseMultiItemQuickAdapter<TeacherSelf
                     }
                 });
 
-                ImageView im_delete = holder.getView(R.id.im_delete);
+                LinearLayout im_delete = holder.getView(R.id.ll_del_video);
                 im_delete.setOnClickListener(view -> {
                     if (null != itemAddClickAction) {
                         itemAddClickAction.delete(styleVideoBean.videoUrl);

+ 11 - 2
teacher/src/main/java/com/cooleshow/teacher/ui/minestyle/MineStylePageActivity.java

@@ -25,7 +25,9 @@ import com.cooleshow.base.utils.ActivityUtils;
 import com.cooleshow.base.utils.FileUtils;
 import com.cooleshow.base.utils.GsonUtils;
 import com.cooleshow.base.utils.MyFileUtils;
+import com.cooleshow.base.utils.SizeUtils;
 import com.cooleshow.base.utils.ToastUtil;
+import com.cooleshow.base.widgets.CommonItemDecoration;
 import com.cooleshow.teacher.R;
 import com.cooleshow.teacher.adapter.MineStyleVideoAdapter;
 import com.cooleshow.teacher.adapter.TeachableSelectAdapter;
@@ -34,6 +36,7 @@ import com.cooleshow.teacher.bean.TeacherSelfStyleInfoBean;
 import com.cooleshow.teacher.contract.MineStylePageContract;
 import com.cooleshow.teacher.databinding.ActivityMineStylePageBinding;
 import com.cooleshow.teacher.presenter.minestyle.MineStylePagePresenter;
+import com.cooleshow.teacher.widgets.MineStyleVideoItemDecoration;
 import com.daya.live_teaching.utils.GlideEngine;
 import com.google.android.flexbox.AlignItems;
 import com.google.android.flexbox.FlexDirection;
@@ -112,6 +115,9 @@ public class MineStylePageActivity extends BaseMVPActivity<ActivityMineStylePage
                 myStyleInfoBean.subjectName = subjectNameStr;
                 presenter.saveTeacherStyle(GsonUtils.toJson(myStyleInfoBean));
                 break;
+            case R.id.tv_add_style:
+                getVideoPermission();
+                break;
         }
     }
 
@@ -140,10 +146,13 @@ public class MineStylePageActivity extends BaseMVPActivity<ActivityMineStylePage
         videoList = viewBinding.rvTeacherStyleVideo;
         viewBinding.tvSelectFans.setOnClickListener(this);
         viewBinding.tvSave.setOnClickListener(this);
+        viewBinding.tvAddStyle.setOnClickListener(this);
         GridLayoutManager manager = new GridLayoutManager(this, 2);
         videoList.setLayoutManager(manager);
-        addEmptyVideoBean();
+//        addEmptyVideoBean();
         mMineStyleVideoListAdapter = new MineStyleVideoAdapter(videoBeanList);
+        MineStyleVideoItemDecoration itemDecoration = new MineStyleVideoItemDecoration(SizeUtils.dp2px(20), SizeUtils.dp2px(14), 0, SizeUtils.dp2px(14), SizeUtils.dp2px(3.5f));
+        videoList.addItemDecoration(itemDecoration);
         videoList.setAdapter(mMineStyleVideoListAdapter);
         mMineStyleVideoListAdapter.setItemAddClickAction(new MineStyleVideoAdapter.ItemAddClickAction() {
             @Override
@@ -288,7 +297,7 @@ public class MineStylePageActivity extends BaseMVPActivity<ActivityMineStylePage
         if (mMineStyleVideoListAdapter != null) {
             videoBeanList.clear();
             videoBeanList.addAll(styleInfoBean.styleVideo);
-            addEmptyVideoBean();
+//            addEmptyVideoBean();
             mMineStyleVideoListAdapter.notifyDataSetChanged();
         }
         if (!TextUtils.isEmpty(styleInfoBean.subjectId)) {

+ 41 - 0
teacher/src/main/java/com/cooleshow/teacher/widgets/MineStyleVideoItemDecoration.java

@@ -0,0 +1,41 @@
+package com.cooleshow.teacher.widgets;
+
+import android.graphics.Rect;
+import android.view.View;
+
+import androidx.recyclerview.widget.RecyclerView;
+
+/**
+ * Author by pq, Date on 2021/3/18 0018.
+ */
+public class MineStyleVideoItemDecoration extends RecyclerView.ItemDecoration {
+
+    private int top;
+    private int left;
+    private int bottom;
+    private int right;
+    private int center;
+
+    public MineStyleVideoItemDecoration(int top, int left, int bottom, int right, int center) {
+        this.top = top;
+        this.left = left;
+        this.bottom = bottom;
+        this.right = right;
+        this.center = center;
+    }
+
+    @Override
+    public void getItemOffsets(Rect outRect, View view, RecyclerView parent, RecyclerView.State state) {
+        //每行都只有2个
+        int childLayoutPosition = parent.getChildLayoutPosition(view);
+        if (childLayoutPosition % 2 == 0) {
+            outRect.left = left;
+            outRect.right = center;
+        } else {
+            outRect.left = center;
+            outRect.right = right;
+        }
+        outRect.top = top;
+        outRect.bottom = bottom;
+    }
+}

二进制
teacher/src/main/res/drawable-xhdpi/icon_add_style.png


二进制
teacher/src/main/res/drawable-xhdpi/icon_avatar_select_tip.png


二进制
teacher/src/main/res/drawable-xhdpi/icon_check_select_20dp.png


二进制
teacher/src/main/res/drawable-xhdpi/icon_check_unselect.png


二进制
teacher/src/main/res/drawable-xhdpi/icon_del_video.png


二进制
teacher/src/main/res/drawable-xhdpi/icon_edit2.png


二进制
teacher/src/main/res/drawable-xhdpi/icon_edit_nickname.png


二进制
teacher/src/main/res/drawable-xhdpi/icon_teacher_default_head.png


二进制
teacher/src/main/res/drawable-xxhdpi/icon_add_style.png


二进制
teacher/src/main/res/drawable-xxhdpi/icon_avatar_select_tip.png


二进制
teacher/src/main/res/drawable-xxhdpi/icon_check_select_20dp.png


二进制
teacher/src/main/res/drawable-xxhdpi/icon_check_unselect.png


二进制
teacher/src/main/res/drawable-xxhdpi/icon_del_video.png


二进制
teacher/src/main/res/drawable-xxhdpi/icon_edit2.png


二进制
teacher/src/main/res/drawable-xxhdpi/icon_edit_nickname.png


二进制
teacher/src/main/res/drawable-xxhdpi/icon_teacher_default_head.png


+ 6 - 0
teacher/src/main/res/drawable/selector_normal_style.xml

@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="utf-8"?>
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+    <item android:drawable="@drawable/icon_check_select_20dp" android:state_enabled="true" android:state_checked="true"/>
+    <item android:drawable="@drawable/icon_check_unselect" android:state_enabled="true" android:state_checked="false"/>
+    <item android:drawable="@drawable/icon_check_unselect"/>
+</selector>

+ 376 - 52
teacher/src/main/res/layout/activity_mine_style_page.xml

@@ -1,6 +1,7 @@
 <?xml version="1.0" encoding="utf-8"?>
 <LinearLayout 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:background="@color/color_f6f8f9"
@@ -22,6 +23,221 @@
             android:layout_width="match_parent"
             android:layout_height="wrap_content">
 
+            <View
+                android:id="@+id/view_header_info"
+                android:layout_width="match_parent"
+                android:layout_height="0dp"
+                android:layout_marginStart="14dp"
+                android:layout_marginTop="19dp"
+                android:layout_marginEnd="14dp"
+                android:background="@drawable/shape_10dp_white"
+                app:layout_constraintBottom_toBottomOf="@+id/view_header_helper_line"
+                app:layout_constraintLeft_toLeftOf="parent"
+                app:layout_constraintTop_toTopOf="parent" />
+
+            <TextView
+                android:id="@+id/tv_avatar_title"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginStart="15dp"
+                android:layout_marginTop="38dp"
+                android:includeFontPadding="false"
+                android:text="头像"
+                android:textColor="@color/color_666666"
+                android:textSize="@dimen/sp_16"
+                app:layout_constraintLeft_toLeftOf="@+id/view_header_info"
+                app:layout_constraintTop_toTopOf="@+id/view_header_info" />
+
+            <ImageView
+                android:id="@+id/iv_avatar_arrow"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginEnd="14dp"
+                android:src="@drawable/icon_arrow_right_small"
+                app:layout_constraintBottom_toBottomOf="@+id/tv_avatar_title"
+                app:layout_constraintRight_toRightOf="@+id/view_header_info"
+                app:layout_constraintTop_toTopOf="@+id/tv_avatar_title" />
+
+            <de.hdodenhof.circleimageview.CircleImageView
+                android:id="@+id/iv_avatar"
+                android:layout_width="56dp"
+                android:layout_height="56dp"
+                android:layout_marginEnd="22dp"
+                android:src="@drawable/icon_teacher_default_head"
+                app:layout_constraintBottom_toBottomOf="@+id/tv_avatar_title"
+                app:layout_constraintRight_toLeftOf="@+id/iv_avatar_arrow"
+                app:layout_constraintTop_toTopOf="@+id/tv_avatar_title" />
+
+            <ImageView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:src="@drawable/icon_avatar_select_tip"
+                app:layout_constraintBottom_toBottomOf="@+id/iv_avatar"
+                app:layout_constraintRight_toRightOf="@+id/iv_avatar" />
+
+            <TextView
+                android:id="@+id/tv_nickname_title"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="55dp"
+                android:includeFontPadding="false"
+                android:text="昵称"
+                android:textColor="@color/color_666666"
+                android:textSize="@dimen/sp_16"
+                app:layout_constraintLeft_toLeftOf="@+id/tv_avatar_title"
+                app:layout_constraintTop_toBottomOf="@+id/tv_avatar_title" />
+
+
+            <ImageView
+                android:id="@+id/iv_nickname_edit"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginEnd="14dp"
+                android:src="@drawable/icon_edit_nickname"
+                app:layout_constraintBottom_toBottomOf="@+id/tv_nickname_title"
+                app:layout_constraintRight_toRightOf="@+id/view_header_info"
+                app:layout_constraintTop_toTopOf="@+id/tv_nickname_title" />
+
+            <TextView
+                android:id="@+id/tv_nickname"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginEnd="16dp"
+                android:textColor="@color/color_333333"
+                android:textSize="@dimen/sp_16"
+                app:layout_constraintBottom_toBottomOf="@+id/iv_nickname_edit"
+                app:layout_constraintRight_toLeftOf="@+id/iv_nickname_edit"
+                app:layout_constraintTop_toTopOf="@+id/iv_nickname_edit"
+                tools:text="上老师" />
+
+            <TextView
+                android:id="@+id/tv_real_name_title"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="40dp"
+                android:includeFontPadding="false"
+                android:text="实名认证"
+                android:textColor="@color/color_666666"
+                android:textSize="@dimen/sp_16"
+                app:layout_constraintLeft_toLeftOf="@+id/tv_nickname_title"
+                app:layout_constraintTop_toBottomOf="@+id/tv_nickname_title" />
+
+
+            <ImageView
+                android:id="@+id/iv_real_name_arrow"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginEnd="14dp"
+                android:src="@drawable/icon_arrow_right_small"
+                app:layout_constraintBottom_toBottomOf="@+id/tv_real_name_title"
+                app:layout_constraintRight_toRightOf="@+id/view_header_info"
+                app:layout_constraintTop_toTopOf="@+id/tv_real_name_title" />
+
+
+            <TextView
+                android:id="@+id/tv_real_name_status"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginEnd="16dp"
+                android:text="未认证"
+                android:textColor="@color/color_ff0000"
+                android:textSize="@dimen/sp_16"
+                app:layout_constraintBottom_toBottomOf="@+id/iv_real_name_arrow"
+                app:layout_constraintRight_toLeftOf="@+id/iv_real_name_arrow"
+                app:layout_constraintTop_toTopOf="@+id/iv_real_name_arrow"
+                tools:text="未认证" />
+
+            <TextView
+                android:id="@+id/tv_gender_title"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="40dp"
+                android:includeFontPadding="false"
+                android:text="性别"
+                android:textColor="@color/color_666666"
+                android:textSize="@dimen/sp_16"
+                app:layout_constraintLeft_toLeftOf="@+id/tv_real_name_title"
+                app:layout_constraintTop_toBottomOf="@+id/tv_real_name_title" />
+
+            <RadioGroup
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginEnd="14dp"
+                android:orientation="horizontal"
+                app:layout_constraintBottom_toBottomOf="@+id/tv_gender_title"
+                app:layout_constraintRight_toRightOf="@+id/view_header_info"
+                app:layout_constraintTop_toTopOf="@+id/tv_gender_title">
+
+                <RadioButton
+                    android:id="@+id/tv_male"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:button="@drawable/selector_normal_style"
+                    android:checked="true"
+                    android:gravity="center"
+                    android:includeFontPadding="false"
+                    android:text=" 男"
+                    android:textColor="@color/color_666666"
+                    android:textSize="@dimen/sp_16" />
+
+                <RadioButton
+                    android:id="@+id/tv_female"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="30dp"
+                    android:button="@drawable/selector_normal_style"
+                    android:gravity="center"
+                    android:includeFontPadding="false"
+                    android:text=" 女"
+                    android:textColor="@color/color_666666"
+                    android:textSize="@dimen/sp_16" />
+            </RadioGroup>
+
+
+            <TextView
+                android:id="@+id/tv_phone_title"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="40dp"
+                android:includeFontPadding="false"
+                android:text="手机号"
+                android:textColor="@color/color_666666"
+                android:textSize="@dimen/sp_16"
+                app:layout_constraintLeft_toLeftOf="@+id/tv_gender_title"
+                app:layout_constraintTop_toBottomOf="@+id/tv_gender_title" />
+
+
+            <ImageView
+                android:id="@+id/iv_edit_phone"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginEnd="14dp"
+                android:src="@drawable/icon_edit_nickname"
+                app:layout_constraintBottom_toBottomOf="@+id/tv_phone_title"
+                app:layout_constraintRight_toRightOf="@+id/view_header_info"
+                app:layout_constraintTop_toTopOf="@+id/tv_phone_title" />
+
+            <TextView
+                android:id="@+id/tv_phone_num"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginEnd="11dp"
+                android:includeFontPadding="false"
+                android:textColor="@color/color_666666"
+                android:textSize="@dimen/sp_16"
+                app:layout_constraintBottom_toBottomOf="@+id/iv_edit_phone"
+                app:layout_constraintRight_toLeftOf="@+id/iv_edit_phone"
+                app:layout_constraintTop_toTopOf="@+id/iv_edit_phone" />
+
+
+            <View
+                android:id="@+id/view_header_helper_line"
+                android:layout_width="1px"
+                android:layout_height="1px"
+                android:layout_marginTop="20dp"
+                app:layout_constraintLeft_toLeftOf="@+id/tv_phone_title"
+                app:layout_constraintTop_toBottomOf="@+id/tv_phone_title" />
+
             <androidx.constraintlayout.widget.ConstraintLayout
                 android:id="@+id/cl_top_select"
                 android:layout_width="match_parent"
@@ -32,7 +248,7 @@
                 android:background="@drawable/bg_white_10dp"
                 android:orientation="vertical"
                 app:layout_constraintLeft_toLeftOf="parent"
-                app:layout_constraintTop_toTopOf="parent">
+                app:layout_constraintTop_toBottomOf="@+id/view_header_info">
 
                 <ImageView
                     android:id="@+id/im_fan_pages"
@@ -41,46 +257,65 @@
                     android:layout_marginLeft="11dp"
                     android:layout_marginTop="16dp"
                     android:src="@drawable/icon_fan_pages"
+                    android:visibility="gone"
                     app:layout_constraintLeft_toLeftOf="parent"
                     app:layout_constraintTop_toTopOf="parent" />
 
                 <TextView
                     android:id="@+id/start_view"
                     android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
+                    android:layout_height="0dp"
                     android:layout_marginLeft="4dp"
+                    android:gravity="center"
+                    android:includeFontPadding="false"
                     android:text="*"
                     android:textColor="@color/red_eb6363"
                     android:textSize="@dimen/sp_16"
                     android:textStyle="bold"
-                    app:layout_constraintBottom_toBottomOf="@+id/im_fan_pages"
-                    app:layout_constraintLeft_toRightOf="@+id/im_fan_pages"
-                    app:layout_constraintTop_toTopOf="@+id/im_fan_pages" />
+                    android:visibility="visible"
+                    app:layout_constraintBottom_toBottomOf="@+id/tv_select_musical_title"
+                    app:layout_constraintRight_toLeftOf="@+id/tv_select_musical_title"
+                    app:layout_constraintTop_toTopOf="@+id/tv_select_musical_title" />
 
                 <TextView
+                    android:id="@+id/tv_select_musical_title"
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:text="可教授乐器(可多选)"
+                    android:layout_marginStart="14dp"
+                    android:layout_marginTop="16dp"
+                    android:paddingStart="5dp"
+                    android:text="可教授乐器"
                     android:textColor="@color/black_333"
-                    android:textSize="@dimen/sp_16"
+                    android:textSize="@dimen/sp_18"
                     android:textStyle="bold"
-                    app:layout_constraintBottom_toBottomOf="@+id/im_fan_pages"
-                    app:layout_constraintLeft_toRightOf="@+id/start_view"
-                    app:layout_constraintTop_toTopOf="@+id/im_fan_pages" />
+                    app:layout_constraintLeft_toLeftOf="parent"
+                    app:layout_constraintTop_toTopOf="parent" />
+
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:text="(可多选)"
+                    android:textColor="@color/color_cccccc"
+                    android:textSize="@dimen/sp_12"
+                    app:layout_constraintBaseline_toBaselineOf="@+id/tv_select_musical_title"
+                    app:layout_constraintLeft_toRightOf="@+id/tv_select_musical_title" />
 
                 <TextView
                     android:id="@+id/tv_select_fans"
                     android:layout_width="54dp"
                     android:layout_height="24dp"
+                    android:layout_marginEnd="17dp"
                     android:layout_marginRight="11dp"
-                    android:background="@drawable/shape_course_status_ing"
+                    android:drawableLeft="@drawable/icon_edit2"
+                    android:drawablePadding="4dp"
                     android:gravity="center"
+                    android:includeFontPadding="false"
                     android:text="选择"
-                    android:textColor="@color/white"
-                    android:textSize="@dimen/sp_14"
-                    app:layout_constraintBottom_toBottomOf="@+id/im_fan_pages"
+                    android:textColor="@color/color_333333"
+                    android:textSize="@dimen/sp_16"
+                    app:layout_constraintBottom_toBottomOf="@+id/tv_select_musical_title"
                     app:layout_constraintRight_toRightOf="parent"
-                    app:layout_constraintTop_toTopOf="@+id/im_fan_pages" />
+                    app:layout_constraintTop_toTopOf="@+id/tv_select_musical_title" />
 
                 <androidx.recyclerview.widget.RecyclerView
                     android:id="@+id/rv_top_select"
@@ -93,7 +328,19 @@
                     android:overScrollMode="never"
                     android:scrollbars="none"
                     app:layout_constraintBottom_toBottomOf="parent"
-                    app:layout_constraintTop_toBottomOf="@+id/im_fan_pages" />
+                    app:layout_constraintTop_toBottomOf="@+id/tv_select_musical_title" />
+
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginEnd="14dp"
+                    android:layout_marginBottom="13dp"
+                    android:includeFontPadding="false"
+                    android:text="最多可选5种声部"
+                    android:textColor="@color/color_cccccc"
+                    android:textSize="@dimen/sp_12"
+                    app:layout_constraintBottom_toBottomOf="parent"
+                    app:layout_constraintRight_toRightOf="parent" />
 
             </androidx.constraintlayout.widget.ConstraintLayout>
 
@@ -109,40 +356,49 @@
                 app:layout_constraintLeft_toLeftOf="parent"
                 app:layout_constraintTop_toBottomOf="@+id/cl_top_select">
 
-                <ImageView
-                    android:id="@+id/im_personal_introduction"
-                    android:layout_width="24dp"
-                    android:layout_height="24dp"
-                    android:layout_marginLeft="11dp"
+
+                <TextView
+                    android:id="@+id/tv_introduce_title"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginLeft="14dp"
                     android:layout_marginTop="16dp"
-                    android:src="@drawable/icon_personal_introduction"
+                    android:text="个人介绍"
+                    android:textColor="@color/black_333"
+                    android:textSize="@dimen/sp_18"
+                    android:textStyle="bold"
                     app:layout_constraintLeft_toLeftOf="parent"
                     app:layout_constraintTop_toTopOf="parent" />
 
                 <TextView
+                    android:id="@+id/tv_edit_introduce"
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:layout_marginLeft="4dp"
-                    android:text="个人介绍"
-                    android:textColor="@color/black_333"
+                    android:layout_marginEnd="17dp"
+                    android:drawableLeft="@drawable/icon_edit2"
+                    android:drawablePadding="4dp"
+                    android:includeFontPadding="false"
+                    android:text="编辑"
+                    android:textColor="@color/color_333333"
                     android:textSize="@dimen/sp_16"
-                    android:textStyle="bold"
-                    app:layout_constraintBottom_toBottomOf="@+id/im_personal_introduction"
-                    app:layout_constraintLeft_toRightOf="@+id/im_personal_introduction"
-                    app:layout_constraintTop_toTopOf="@+id/im_personal_introduction" />
+                    app:layout_constraintBottom_toBottomOf="@+id/tv_introduce_title"
+                    app:layout_constraintRight_toRightOf="parent"
+                    app:layout_constraintTop_toTopOf="@+id/tv_introduce_title" />
 
                 <TextView
                     android:id="@+id/tv_num_hint"
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
+                    android:layout_marginEnd="14dp"
                     android:layout_marginRight="11dp"
+                    android:layout_marginBottom="12dp"
                     android:gravity="center"
-                    android:text="0/200"
-                    android:textColor="@color/color_999999"
+                    android:text="最多200字介绍"
+                    android:textColor="@color/color_cccccc"
                     android:textSize="@dimen/sp_12"
-                    app:layout_constraintBottom_toBottomOf="@+id/im_personal_introduction"
+                    app:layout_constraintBottom_toBottomOf="parent"
                     app:layout_constraintRight_toRightOf="parent"
-                    app:layout_constraintTop_toTopOf="@+id/im_personal_introduction" />
+                    app:layout_constraintTop_toBottomOf="@+id/et_self_introduction" />
 
                 <EditText
                     android:id="@+id/et_self_introduction"
@@ -162,7 +418,7 @@
                     android:textColorHint="@color/color_999999"
                     android:textSize="@dimen/sp_13"
                     app:layout_constraintBottom_toBottomOf="parent"
-                    app:layout_constraintTop_toBottomOf="@+id/im_personal_introduction" />
+                    app:layout_constraintTop_toBottomOf="@+id/tv_introduce_title" />
 
             </androidx.constraintlayout.widget.ConstraintLayout>
 
@@ -178,40 +434,108 @@
                 app:layout_constraintLeft_toLeftOf="parent"
                 app:layout_constraintTop_toBottomOf="@+id/cl_personal_introduction">
 
-                <ImageView
-                    android:id="@+id/im_teacher_style"
-                    android:layout_width="24dp"
-                    android:layout_height="24dp"
-                    android:layout_marginLeft="11dp"
+                <TextView
+                    android:id="@+id/tv_talent_style_title"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginLeft="14dp"
                     android:layout_marginTop="16dp"
-                    android:src="@drawable/icon_teacher_style"
+                    android:text="达人风采"
+                    android:textColor="@color/black_333"
+                    android:textSize="@dimen/sp_18"
+                    android:textStyle="bold"
                     app:layout_constraintLeft_toLeftOf="parent"
                     app:layout_constraintTop_toTopOf="parent" />
 
                 <TextView
+                    android:id="@+id/tv_add_style"
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:layout_marginLeft="4dp"
-                    android:text="老师风采"
-                    android:textColor="@color/black_333"
+                    android:layout_marginEnd="17dp"
+                    android:drawableLeft="@drawable/icon_add_style"
+                    android:drawablePadding="4dp"
+                    android:includeFontPadding="false"
+                    android:text="添加"
+                    android:textColor="@color/color_333333"
                     android:textSize="@dimen/sp_16"
-                    android:textStyle="bold"
-                    app:layout_constraintBottom_toBottomOf="@+id/im_teacher_style"
-                    app:layout_constraintLeft_toRightOf="@+id/im_teacher_style"
-                    app:layout_constraintTop_toTopOf="@+id/im_teacher_style" />
+                    app:layout_constraintBottom_toBottomOf="@+id/tv_talent_style_title"
+                    app:layout_constraintRight_toRightOf="parent"
+                    app:layout_constraintTop_toTopOf="@+id/tv_talent_style_title" />
 
                 <androidx.recyclerview.widget.RecyclerView
                     android:id="@+id/rv_teacher_style_video"
                     android:layout_width="match_parent"
                     android:layout_height="wrap_content"
-                    android:layout_marginLeft="5dp"
                     android:layout_marginTop="7dp"
-                    android:layout_marginRight="5dp"
-                    android:layout_marginBottom="18dp"
+                    android:layout_marginBottom="29dp"
                     android:overScrollMode="never"
                     android:scrollbars="none"
                     app:layout_constraintBottom_toBottomOf="parent"
-                    app:layout_constraintTop_toBottomOf="@+id/im_teacher_style" />
+                    app:layout_constraintTop_toBottomOf="@+id/tv_talent_style_title" />
+            </androidx.constraintlayout.widget.ConstraintLayout>
+
+            <androidx.constraintlayout.widget.ConstraintLayout
+                android:id="@+id/cs_fans"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginStart="14dp"
+                android:layout_marginTop="12dp"
+                android:layout_marginEnd="14dp"
+                android:background="@drawable/bg_white_10dp"
+                app:layout_constraintTop_toBottomOf="@+id/cl_eacher_style">
+
+                <TextView
+                    android:id="@+id/tv_fans_title"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="14dp"
+                    android:layout_marginTop="16dp"
+                    android:includeFontPadding="false"
+                    android:text="粉丝群"
+                    android:textColor="@color/color_333333"
+                    android:textSize="@dimen/sp_18"
+                    android:textStyle="bold"
+                    app:layout_constraintLeft_toLeftOf="parent"
+                    app:layout_constraintTop_toTopOf="parent" />
+
+                <TextView
+                    android:id="@+id/tv_create_fans_group"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginEnd="17dp"
+                    android:drawableLeft="@drawable/icon_edit2"
+                    android:drawablePadding="4dp"
+                    android:includeFontPadding="false"
+                    android:text="创建"
+                    android:textColor="@color/color_333333"
+                    android:textSize="@dimen/sp_16"
+                    app:layout_constraintBottom_toBottomOf="@+id/tv_fans_title"
+                    app:layout_constraintRight_toRightOf="parent"
+                    app:layout_constraintTop_toTopOf="@+id/tv_fans_title" />
+
+                <androidx.recyclerview.widget.RecyclerView
+                    android:id="@+id/recyclerView_fans"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/dp_18"
+                    android:overScrollMode="never"
+                    android:scrollbars="none"
+                    app:layout_constraintLeft_toLeftOf="parent"
+                    app:layout_constraintRight_toRightOf="parent"
+                    app:layout_constraintTop_toBottomOf="@+id/tv_fans_title" />
+
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="15dp"
+                    android:includeFontPadding="false"
+                    android:paddingBottom="12dp"
+                    android:text="具体群操作请到聊天-群组-群设置中操作"
+                    android:textColor="@color/color_cccccc"
+                    android:textSize="@dimen/sp_12"
+                    app:layout_constraintLeft_toLeftOf="parent"
+                    app:layout_constraintRight_toRightOf="parent"
+                    app:layout_constraintTop_toBottomOf="@+id/recyclerView_fans" />
             </androidx.constraintlayout.widget.ConstraintLayout>
 
             <TextView
@@ -229,7 +553,7 @@
                 android:textSize="@dimen/sp_14"
                 app:layout_constraintBottom_toBottomOf="parent"
                 app:layout_constraintLeft_toLeftOf="parent"
-                app:layout_constraintTop_toBottomOf="@+id/cl_eacher_style" />
+                app:layout_constraintTop_toBottomOf="@+id/cs_fans" />
 
 
         </androidx.constraintlayout.widget.ConstraintLayout>

+ 61 - 33
teacher/src/main/res/layout/item_teacher_style_video_layout.xml

@@ -1,25 +1,42 @@
 <?xml version="1.0" encoding="utf-8"?>
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<androidx.constraintlayout.widget.ConstraintLayout 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:layout_marginTop="6dp">
+    android:layout_height="wrap_content">
 
     <FrameLayout
         android:id="@+id/fl_video"
         android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginLeft="5dp"
-        android:layout_marginRight="5dp">
+        android:layout_height="156dp"
+        app:layout_constraintLeft_toLeftOf="parent"
+        app:layout_constraintRight_toRightOf="parent"
+        app:layout_constraintTop_toTopOf="parent">
 
         <com.cooleshow.base.widgets.QMUIRadiusImageView
             android:id="@+id/iv_video_bg"
             android:layout_width="match_parent"
-            android:layout_height="106dp"
-            android:layout_marginTop="5dp"
+            android:layout_height="156dp"
             app:qmui_corner_radius="10dp" />
 
+        <View
+            android:visibility="gone"
+            android:id="@+id/view_no_cover_bg"
+            android:background="@drawable/shape_66000000_10dp"
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"/>
+
+        <TextView
+            android:visibility="gone"
+            android:id="@+id/tv_upload_cover_tip"
+            android:layout_gravity="center"
+            android:textColor="@color/white"
+            android:textSize="@dimen/sp_14"
+            android:text="请上传视频封面"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"/>
+
         <ImageView
+            android:id="@+id/iv_play_video"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:layout_gravity="center"
@@ -44,37 +61,48 @@
             android:visibility="gone" />
     </FrameLayout>
 
-    <LinearLayout
-        android:id="@+id/ll_upload_cover"
-        android:layout_marginEnd="10dp"
-        android:layout_width="match_parent"
-        android:layout_height="28dp"
-        android:layout_below="@+id/fl_video"
-        android:layout_centerHorizontal="true"
+    <TextView
+        android:id="@+id/tv_upload_cover"
+        android:layout_width="0dp"
+        android:layout_height="wrap_content"
+        android:layout_marginStart="7dp"
         android:layout_marginTop="10dp"
-        android:background="@drawable/shape_2dc7aa_14dp"
-        android:gravity="center">
+        android:background="@drawable/shape_2dc7aa_12dp"
+        android:gravity="center"
+        android:paddingTop="4dp"
+        android:paddingBottom="4dp"
+        android:text="上传封面"
+        android:textColor="@color/white"
+        android:textSize="@dimen/sp_12"
+        app:layout_constraintLeft_toLeftOf="@+id/fl_video"
+        app:layout_constraintRight_toLeftOf="@+id/ll_del_video"
+        app:layout_constraintTop_toBottomOf="@+id/fl_video" />
 
-        <ImageView
-            android:id="@+id/iv_upload_video_cover"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/icon_upload_video_cover" />
+    <LinearLayout
+        android:id="@+id/ll_del_video"
+        android:layout_width="0dp"
+        android:layout_height="0dp"
+        android:layout_marginStart="6dp"
+        android:layout_marginEnd="7dp"
+        android:background="@drawable/shape_ff7938_12dp"
+        android:gravity="center"
+        app:layout_constraintBottom_toBottomOf="@+id/tv_upload_cover"
+        app:layout_constraintLeft_toRightOf="@+id/tv_upload_cover"
+        app:layout_constraintRight_toRightOf="@+id/fl_video"
+        app:layout_constraintTop_toTopOf="@+id/tv_upload_cover">
 
         <TextView
-            android:layout_marginStart="10dp"
-            android:id="@+id/tv_upload_cover"
+            android:id="@+id/tv_del_video"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
-            android:text="请上传视频封面"
+            android:drawableLeft="@drawable/icon_del_video"
+            android:drawablePadding="5dp"
+            android:gravity="center"
+            android:includeFontPadding="false"
+            android:text="删除"
             android:textColor="@color/white"
-            android:textSize="@dimen/sp_14" />
+            android:textSize="@dimen/sp_12" />
     </LinearLayout>
 
-    <ImageView
-        android:id="@+id/im_delete"
-        android:layout_width="22dp"
-        android:layout_height="22dp"
-        android:layout_alignParentRight="true"
-        android:background="@drawable/icon_video_close" />
-</RelativeLayout>
+
+</androidx.constraintlayout.widget.ConstraintLayout>