Commit 9d4e0690 by 洪国微

添加双11活动标签

parent ea1da919
......@@ -36,5 +36,12 @@ public class CourseHomeBodyBean {
public String originalApplyFee;
public boolean isBuy;
public String demoFile;
/**
* 活动图标
*/
public String activityImg;
/**
* 是否参加活动
*/
public String joinActivity;
}
......@@ -28,4 +28,12 @@ public class CourseHostInfoBean {
public String askTotalTime;
public String helpLong;
public ShareData shareData;
/**
* 活动图标
*/
public String activityImg;
/**
* 是否参加活动
*/
public String joinActivity;
}
......@@ -75,7 +75,16 @@ class CourseItemNewView : ConstraintLayout {
.load(headUrl)
.into(iv_head)
tv_title.text = course.title
//活动标签
if(!TextUtils.isEmpty(course.courseHostInfo?.activityImg)){
img_activity.visibility = View.VISIBLE
GlideApp.with(context).load(course.courseHostInfo?.activityImg).into(img_activity)
tv_title.text = "\u3000\u3000\u3000\u0020"+course.title
}else{
img_activity.visibility = View.GONE
tv_title.text = course.title
}
if (!TextUtils.isEmpty(course.doctorName)) {
doctorName = course.doctorName
} else {
......
......@@ -82,6 +82,14 @@
app:layout_constraintTop_toTopOf="@+id/iv_head"
tools:text="走出余光恐惧,一位余光恐惧者的亲诉一位余光恐惧者的亲诉一位余光恐惧者的亲诉一位余光恐惧者的亲诉"/>
<ImageView
android:id="@+id/img_activity"
android:layout_width="47dp"
android:layout_height="15dp"
android:layout_marginTop="3.3dp"
app:layout_constraintTop_toTopOf="@+id/tv_title"
app:layout_constraintLeft_toLeftOf="@+id/tv_title"
android:visibility="gone"/>
<TextView
android:id="@+id/tv_doctor_info"
android:layout_width="0dp"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment