Commit 493da86b by 刘鹏

Merge branch 'dev' into new_dev_4.3.91

parents 74a96c87 a22c32c0
......@@ -9,8 +9,8 @@ ext {
"m-consultant" : "0.0.60.19",
"m-fm" : "0.0.30.08",
"m-user" : "0.0.62.04",
"m-home" : "0.0.23.18",
"m-im" : "0.0.21.29",
"m-home" : "0.0.23.35",
"m-im" : "0.0.21.30",
"m-dynamic" : "0.0.7.35",
"m-article" : "0.0.0.10",
......@@ -95,8 +95,8 @@ ext {
"m-consultant" : "0.0.60.19",
"m-fm" : "0.0.30.08",
"m-user" : "0.0.62.04",
"m-home" : "0.0.23.18",
"m-im" : "0.0.21.29",
"m-home" : "0.0.23.35",
"m-im" : "0.0.21.30",
"m-dynamic" : "0.0.7.35",
"m-article" : "0.0.0.8",
......
......@@ -114,7 +114,7 @@ class ConsultAssistantDialogUtils private constructor() {
object : ConsultAssistantDialog.OnConsultAssistantClickListener {
override fun onClickAction() {
if (Utils.isFastClick()) {
return onClickAction()
return@onClickAction
}
if (ConsultantIn.getUserImpl().isLogin()){
//获取用户uid
......@@ -161,7 +161,7 @@ class ConsultAssistantDialogUtils private constructor() {
object : ConsultAssistantDialog.OnConsultAssistantClickListener {
override fun onClickAction() {
if (Utils.isFastClick()) {
return onClickAction()
return@onClickAction
}
if (ConsultantIn.getUserImpl().isLogin()){
//获取用户uid
......@@ -206,7 +206,7 @@ class ConsultAssistantDialogUtils private constructor() {
object : ConsultAssistantDialog.OnConsultAssistantClickListener {
override fun onClickAction() {
if (Utils.isFastClick()) {
return onClickAction()
return@onClickAction
}
getConsultAssistantUid("", activity, 4)
}
......@@ -262,7 +262,7 @@ class ConsultAssistantDialogUtils private constructor() {
object : ConsultAssistantDialog.OnConsultAssistantClickListener {
override fun onClickAction() {
if (Utils.isFastClick()) {
return onClickAction()
return@onClickAction
}
ActionCountUtils.count("app_consult_list_page|app_consult_list_daoyi_entry_click")
YdlBuryPointUtil.sendClick("assistant_list_click")
......@@ -294,7 +294,7 @@ class ConsultAssistantDialogUtils private constructor() {
object : ConsultAssistantDialog.OnConsultAssistantClickListener {
override fun onClickAction() {
if (Utils.isFastClick()) {
return onClickAction()
return@onClickAction
}
ActionCountUtils.count("app_consult_list_page|app_consult_list_daoyi_entry_click")
YdlBuryPointUtil.sendClick("assistant_list_click")
......@@ -383,7 +383,6 @@ class ConsultAssistantDialogUtils private constructor() {
@SuppressLint("CheckResult")
private fun getConsultAssistantUid(location: Int, activity: Activity, ffrom: String?) {
obtainApi(SearchApi::class.java).getChatRouteConfig(location)
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
......
......@@ -39,6 +39,8 @@ class HomeBIConstants {
const val YDL_HOME_DWELL_TIME: String = YDL_USER_MAIN_PAGE + "ydl_user_main_page_stay_visit" // 首页停留时长
const val YDL_HOME_ZHUMIANMINGXIANG: String = YDL_USER_MAIN_PAGE + "ydl_user_sleep_aid_more_click" // 首页助眠冥想
const val YDL_HOME_ZHUMIANICON: String = YDL_USER_MAIN_PAGE + "ydl_user_sleep_aid_type_click" // 首页_助眠_icon
const val YDL_HOME_SEARCH_TAG: String = YDL_USER_MAIN_PAGE + "ydl_user_search_tag" // 首页_定制咨询点击tag
const val YDL_HOME_POPUPWINDOWS_PAGE_POPUP: String = YDL_USER_MAIN_PAGE + "popupwindows_page_popup" // 首页弹窗页面弹出事件(99元3小时弹出事件)
}
......
......@@ -6,6 +6,8 @@ import android.text.TextUtils
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.widget.ImageView
import com.ydl.ydl_image.module.GlideApp
import com.ydl.ydlcommon.data.PlatformDataManager
import com.yidianling.home.R
import com.yidianling.home.constract.YdlHomeViewHolderConstract
......@@ -139,7 +141,7 @@ class YdlHomeAdapter(
//底部提示语模块
else -> {
val view = mInflater.inflate(R.layout.home_footer_view, parent, false)
return FooterViewViewHolder(view)
return FooterViewViewHolder(view,viewType)
}
}
}
......@@ -257,5 +259,14 @@ class YdlHomeAdapter(
/**
* 底部提示语模块 ViewHolder
*/
inner class FooterViewViewHolder(val footerView: View) : RecyclerView.ViewHolder(footerView)
inner class FooterViewViewHolder(val footerView: View,val viewType:Int) : RecyclerView.ViewHolder(footerView){
var imageLogoView: ImageView?=null
init {
imageLogoView=footerView.findViewById(R.id.iv_logo_view);
imageLogoView?.let {
GlideApp.with(mContext).load("https://static.yidianling.com/banner/bottombanner@2x.png").into(it);
}
}
}
}
\ No newline at end of file
......@@ -135,33 +135,7 @@ class YdlHomeFragment : BaseMvpFragment<IHomeContract.View, HomePresenterImpl>()
}
}
// val inputLayoutParams = ll_search.layoutParams as CoordinatorLayout.LayoutParams
// val inputOriginMargin = inputLayoutParams.leftMargin
// var inputOffset = DisplayUtils.dp2px(context, 20).toFloat()
//
// appbar_layout.addOnOffsetChangedListener { appBarLayout, i ->
// home_swipe_refresh_layout.isEnabled = i >= 0
//
// val scale = java.lang.Float.valueOf(Math.abs(i).toFloat())!! / java.lang.Float.valueOf(
// appBarLayout.totalScrollRange.toFloat()
// )!!
// view_search_toolbar_bg.alpha = scale
// val leftMargin = inputOriginMargin - inputOffset * scale
// val rightMargin = inputOriginMargin - inputOffset * scale
// inputLayoutParams.setMargins(leftMargin.toInt(), 0, rightMargin.toInt(), 0)
// ll_search.layoutParams = inputLayoutParams
// val zheZhaoAlpha = ((1 - (0.2 * scale)).toFloat())
// //以下判断是因为toolbar和遮罩层拦截住了点击事件,导致banner不好点击
// if (zheZhaoAlpha == 1f) {
// title_layout.visibility = View.GONE
// toolbar.visibility = View.GONE
// } else {
// title_layout.visibility = View.VISIBLE
// toolbar.visibility = View.VISIBLE
// }
// view_search_input_bg.alpha = zheZhaoAlpha
// }
// initStatus()
}
......@@ -236,6 +210,9 @@ class YdlHomeFragment : BaseMvpFragment<IHomeContract.View, HomePresenterImpl>()
} else {
YDLRouterManager.router(act.btnLinkurl)
}
//定制咨询点击事件埋点
ActionCountUtils.count(HomeBIConstants.YDL_HOME_SEARCH_TAG,"1")
}
} else {
img_ad.visibility = View.GONE
......@@ -271,6 +248,8 @@ class YdlHomeFragment : BaseMvpFragment<IHomeContract.View, HomePresenterImpl>()
location[1] - heig,
location[0]
).show()
//99元3小时弹出事件
ActionCountUtils.count(HomeBIConstants.YDL_HOME_POPUPWINDOWS_PAGE_POPUP,"1")
}
}
}
......
package com.yidianling.home.ui.view
import android.content.Context
import android.graphics.Color
import androidx.recyclerview.widget.RecyclerView
import android.text.TextUtils
import android.view.View
import android.view.ViewGroup
import android.widget.FrameLayout
import android.widget.LinearLayout
import android.widget.RelativeLayout
import com.ydl.ydlcommon.data.PlatformDataManager
import com.yidianling.common.tools.RxImageTool
import androidx.recyclerview.widget.RecyclerView
import com.bumptech.glide.Glide
import com.bumptech.glide.load.engine.DiskCacheStrategy
import com.yidianling.home.R
import com.yidianling.home.event.IHomeBaseEvent
import com.yidianling.home.model.bean.HomeHeaderBean
......@@ -38,6 +34,10 @@ class HomeButtonBannerView(private val mContext: Context, private var homeEvent:
layoutParams = params
View.inflate(mContext, R.layout.home_button_banner_view, this)
Glide.with(context)
.load(R.drawable.qingsu_new_free_dynamic)
.diskCacheStrategy(DiskCacheStrategy.RESOURCE)
.into(qingsuGif)
homeModuleButtonBannerFirst.setOnClickListener {
homeEvent?.reservationExpertsClick()
}
......@@ -45,7 +45,7 @@ class HomeButtonBannerView(private val mContext: Context, private var homeEvent:
homeEvent?.askMoreClick()
}
homeModuleButtonBannerThird.setOnClickListener {
homeEvent?.articleMoreClick()
homeEvent?.nowConfideClick()
}
homeModuleButtonBannerFourth.setOnClickListener {
homeEvent?.psychologyTestClick()
......
package com.yidianling.home.ui.view
import android.content.Context
import androidx.constraintlayout.widget.ConstraintLayout
import android.util.AttributeSet
import android.view.View
import com.yidianling.common.tools.RxImageTool
import com.yidianling.home.R
import kotlinx.android.synthetic.xlzx.home_common_title_big_full_view.view.*
/**
* @author liupneg
* @描述: 首页通用标题,富文本样式
* @Company 壹点灵
*/
class HomeCommonTitleBigFullView(private val mContext: Context, private val attributeSet: AttributeSet) :
ConstraintLayout(mContext, attributeSet) {
init {
initView()
}
private fun initView() {
View.inflate(mContext, R.layout.home_common_title_big_full_view, this)
}
fun setTitle(title: String) {
homeModuleCommonTitleViewFullTitle.text = title
}
fun setMoreText(text: String) {
homeModuleCommonTitleViewMorell.visibility = View.VISIBLE
homeModuleCommonTitleViewMoreText.text = text
}
fun setTopMargin(topMargin: Int) {
val params = layoutParams as MarginLayoutParams
params.topMargin = RxImageTool.dp2px(topMargin.toFloat())
layoutParams = params
}
}
\ No newline at end of file
package com.yidianling.home.ui.view
import android.content.Context
import android.graphics.Color
import android.text.TextUtils
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.widget.FrameLayout
import androidx.core.content.ContextCompat
import com.ydl.ydl_image.manager.YDLImageCacheManager
import com.ydl.ydlcommon.utils.URLUtils
import com.ydl.ydlcommon.utils.actionutil.ActionCountUtils
import com.yidianling.common.tools.RxImageTool
import com.yidianling.home.R
import com.yidianling.home.constants.HomeBIConstants
import com.yidianling.home.event.IHomeBaseEvent
import com.yidianling.home.model.bean.HomeConsultBean
import kotlinx.android.synthetic.xlzx.home_consult_item_view.view.*
import java.math.BigDecimal
import kotlinx.android.synthetic.xlzx.home_item_tag.view.*
/**
* @author jiucheng
......@@ -53,12 +50,12 @@ class HomeConsultItemView(private var mContext: Context, private var homeEvent:
setHead(bean)
//设置名称
tv_consult_name.text = bean.name
//咨询师标签
setTag(bean)
//设置接通率文案
setConnection(bean)
//设置向TA咨询人数
setConfideNum(bean)
//设置向TA咨询按钮状态
setConfideButton(bean)
setOnClickListener {
val url = URLUtils.appendParmas(bean.linkUrl, "cateId", cateId)
......@@ -66,6 +63,22 @@ class HomeConsultItemView(private var mContext: Context, private var homeEvent:
}
}
/**咨询师标签*/
private fun setTag(bean: HomeConsultBean.ListBean) {
ll_tags.removeAllViews()
if (!TextUtils.isEmpty(bean.tags)) {
val tagList = bean.tags?.split("|")
tagList.forEachIndexed { index, tag ->
if (index < 2 && !TextUtils.isEmpty(tag)) {
val view = LayoutInflater.from(context)
.inflate(R.layout.home_item_tag, ll_tags, false)
view.tvTag.text = tag
ll_tags.addView(view)
}
}
}
}
/**
* 设置头像
*/
......@@ -79,9 +92,11 @@ class HomeConsultItemView(private var mContext: Context, private var homeEvent:
private fun setConfideNum(bodyBean: HomeConsultBean.ListBean) {
if (TextUtils.isEmpty(bodyBean.zixunOrderNum.toString())) {
tv_consult_num.visibility = View.GONE
tv_tv_consult_num_content.visibility = View.GONE
} else {
tv_consult_num.visibility = View.VISIBLE
tv_consult_num.text = "咨询次数${bodyBean.zixunOrderNum}"
tv_tv_consult_num_content.visibility = View.VISIBLE
tv_consult_num.text = bodyBean.zixunOrderNum.toString()
}
}
......@@ -91,40 +106,18 @@ class HomeConsultItemView(private var mContext: Context, private var homeEvent:
private fun setConnection(bodyBean: HomeConsultBean.ListBean) {
if (TextUtils.isEmpty(bodyBean.feedbackRate.toString())) {
tv_feedback_rate.visibility = View.INVISIBLE
tv_feedback_rate_content.visibility = View.INVISIBLE
} else {
tv_feedback_rate.visibility = View.VISIBLE
tv_feedback_rate_content.visibility = View.VISIBLE
try {
val d = BigDecimal(bodyBean.feedbackRate.toString()).setScale(1, BigDecimal.ROUND_DOWN)
val str = d.toString()
val dd = bodyBean.feedbackRate/5.00f
val str = String.format("%.0f",dd*100f)+"%"
tv_feedback_rate.text = str
} catch (e: Exception) {
}catch (e:Exception){
e.printStackTrace()
}
}
}
/**
* 设置向TA倾诉按钮状态
*/
private fun setConfideButton(bodyBean: HomeConsultBean.ListBean) {
//私聊文案
if (TextUtils.isEmpty(bodyBean.chatBtnText)) {
tv_consult_chat.text = "私聊"
tv_consult_chat.setTextColor(Color.parseColor("#FD9B0A"))
} else {
tv_consult_chat.text = bodyBean.chatBtnText
tv_consult_chat.setTextColor(
ContextCompat.getColor(
context,
R.color.platform_color_999999
)
)
}
tv_consult_chat.setOnClickListener {
homeEvent!!.consultChatClick(bodyBean.uid.toString())
ActionCountUtils.count(HomeBIConstants.YDL_PRIVATE_CHAT_CLICK)
}
}
}
......@@ -4,14 +4,12 @@ import android.content.Context
import android.graphics.Color
import android.graphics.Typeface
import android.os.Build
import com.google.android.material.tabs.TabLayout
import androidx.core.content.ContextCompat
import androidx.recyclerview.widget.RecyclerView
import android.text.Layout
import android.view.View
import android.view.ViewGroup
import android.widget.LinearLayout
import android.widget.TextView
import androidx.recyclerview.widget.RecyclerView
import com.google.android.material.tabs.TabLayout
import com.yidianling.common.tools.LogUtil
import com.yidianling.common.tools.RxDeviceTool
import com.yidianling.common.tools.RxImageTool
......@@ -19,9 +17,7 @@ import com.yidianling.home.R
import com.yidianling.home.event.IHomeBaseEvent
import com.yidianling.home.model.bean.HomeConsultBean
import com.yidianling.home.model.bean.HomeHeaderBean
import kotlinx.android.synthetic.xlzx.home_confide_view.view.*
import java.lang.Exception
import kotlin.math.ceil
import kotlinx.android.synthetic.xlzx.home_consult_view.view.*
/**
* @author <a href="https://www.jianshu.com/u/c1e5310dd724">xujian</a>
......@@ -65,11 +61,11 @@ class HomeConsultView(private val mContext: Context, private var homeEvent: IHom
)
layoutParams = params
orientation = VERTICAL
View.inflate(mContext, R.layout.home_confide_view, this)
homeModuleConfideViewHomeCommonTitleView.setTitle("心理咨询")
homeModuleConfideViewHomeCommonTitleView.setMoreText("更多咨询")
homeModuleConfideViewHomeCommonTitleView.setTopMargin(-4)
homeModuleConfideViewHomeCommonTitleView.setOnClickListener {
View.inflate(mContext, R.layout.home_consult_view, this)
homeModuleConfideViewHomeCommonFullTitleView.setTitle("心理咨询")
homeModuleConfideViewHomeCommonFullTitleView.setMoreText("更多")
homeModuleConfideViewHomeCommonFullTitleView.setTopMargin(-4)
homeModuleConfideViewHomeCommonFullTitleView.setOnClickListener {
homeEvent?.consultMoreClick()
}
}
......@@ -219,15 +215,14 @@ class HomeConsultView(private val mContext: Context, private var homeEvent: IHom
fun updateText(txtView: TextView, isSelected: Boolean): TextView {
if (!isSelected) {
txtView.textSize = 12f
txtView.setTextColor(Color.parseColor("#999999"))
txtView.setTextColor(Color.parseColor("#929292"))
txtView.typeface = Typeface.DEFAULT
txtView.setPadding(dp10, dp5, dp10, dp7)
txtView.setBackgroundResource(R.drawable.home_consult_tab_item_unselected_bg)
} else {
txtView.textSize = 12f
txtView.setTextColor(Color.parseColor("#FD9B0A"))
txtView.textSize = 14f
txtView.setTextColor(Color.parseColor("#5E5E5E"))
txtView.typeface = Typeface.DEFAULT_BOLD
txtView.setPadding(dp10, dp5, dp10, dp7)
txtView.setBackgroundResource(R.drawable.home_consult_tab_item_selected_bg)
}
return txtView
}
......
......@@ -69,6 +69,7 @@ class HomeModuleCategoryView : FrameLayout {
var dp6: Int = 0
var dp8: Int = 0
var dp12: Int = 0
//左右间距
var dp15: Int = 0
/**
* 倍数
......@@ -116,13 +117,13 @@ class HomeModuleCategoryView : FrameLayout {
dp6 = RxImageTool.dip2px(4f)
dp12 = RxImageTool.dip2px(12f)
categoryEightWidth = ScreenUtil.screenWidth - RxImageTool.dp2px(30f)
categoryEightWidth = ScreenUtil.screenWidth - RxImageTool.dp2px(8f)
textViewWidth = categoryEightWidth / 4
imageEightViewWidth = RxImageTool.dip2px(38f)
textViewHeight = RxImageTool.dip2px(28f)
margin = (categoryEightWidth - 4 * imageEightViewWidth) / 8
dp8 = RxImageTool.dip2px(8f)
dp15 = RxImageTool.dip2px(15f)
dp15 = RxImageTool.dip2px(4f)
}
fun initData(askCategoryDataBean: List<HomeHeaderBean.AskCategoryDataBean>?) {
......
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<corners android:radius="1dp"></corners>
<solid android:color="@color/platform_white" />
<stroke android:width="0.5dp" android:color="@color/platform_color_E0E0E0"/>
</shape>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="#FF4E4E" />
<corners
android:bottomLeftRadius="0dp"
android:bottomRightRadius="7dp"
android:topLeftRadius="7dp"
android:topRightRadius="7dp" />
<stroke
android:width="1dp"
android:color="@color/white" />
<padding
android:left="3dp"
android:right="4dp" />
</shape>
\ No newline at end of file
<?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"
android:id="@+id/ll_home_module_button"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_marginTop="17dp">
android:layout_marginTop="17dp"
android:orientation="vertical">
<com.yidianling.home.ui.widget.HomeModuleCategoryView
android:id="@+id/home_category_view"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="15dp"
android:layout_marginRight="15dp"
android:gravity="center_horizontal"
android:layout_marginLeft="4dp"
android:layout_marginTop="15dp"
android:layout_marginRight="4dp"
android:gravity="center_horizontal|bottom"
android:orientation="horizontal"
android:paddingBottom="12dp">
......@@ -20,22 +27,23 @@
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical"
android:gravity="center">
android:gravity="center"
android:orientation="vertical">
<ImageView
android:layout_width="54dp"
android:layout_height="38dp"
android:src="@drawable/home_banner_first_icon"
android:scaleType="fitXY"/>
android:layout_width="52dp"
android:layout_height="52dp"
android:scaleType="fitXY"
android:src="@drawable/home_banner_first_icon" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="咨询沟通"
android:layout_marginTop="3dp"
android:layout_marginTop="6dp"
android:text="心理咨询"
android:textColor="@color/platform_color_242424"
android:textSize="13dp"/>
android:textSize="13dp"
android:textStyle="bold" />
</LinearLayout>
<LinearLayout
......@@ -43,75 +51,92 @@
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical"
android:gravity="center">
android:gravity="center"
android:orientation="vertical">
<ImageView
android:layout_width="54dp"
android:layout_height="38dp"
android:src="@drawable/home_banner_fourth_icon"
android:scaleType="fitXY"/>
android:layout_height="52dp"
android:scaleType="fitXY"
android:src="@drawable/home_banner_fourth_icon" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:text="心理测试"
android:layout_marginTop="3dp"
android:textColor="@color/platform_color_242424"
android:textSize="13dp"/>
android:textSize="13dp"
android:textStyle="bold" />
</LinearLayout>
<LinearLayout
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/homeModuleButtonBannerThird"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical"
android:gravity="center">
android:gravity="center"
android:orientation="vertical">
<ImageView
android:layout_width="54dp"
android:layout_height="38dp"
android:id="@+id/third_icon"
android:layout_width="71dp"
android:layout_height="64dp"
android:paddingLeft="7dp"
android:paddingTop="12dp"
android:paddingRight="12dp"
android:scaleType="fitXY"
android:src="@drawable/home_banner_third_icon"
android:scaleType="fitXY"/>
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:id="@+id/qingsuGif"
android:layout_width="45dp"
android:layout_height="24dp"
app:layout_constraintRight_toRightOf="@id/third_icon"
app:layout_constraintTop_toTopOf="@id/third_icon" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="主题阅读"
android:layout_marginTop="3dp"
android:layout_below="@id/third_icon"
android:layout_marginTop="6dp"
android:text="倾诉热线"
android:textColor="@color/platform_color_242424"
android:textSize="13dp"/>
</LinearLayout>
android:textSize="13dp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="@id/third_icon"
app:layout_constraintRight_toRightOf="@id/third_icon"
app:layout_constraintTop_toBottomOf="@id/third_icon" />
</androidx.constraintlayout.widget.ConstraintLayout>
<LinearLayout
android:id="@+id/homeModuleButtonBannerSecond"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical"
android:gravity="center">
android:gravity="center"
android:orientation="vertical">
<ImageView
android:layout_width="54dp"
android:layout_height="38dp"
android:src="@drawable/home_banner_second_icon"
android:scaleType="fitXY"/>
android:layout_width="52dp"
android:layout_height="52dp"
android:scaleType="fitXY"
android:src="@drawable/home_banner_second_icon" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="人生答疑"
android:layout_marginTop="3dp"
android:layout_marginTop="6dp"
android:text="心理问答"
android:textColor="@color/platform_color_242424"
android:textSize="13dp"/>
android:textSize="13dp"
android:textStyle="bold" />
</LinearLayout>
</LinearLayout>
<com.yidianling.home.ui.widget.HomeModuleCategoryView
android:id="@+id/home_category_view"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout 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="wrap_content"
android:paddingTop="@dimen/platform_dp_30"
android:paddingBottom="@dimen/platform_dp_6">
<TextView
android:id="@+id/homeModuleCommonTitleViewFullTitle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/platform_dp_16"
android:paddingRight="@dimen/platform_dp_1"
android:textColor="@color/platform_color_242424"
android:textSize="20sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:text="通用标题" />
<TextView
android:id="@+id/people_num"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="20dp"
android:text="300w+"
android:textColor="#5A8AFF"
android:textSize="17sp"
android:textStyle="bold"
app:layout_constraintBaseline_toBaselineOf="@id/homeModuleCommonTitleViewFullTitle"
app:layout_constraintLeft_toRightOf="@id/homeModuleCommonTitleViewFullTitle" />
<TextView
android:layout_width="0dp"
android:layout_height="wrap_content"
android:ellipsize="end"
android:maxLines="1"
android:text=" 人在这里发生了改变"
android:textColor="@color/platform_color_999999"
android:textSize="13sp"
app:layout_constraintBaseline_toBaselineOf="@id/homeModuleCommonTitleViewFullTitle"
app:layout_constraintHorizontal_weight="1"
app:layout_constraintLeft_toRightOf="@id/people_num"
app:layout_constraintRight_toLeftOf="@id/homeModuleCommonTitleViewMorell" />
<LinearLayout
android:id="@+id/homeModuleCommonTitleViewMorell"
android:layout_width="wrap_content"
android:layout_height="@dimen/platform_dp_18"
android:layout_marginRight="@dimen/platform_dp_16"
android:background="@drawable/home_show_more_line"
android:gravity="center"
android:orientation="horizontal"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:visibility="visible"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintRight_toRightOf="parent">
<TextView
android:id="@+id/homeModuleCommonTitleViewMoreText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/platform_dp_2"
android:gravity="center"
android:text="更多"
android:textColor="@color/platform_color_666666"
android:textSize="10sp" />
<ImageView
android:layout_marginLeft="2dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/home_more_icon_gray" />
</LinearLayout>
</androidx.constraintlayout.widget.ConstraintLayout>
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
<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:orientation="vertical"
android:background="@drawable/home_view_shadow_bg"
android:gravity="center"
android:background="@drawable/home_view_shadow_bg">
<RelativeLayout
android:layout_width="wrap_content"
android:orientation="vertical">
<androidx.cardview.widget.CardView
android:layout_width="64dp"
android:layout_height="64dp"
android:layout_marginTop="19dp">
<androidx.cardview.widget.CardView
android:layout_width="64dp"
android:layout_height="64dp"
android:layout_centerInParent="true"
app:cardCornerRadius="32dp"
app:cardElevation="0dp"
android:layout_centerHorizontal="true">
<ImageView
android:id="@+id/img_consult_head"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"
android:background="@color/platform_color_E0E0E0"/>
</androidx.cardview.widget.CardView>
</RelativeLayout>
android:layout_centerInParent="true"
android:layout_centerHorizontal="true"
android:layout_marginTop="20dp"
app:cardCornerRadius="32dp"
app:cardElevation="0dp">
<ImageView
android:id="@+id/img_consult_head"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/platform_color_E0E0E0"
android:scaleType="centerCrop" />
</androidx.cardview.widget.CardView>
<TextView
android:id="@+id/tv_consult_name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:textColor="@color/platform_color_242424"
android:textSize="@dimen/platform_dp_16"
android:textStyle="bold"
tools:ignore="SpUsage"
tools:text="姚雨晴" />
<LinearLayout
android:id="@+id/tv_name_layout"
android:layout_marginTop="4dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="13dp"
android:gravity="center_vertical"
android:orientation="horizontal">
<TextView
android:id="@+id/tv_consult_name"
android:id="@+id/tv_tv_consult_num_content"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/platform_color_242424"
android:textSize="@dimen/platform_dp_16"
android:textStyle="bold"
tools:ignore="SpUsage"
tools:text="姚雨晴"/>
<ImageView
android:id="@+id/img_sex"
android:layout_width="13dp"
android:layout_height="13dp"
android:layout_marginStart="6dp"
android:layout_marginLeft="3dp"
android:background="@drawable/home_counselor"/>
</LinearLayout>
android:text="咨询次数 "
android:textColor="#888888"
android:textSize="@dimen/platform_dp_10" />
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:id="@+id/tv_feedback_rate"
android:id="@+id/tv_consult_num"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#FF5B46"
android:textSize="15dp"
android:textStyle="bold"
tools:text="9.8"/>
android:textColor="#888888"
android:textSize="@dimen/platform_dp_10"
tools:text="8000" />
<TextView
android:id="@+id/tv_feedback_rate_content"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#FF5B46"
android:textSize="14dp"
android:text="分"/>
android:layout_marginLeft="12dp"
android:text="好评率 "
android:textColor="#888888"
android:textSize="@dimen/platform_dp_10" />
<TextView
android:id="@+id/tv_consult_num"
android:id="@+id/tv_feedback_rate"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/platform_color_666666"
android:textSize="@dimen/platform_dp_13"
tools:text="8000次咨询"
android:layout_marginLeft="4dp"/>
android:textColor="#888888"
android:textSize="@dimen/platform_dp_10"
tools:text="83%" />
</LinearLayout>
<TextView
android:id="@+id/tv_consult_chat"
android:layout_width="74dp"
android:layout_height="28dp"
android:layout_alignParentBottom="true"
android:layout_centerHorizontal="true"
android:background="@drawable/home_consult_chat_rest_bg"
android:gravity="center"
android:paddingLeft="9dp"
android:paddingRight="9dp"
tools:text="休息中"
android:layout_marginTop="10dp"
android:layout_marginBottom="15dp"
android:textColor="@color/platform_color_999999"
android:textSize="12dp"/>
<LinearLayout
android:id="@+id/ll_tags"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:layout_marginBottom="12dp"
android:layout_marginEnd="@dimen/platform_dp_10"
android:layout_marginStart="@dimen/platform_dp_16"
android:gravity="center_vertical"
android:orientation="horizontal"/>
</LinearLayout>
......
<?xml version="1.0" encoding="utf-8"?>
<merge 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:orientation="vertical"
android:clipChildren="false">
<com.yidianling.home.ui.view.HomeCommonTitleBigFullView
android:id="@+id/homeModuleConfideViewHomeCommonFullTitleView"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:orientation="horizontal"
android:clipChildren="false"
>
<com.google.android.material.tabs.TabLayout
android:id="@+id/tab_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:tabGravity="fill"
app:tabIndicatorHeight="0dp"
android:layout_marginLeft="2dp"
android:layout_marginRight="8dp"
app:tabMode="scrollable"
app:tabPaddingStart="4dp"
app:tabPaddingEnd="4dp"
app:tabSelectedTextColor="@color/platform_color_242424"
app:tabTextAppearance="@style/TabLayoutTextSize"
app:tabTextColor="#333"/>
</LinearLayout>
<FrameLayout
android:id="@+id/ll_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
</merge>
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:paddingTop="@dimen/platform_dp_30"
android:paddingBottom="@dimen/platform_dp_16">
android:orientation="horizontal">
<View
android:layout_width="48dp"
android:layout_height="0.5dp"
android:background="@color/platform_color_EBEBEB"
android:layout_marginRight="@dimen/platform_dp_8"/>
<TextView
android:layout_width="wrap_content"
<ImageView
android:id="@+id/iv_logo_view"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textColor="@color/platform_color_999999"
android:textSize="@dimen/platform_dp_10"
android:text="我是有底线的"/>
<View
android:layout_width="48dp"
android:layout_height="0.5dp"
android:layout_marginLeft="@dimen/platform_dp_8"
android:background="@color/platform_color_EBEBEB"/>
android:background="@color/baby_blue"
/>
</LinearLayout>
\ No newline at end of file
......@@ -7,60 +7,6 @@
android:layout_height="match_parent"
android:clipChildren="false"
android:clipToPadding="false">
<!-- <android.support.design.widget.CoordinatorLayout-->
<!-- android:id="@+id/container"-->
<!-- android:layout_width="match_parent"-->
<!-- android:layout_height="match_parent"-->
<!-- android:background="@color/home_colorBg"-->
<!-- android:clipChildren="false"-->
<!-- android:clipToPadding="false"-->
<!-- app:layout_behavior="@string/appbar_scrolling_view_behavior"-->
<!-- >-->
<!-- <android.support.design.widget.AppBarLayout-->
<!-- android:id="@+id/appbar_layout"-->
<!-- android:layout_width="match_parent"-->
<!-- android:layout_height="wrap_content"-->
<!-- android:background="@color/home_colorBg"-->
<!-- android:clipChildren="false"-->
<!-- android:clipToPadding="false"-->
<!-- android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"-->
<!-- app:elevation="0dp">-->
<!-- <android.support.design.widget.CollapsingToolbarLayout-->
<!-- android:layout_width="match_parent"-->
<!-- android:layout_height="match_parent"-->
<!-- android:clipChildren="false"-->
<!-- android:clipToPadding="false"-->
<!-- app:layout_scrollFlags="scroll|exitUntilCollapsed">-->
<!-- <include layout="@layout/home_layout_home_module_head_bg"/>-->
<!-- <include-->
<!-- layout="@layout/home_layout_home_module_head_middle"/>-->
<!-- <android.support.v7.widget.Toolbar-->
<!-- android:id="@+id/toolbar"-->
<!-- android:layout_width="match_parent"-->
<!-- android:layout_height="@dimen/home_home_title_bar_height"-->
<!-- android:alpha="0"-->
<!-- android:background="@android:color/white"-->
<!-- android:tag="toolbar"-->
<!-- android:visibility="gone"-->
<!-- app:layout_collapseMode="pin"-->
<!-- app:popupTheme="@style/Widget.AppCompat.Toolbar"/>-->
<!-- <include layout="@layout/home_layout_home_module_toolbar"/>-->
<!-- </android.support.design.widget.CollapsingToolbarLayout>-->
<!-- </android.support.design.widget.AppBarLayout>-->
<!-- </android.support.design.widget.CoordinatorLayout>-->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
......@@ -69,7 +15,4 @@
<include layout="@layout/home_layout_home_module_content"/>
</LinearLayout>
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
<?xml version="1.0" encoding="utf-8"?>
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/tvTag"
android:layout_width="wrap_content"
android:layout_height="14dp"
android:layout_marginRight="6dp"
android:background="@drawable/home_bg_radius_line_gray_1"
android:gravity="center"
android:paddingLeft="4dp"
android:paddingRight="4dp"
android:textColor="@color/platform_color_999999"
android:textSize="10sp"
tools:text="恋爱情感" />
......@@ -326,6 +326,8 @@ open class YdlHomeFragment : BaseMvpFragment<IHomeContract.View, HomePresenterIm
} else {
YDLRouterManager.router(act.btnLinkurl)
}
//定制咨询点击事件埋点
ActionCountUtils.count(HomeBIConstants.YDL_HOME_SEARCH_TAG,"1")
}
} else {
img_ad.visibility = View.GONE
......@@ -352,6 +354,8 @@ open class YdlHomeFragment : BaseMvpFragment<IHomeContract.View, HomePresenterIm
//文案不为空才显示引导--李思开
if (!TextUtils.isEmpty(act.title)) {
ActivityGuideDialog(mActivity, act.imageUrl, act.title).show()
//99元3小时弹出事件
ActionCountUtils.count(HomeBIConstants.YDL_HOME_POPUPWINDOWS_PAGE_POPUP,"1")
}
}
}
......
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