Commit 21405993 by 刘鹏

Merge branch 'fix/lancet/4398' into 'release'

set free logo status

See merge request app_android_lib/YDL-Component!186
parents 89a7cebd a0c62ec0
......@@ -9,8 +9,8 @@ ext {
"m-consultant" : "0.0.60.68",
"m-fm" : "0.0.30.09",
"m-user" : "0.0.62.55",
"m-home" : "0.0.23.94",
"m-im" : "0.0.21.59",
"m-home" : "0.0.23.95",
"m-im" : "0.0.21.60",
"m-dynamic" : "0.0.7.74",
"m-article" : "0.0.0.10",
"m-muse" : "0.0.28.81",
......@@ -95,8 +95,8 @@ ext {
"m-consultant" : "0.0.60.68",
"m-fm" : "0.0.30.09",
"m-user" : "0.0.62.55",
"m-home" : "0.0.23.94",
"m-im" : "0.0.21.59",
"m-home" : "0.0.23.95",
"m-im" : "0.0.21.60",
"m-dynamic" : "0.0.7.74",
"m-article" : "0.0.0.10",
......
......@@ -38,7 +38,7 @@ class HomeConfideBean : HomeItemBaseBean {
var confideLine: Int = 0
var confideAddress: String? = null
var confidePraise: String? = null
var confidePraiseScore:String?=null
var confidePraiseScore: String? = null
/**
* 实际费用
*/
......@@ -64,5 +64,7 @@ class HomeConfideBean : HomeItemBaseBean {
* 红包展示文本
*/
var couponText : String? = null
var listenFree: Boolean? = null
}
}
......@@ -2,7 +2,6 @@ package com.yidianling.home.ui.view
import android.annotation.SuppressLint
import android.content.Context
import android.graphics.Paint
import android.text.TextUtils
import android.view.View
import android.view.ViewGroup
......@@ -10,8 +9,6 @@ import android.widget.FrameLayout
import com.blankj.utilcode.util.SpanUtils
import com.bumptech.glide.Glide
import com.bumptech.glide.load.engine.DiskCacheStrategy
import com.ydl.ydl_image.config.SimpleImageOpConfiger
import com.ydl.ydl_image.manager.YDLImageCacheManager
import com.ydl.ydl_image.module.GlideApp
import com.yidianling.common.tools.RxImageTool
import com.yidianling.home.R
......@@ -51,6 +48,8 @@ class HomeConfideExpertInfoView(private var mContext: Context, private var homeE
setListenAndScore(bean)
setFreeStatus(bean)
setConfideTag(bean)
setLineStatus(bean)
......@@ -68,16 +67,16 @@ class HomeConfideExpertInfoView(private var mContext: Context, private var homeE
//设置向TA倾诉按钮状态
setConfideButton(bean)
//设置红包、原价
setCoupon(bean)
// setCoupon(bean)
//设置咨询师简介
tv_content.text = bean.confideContent
//最后一项显示分割线
if (isLast) {
// view_line.visibility = View.GONE
view_line.visibility = View.GONE
} else {
// view_line.visibility = View.VISIBLE
view_line.visibility = View.VISIBLE
}
this.setOnClickListener {
homeEvent!!.confideClick(bean.linkUrl, bean.confidedId.toString(), bean.doctorId, bean.uid.toString())
......@@ -171,15 +170,6 @@ class HomeConfideExpertInfoView(private var mContext: Context, private var homeE
.setFontSize(11, true)
.create()
tv_score.text = bodyBean.confidePraiseScore
if (bodyBean.confideFee == "0" && bodyBean.confideLine == 1) {
confide_free_logo.visibility = VISIBLE
Glide.with(context)
.load(R.drawable.home_confide__free)
.diskCacheStrategy(DiskCacheStrategy.RESOURCE)
.into(confide_free_logo)
} else {
confide_free_logo.visibility = GONE
}
}
/**
......@@ -219,6 +209,18 @@ class HomeConfideExpertInfoView(private var mContext: Context, private var homeE
flowlayout_tag.text = sb.toString()
}
private fun setFreeStatus(bodyBean: HomeConfideBean.BodyBean) {
if (bodyBean.listenFree == true && bodyBean.confideLine == 1) {
confide_free_logo.visibility = VISIBLE
Glide.with(context)
.load(R.drawable.home_confide__free)
.diskCacheStrategy(DiskCacheStrategy.RESOURCE)
.into(confide_free_logo)
} else {
confide_free_logo.visibility = GONE
}
}
/**
* 设置红包、原价
*/
......
......@@ -217,6 +217,7 @@
</FrameLayout>
<View
android:id="@+id/view_line"
android:layout_width="match_parent"
android:layout_height="0.5dp"
app:layout_constraintTop_toBottomOf="@id/tv_content"
......
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