Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
YDL-Component-Medical
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
杨凯
YDL-Component-Medical
Commits
0f3b0868
Commit
0f3b0868
authored
Jun 21, 2022
by
范玉宾
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
home confide UI done
parent
65a80944
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
560 additions
and
40 deletions
+560
-40
HomeConfideBean.kt
m-home/src/main/java/com/yidianling/home/model/bean/HomeConfideBean.kt
+1
-0
HomeConfideAdapter.kt
m-home/src/ydl/java/com/yidianling/home/adapter/HomeConfideAdapter.kt
+182
-0
HomeConfideExpertInfoView.kt
m-home/src/ydl/java/com/yidianling/home/ui/view/HomeConfideExpertInfoView.kt
+124
-40
home_confide__free.gif
m-home/src/ydl/res/drawable-xhdpi/home_confide__free.gif
+0
-0
home_confide_offline_bg.xml
m-home/src/ydl/res/drawable/home_confide_offline_bg.xml
+7
-0
home_confide_online_main.xml
m-home/src/ydl/res/drawable/home_confide_online_main.xml
+7
-0
home_confide_recommend_expert_line_bg.xml
m-home/src/ydl/res/drawable/home_confide_recommend_expert_line_bg.xml
+7
-0
home_confide_item_layout.xml
m-home/src/ydl/res/layout/home_confide_item_layout.xml
+228
-0
colors.xml
m-home/src/ydl/res/values/colors.xml
+4
-0
No files found.
m-home/src/main/java/com/yidianling/home/model/bean/HomeConfideBean.kt
View file @
0f3b0868
...
...
@@ -38,6 +38,7 @@ class HomeConfideBean : HomeItemBaseBean {
var
confideLine
:
Int
=
0
var
confideAddress
:
String
?
=
null
var
confidePraise
:
String
?
=
null
var
confidePraiseScore
:
String
?=
null
/**
* 实际费用
*/
...
...
m-home/src/ydl/java/com/yidianling/home/adapter/HomeConfideAdapter.kt
0 → 100644
View file @
0f3b0868
package
com.yidianling.home.adapter
import
android.content.Context
import
android.view.LayoutInflater
import
android.view.View
import
android.view.ViewGroup
import
android.widget.FrameLayout
import
android.widget.ImageView
import
android.widget.LinearLayout
import
android.widget.TextView
import
androidx.recyclerview.widget.RecyclerView
import
com.alibaba.android.arouter.launcher.ARouter
import
com.bumptech.glide.Glide
import
com.bumptech.glide.load.resource.drawable.DrawableTransitionOptions
import
com.ydl.webview.H5Params
import
com.ydl.webview.NewH5Activity
import
com.ydl.ydlcommon.modular.ModularServiceManager
import
com.ydl.ydlcommon.utils.Utils
import
com.ydl.ydlcommon.utils.actionutil.ActionCountUtils
import
com.yidianling.home.R
import
com.yidianling.home.constants.HomeBIConstants
import
com.yidianling.home.model.bean.MeditationModuleBean
import
com.yidianling.user.api.service.IUserService
import
kotlinx.android.synthetic.ydl.home_fragment.*
class
HomeConfideAdapter
(
private
val
context
:
Context
,
private
val
data
:
List
<
MeditationModuleBean
.
MeditationDetail
>?,
private
val
moreLink
:
String
?,
private
val
homeLink
:
String
?
=
null
,
private
val
cateId
:
Long
?
=
null
,
private
val
buried
:
String
?
=
null
,
private
val
mark
:
Int
?
=
null
,
private
val
meditationType
:
Int
?
=
null
)
:
RecyclerView
.
Adapter
<
RecyclerView
.
ViewHolder
>()
{
override
fun
onCreateViewHolder
(
parent
:
ViewGroup
,
viewType
:
Int
):
RecyclerView
.
ViewHolder
{
return
when
(
viewType
)
{
CONTENT_TYPE
->
{
MeditationTypeViewHolder
(
LayoutInflater
.
from
(
context
)
.
inflate
(
R
.
layout
.
home_layout_meditation_item
,
parent
,
false
)
)
}
else
->
{
MeditationTypeMoreViewHolder
(
LayoutInflater
.
from
(
context
)
.
inflate
(
R
.
layout
.
home_layout_meditation_more_type
,
parent
,
false
)
)
}
}
}
override
fun
onBindViewHolder
(
holder
:
RecyclerView
.
ViewHolder
,
position
:
Int
)
{
when
(
holder
)
{
is
MeditationTypeViewHolder
->
{
holder
.
ivType
?.
let
{
Glide
.
with
(
context
)
.
load
(
data
?.
get
(
position
)
?.
coverImageUrl
)
.
thumbnail
(
0.1f
)
.
transition
(
DrawableTransitionOptions
.
withCrossFade
())
.
into
(
it
)
}
holder
.
tvName
?.
let
{
it
.
text
=
data
?.
get
(
position
)
?.
title
?:
""
}
holder
.
cvLayout
?.
setOnClickListener
{
ActionCountUtils
.
baiDuCountSign3
(
HomeBIConstants
.
YDL_USER_MAIN_PAGE_MUSE
,
HomeBIConstants
.
YDL_HOME_MEDITATION_CLICK
,
buried
?:
""
,
(
position
+
1
).
toString
(),
""
)
if
(
meditationType
==
0
)
{
if
(
Utils
.
isFastClick
())
{
//防止连击
return
@setOnClickListener
}
if
(!
ModularServiceManager
.
provide
(
IUserService
::
class
.
java
)
.
loginByOneKeyLogin
(
context
,
true
)
)
{
return
@setOnClickListener
}
if
(
data
==
null
)
{
return
@setOnClickListener
}
ARouter
.
getInstance
().
build
(
"/muse/play"
)
.
withLong
(
"MEDITATION_ID"
,
data
[
position
]
?.
meditationId
)
.
withInt
(
"MEDITATION_TYPE"
,
meditationType
)
.
withFloat
(
"MEDIA_DURATION"
,
data
[
position
].
duration
?:
0.0f
)
.
withString
(
"MEDIA_URL"
,
data
[
position
].
mediaIdCoverImageUrl
)
.
withString
(
"MEDIA_COVER_URL"
,
data
[
position
].
mediaIdCoverImageUrl
)
.
navigation
()
// YDLRouterManager.router(ROUTER_MUSE_PLAY,
// YDLRouterParams().putExtra("MEDITATION_ID" , data[position]?.meditationId.toString())
// .putExtra("MEDITATION_TYPE", meditationType.toString())
// .putExtra("MEDIA_DURATION", (data[position].duration?:0).toString())
// .putExtra("MEDIA_URL", data[position].mediaIdCoverImageUrl.toString())
// .putExtra("MEDIA_COVER_URL", data[position].mediaIdCoverImageUrl.toString()))
}
else
{
if
(
Utils
.
isFastClick
())
{
//防止连击
return
@setOnClickListener
}
if
(
data
==
null
)
{
return
@setOnClickListener
}
val
homeLink
=
"${homeLink}mark=$mark&cateId=$cateId&meditationId=${data[position]?.meditationId}"
if
(!
homeLink
.
isNullOrBlank
())
{
NewH5Activity
.
start
(
context
,
H5Params
(
homeLink
,
null
))
}
}
}
}
is
MeditationTypeMoreViewHolder
->
{
holder
.
llMoreLayout
?.
setOnClickListener
{
if
(
Utils
.
isFastClick
())
{
//防止连击
return
@setOnClickListener
}
//冥想助眠更多点击事件
ActionCountUtils
.
count
(
HomeBIConstants
.
YDL_HOME_MEDITATION_VOICE_MORE_CLICK
,
buried
?:
""
)
val
moreLink
=
"${moreLink}mark=$mark&cateId=$cateId"
if
(!
moreLink
.
isNullOrBlank
())
{
NewH5Activity
.
start
(
context
,
H5Params
(
moreLink
,
null
))
}
}
}
}
}
override
fun
getItemCount
():
Int
{
return
if
(
data
?.
isNotEmpty
()
==
true
)
{
data
.
size
+
1
}
else
{
0
}
}
override
fun
getItemId
(
position
:
Int
)
=
position
.
toLong
()
override
fun
getItemViewType
(
position
:
Int
):
Int
{
return
if
(
data
?.
isNotEmpty
()
==
true
&&
position
==
data
.
size
)
{
FOOTER_TYPE
}
else
{
CONTENT_TYPE
}
}
inner
class
MeditationTypeViewHolder
(
itemView
:
View
)
:
RecyclerView
.
ViewHolder
(
itemView
)
{
val
cvLayout
:
FrameLayout
?
=
itemView
.
findViewById
(
R
.
id
.
fl_layout
)
val
ivType
:
ImageView
?
=
itemView
.
findViewById
(
R
.
id
.
iv_meditation_type
)
val
tvName
:
TextView
?
=
itemView
.
findViewById
(
R
.
id
.
tv_meditation_type
)
}
inner
class
MeditationTypeMoreViewHolder
(
itemView
:
View
)
:
RecyclerView
.
ViewHolder
(
itemView
)
{
val
llMoreLayout
:
LinearLayout
?
=
itemView
.
findViewById
(
R
.
id
.
ll_more_type
)
}
companion
object
{
const
val
CONTENT_TYPE
=
0
const
val
FOOTER_TYPE
=
1
}
}
\ No newline at end of file
m-home/src/ydl/java/com/yidianling/home/ui/view/HomeConfideExpertInfoView.kt
View file @
0f3b0868
...
...
@@ -7,13 +7,17 @@ import android.text.TextUtils
import
android.view.View
import
android.view.ViewGroup
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
import
com.yidianling.home.event.IHomeBaseEvent
import
com.yidianling.home.model.bean.HomeConfideBean
import
kotlinx.android.synthetic.ydl.home_confide_
expert_info_view
.view.*
import
kotlinx.android.synthetic.ydl.home_confide_
item_layout
.view.*
/**
* @author jiucheng
...
...
@@ -34,7 +38,7 @@ class HomeConfideExpertInfoView(private var mContext: Context, private var homeE
private
fun
initView
()
{
var
params
=
FrameLayout
.
LayoutParams
(
ViewGroup
.
LayoutParams
.
MATCH_PARENT
,
ViewGroup
.
LayoutParams
.
WRAP_CONTENT
)
layoutParams
=
params
View
.
inflate
(
context
,
R
.
layout
.
home_confide_
expert_info_view
,
this
)
View
.
inflate
(
context
,
R
.
layout
.
home_confide_
item_layout
,
this
)
}
fun
setData
(
bean
:
HomeConfideBean
.
BodyBean
?,
position
:
Int
,
isLast
:
Boolean
)
{
...
...
@@ -44,12 +48,19 @@ class HomeConfideExpertInfoView(private var mContext: Context, private var homeE
}
//设置头像
setHead
(
bean
)
setListenAndScore
(
bean
)
setConfideTag
(
bean
)
setLineStatus
(
bean
)
//设置名称
tv_name
.
text
=
bean
.
confidedName
//设置倾诉标签View的最大宽度
tag_view
.
setConfideWidth
()
//
tag_view.setConfideWidth()
//咨询师标签
tag_view
.
initData
(
bean
.
confidedTag
as
MutableList
<
String
>)
//
tag_view.initData(bean.confidedTag as MutableList<String>)
//设置向TA倾诉人数
setConfideNum
(
bean
)
//设置接通率文案
...
...
@@ -58,11 +69,15 @@ class HomeConfideExpertInfoView(private var mContext: Context, private var homeE
setConfideButton
(
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
())
...
...
@@ -73,11 +88,22 @@ class HomeConfideExpertInfoView(private var mContext: Context, private var homeE
* 设置头像
*/
private
fun
setHead
(
bean
:
HomeConfideBean
.
BodyBean
)
{
val
op
=
SimpleImageOpConfiger
()
op
.
errorPic
=
R
.
drawable
.
platform_head_place_hold_pic
op
.
loadingPic
=
R
.
drawable
.
platform_head_place_hold_pic
op
.
transform
=
0
YDLImageCacheManager
.
showImage
(
mContext
,
bean
.
confidedIcon
,
img_head
,
op
)
// val op = SimpleImageOpConfiger()
// op.errorPic = R.drawable.platform_head_place_hold_pic
// op.loadingPic = R.drawable.platform_head_place_hold_pic
// op.transform = 0
// YDLImageCacheManager.showImage(mContext, bean.confidedIcon, img_head, op)
//这样处理 是防止 滑动过程中 反复去加载图片
if
(!
TextUtils
.
isEmpty
(
bean
.
confidedIcon
)
&&
img_head
.
getTag
(
R
.
id
.
img_head
)
!=
bean
.
confidedIcon
)
{
GlideApp
.
with
(
context
)
.
load
(
bean
.
confidedIcon
)
// .override(dp96, dp96)
.
into
(
img_head
)
img_head
.
setTag
(
R
.
id
.
img_head
,
bean
.
confidedIcon
)
}
}
/**
...
...
@@ -135,41 +161,99 @@ class HomeConfideExpertInfoView(private var mContext: Context, private var homeE
}
}
private
fun
setListenAndScore
(
bodyBean
:
HomeConfideBean
.
BodyBean
)
{
SpanUtils
.
with
(
price_content
).
append
(
bodyBean
.
confideFee
)
.
setForegroundColor
(
resources
.
getColor
(
R
.
color
.
home_confide_fe6040
)).
setFontSize
(
18
,
true
)
.
append
(
"元"
).
setForegroundColor
(
resources
.
getColor
(
R
.
color
.
home_confide_fe6040
))
.
setFontSize
(
11
,
true
)
.
append
(
"/25分钟"
).
setForegroundColor
(
resources
.
getColor
(
R
.
color
.
home_confide_aaaeba
))
.
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
}
}
/**
* 设置在线状态
*/
private
fun
setLineStatus
(
bodyBean
:
HomeConfideBean
.
BodyBean
)
{
when
(
bodyBean
.
confideLine
)
{
//1在线 2离线 3通话中
1
,
4
->
{
tv_online
.
text
=
"在线"
tv_online
.
setBackgroundResource
(
R
.
drawable
.
home_confide_online_main
)
}
2
->
{
tv_online
.
text
=
"离线"
tv_online
.
setBackgroundResource
(
R
.
drawable
.
home_confide_offline_bg
)
}
3
->
{
tv_online
.
text
=
"通话中"
tv_online
.
setBackgroundResource
(
R
.
drawable
.
home_confide_online_main
)
}
}
}
private
fun
setConfideTag
(
bodyBean
:
HomeConfideBean
.
BodyBean
)
{
if
(
null
==
bodyBean
.
confidedTag
||
bodyBean
.
confidedTag
!!
.
isEmpty
())
{
return
}
var
i
=
0
val
sb
=
StringBuilder
()
for
(
tag
in
bodyBean
.
confidedTag
!!
)
{
if
(
i
>
4
)
break
sb
.
append
(
tag
).
append
(
" | "
)
i
++
}
if
(
sb
.
length
>
3
)
{
sb
.
setLength
(
sb
.
length
-
3
)
}
flowlayout_tag
.
text
=
sb
.
toString
()
}
/**
* 设置红包、原价
*/
@SuppressLint
(
"SetTextI18n"
)
private
fun
setCoupon
(
bodyBean
:
HomeConfideBean
.
BodyBean
)
{
if
(!
TextUtils
.
isEmpty
(
bodyBean
.
couponText
)){
tvCoupon
.
text
=
bodyBean
.
couponText
tvCoupon
.
visibility
=
View
.
VISIBLE
}
else
{
tvCoupon
.
visibility
=
View
.
GONE
}
if
(
TextUtils
.
isEmpty
(
bodyBean
.
confideFee
)
||
TextUtils
.
isEmpty
(
bodyBean
.
couponMoney
)
||
bodyBean
.
couponMoney
!!
.
toFloat
()
<=
0
){
tvOriginalPrice
.
visibility
=
View
.
GONE
}
else
{
tvOriginalPrice
.
visibility
=
View
.
VISIBLE
val
originalBuffer
=
StringBuffer
()
originalBuffer
.
append
(
bodyBean
.
confideFee
).
append
(
"元/次"
)
tvOriginalPrice
.
text
=
originalBuffer
.
toString
()
//添加删除线
tvOriginalPrice
.
paint
.
flags
=
Paint
.
STRIKE_THRU_TEXT_FLAG
}
try
{
val
couponMoney
=
bodyBean
.
couponMoney
!!
.
toFloat
().
toInt
()
val
confideFee
=
bodyBean
.
confideFee
!!
.
toFloat
().
toInt
()
if
(
couponMoney
>=
confideFee
){
tv_price
.
text
=
"¥0"
}
else
{
val
price
=
confideFee
-
couponMoney
tv_price
.
text
=
"¥"
+
price
.
toString
()
}
}
catch
(
e
:
Exception
){
//防止数据类型变化引起奔溃
}
//
if(!TextUtils.isEmpty(bodyBean.couponText)){
//
tvCoupon.text = bodyBean.couponText
//
tvCoupon.visibility = View.VISIBLE
//
}else{
//
tvCoupon.visibility = View.GONE
//
}
//
if (TextUtils.isEmpty(bodyBean.confideFee) || TextUtils.isEmpty(bodyBean.couponMoney) || bodyBean.couponMoney!!.toFloat() <= 0){
//
tvOriginalPrice.visibility = View.GONE
//
}else{
//
tvOriginalPrice.visibility = View.VISIBLE
//
val originalBuffer = StringBuffer()
//
originalBuffer.append(bodyBean.confideFee).append("元/次")
//
tvOriginalPrice.text = originalBuffer.toString()
//
//添加删除线
//
tvOriginalPrice.paint.flags = Paint.STRIKE_THRU_TEXT_FLAG
//
}
//
try {
//
val couponMoney = bodyBean.couponMoney!!.toFloat().toInt()
//
val confideFee = bodyBean.confideFee!!.toFloat().toInt()
//
//
if (couponMoney >= confideFee){
//
tv_price.text = "¥0"
//
}else{
//
val price = confideFee - couponMoney
//
tv_price.text = "¥"+price.toString()
//
}
//
}catch (e:Exception){
//
//防止数据类型变化引起奔溃
//
}
}
}
m-home/src/ydl/res/drawable-xhdpi/home_confide__free.gif
0 → 100644
View file @
0f3b0868
21.1 KB
m-home/src/ydl/res/drawable/home_confide_offline_bg.xml
0 → 100644
View file @
0f3b0868
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android=
"http://schemas.android.com/apk/res/android"
>
<corners
android:bottomRightRadius=
"6dp"
/>
<solid
android:color=
"#4d000000"
/>
</shape>
\ No newline at end of file
m-home/src/ydl/res/drawable/home_confide_online_main.xml
0 → 100644
View file @
0f3b0868
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android=
"http://schemas.android.com/apk/res/android"
>
<corners
android:bottomRightRadius=
"6dp"
/>
<solid
android:color=
"#4d000000"
/>
</shape>
\ No newline at end of file
m-home/src/ydl/res/drawable/home_confide_recommend_expert_line_bg.xml
0 → 100644
View file @
0f3b0868
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android=
"http://schemas.android.com/apk/res/android"
>
<corners
android:topRightRadius=
"100dp"
android:bottomRightRadius=
"100dp"
/>
<solid
android:color=
"#40FFFFFF"
/>
</shape>
\ No newline at end of file
m-home/src/ydl/res/layout/home_confide_item_layout.xml
0 → 100644
View file @
0f3b0868
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
android:background=
"@color/white"
tools:ignore=
"MissingDefaultResource"
>
<androidx.cardview.widget.CardView
android:id=
"@+id/card_view"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
app:cardElevation=
"0dp"
app:cardCornerRadius=
"6dp"
android:layout_marginTop=
"20dp"
android:layout_marginStart=
"15dp"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
>
<FrameLayout
android:layout_width=
"96dp"
android:layout_height=
"96dp"
>
<ImageView
android:id=
"@+id/img_head"
android:layout_width=
"96dp"
android:layout_height=
"96dp"
android:scaleType=
"fitXY"
/>
<TextView
android:id=
"@+id/tv_online"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:paddingLeft=
"9dp"
android:paddingRight=
"9dp"
android:paddingTop=
"1dp"
android:paddingBottom=
"1dp"
android:textSize=
"10sp"
android:textColor=
"@color/white"
android:background=
"@drawable/home_confide_recommend_expert_line_bg"
tools:text=
"在线"
/>
<ImageView
android:id=
"@+id/iv_play"
android:layout_width=
"24dp"
android:layout_height=
"24dp"
android:layout_gravity=
"bottom|right"
android:layout_marginBottom=
"8dp"
android:layout_marginEnd=
"8dp"
/>
</FrameLayout>
</androidx.cardview.widget.CardView>
<TextView
android:id=
"@+id/tv_name"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"12dp"
android:textColor=
"#333333"
android:textSize=
"16sp"
android:textStyle=
"bold"
app:layout_constraintStart_toEndOf=
"@id/card_view"
app:layout_constraintTop_toTopOf=
"@id/card_view"
tools:text=
"姚雨晴"
/>
<LinearLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:id=
"@+id/ll_confide_data"
app:layout_constraintTop_toBottomOf=
"@id/tv_name"
app:layout_constraintStart_toEndOf=
"@id/card_view"
android:layout_marginStart=
"12dp"
android:orientation=
"horizontal"
>
<LinearLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
android:gravity=
"center"
>
<TextView
android:id=
"@+id/tv_Connection"
android:layout_marginTop=
"12dp"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textSize=
"14sp"
android:textColor=
"#555555"
android:textStyle=
"bold"
tools:text=
"83%"
/>
<TextView
android:id=
"@+id/tv_ConnectionContent"
android:layout_marginTop=
"3dp"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textSize=
"12sp"
android:textColor=
"#69696A"
android:text=
"接通率"
/>
</LinearLayout>
<LinearLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
android:gravity=
"center"
android:layout_marginStart=
"25dp"
>
<TextView
android:id=
"@+id/tv_confideNum"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textSize=
"@dimen/platform_sp_14"
android:textColor=
"#555555"
android:textStyle=
"bold"
android:layout_marginTop=
"12dp"
tools:text=
"8000人"
/>
<TextView
android:id=
"@+id/tv_tv_confideNumContent"
android:layout_marginTop=
"@dimen/platform_dp_3"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textSize=
"@dimen/platform_sp_12"
android:textColor=
"#69696A"
android:text=
"倾诉人次"
/>
</LinearLayout>
<LinearLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
android:gravity=
"center"
android:layout_marginStart=
"25dp"
>
<TextView
android:id=
"@+id/tv_score"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textSize=
"@dimen/platform_sp_14"
android:textColor=
"#555555"
android:textStyle=
"bold"
android:layout_marginTop=
"12dp"
tools:text=
"4.9"
/>
<TextView
android:id=
"@+id/tv_tv_ScoreContent"
android:layout_marginTop=
"@dimen/platform_dp_3"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textSize=
"@dimen/platform_sp_12"
android:textColor=
"#69696A"
android:text=
"评分"
/>
</LinearLayout>
</LinearLayout>
<TextView
android:id=
"@+id/price_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"3dp"
android:layout_marginRight=
"16dp"
android:text=
"50元/25分钟"
android:textSize=
"@dimen/platform_sp_12"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@+id/ll_confide_data"
/>
<TextView
android:id=
"@+id/flowlayout_tag"
android:layout_width=
"0dp"
android:layout_height=
"16dp"
android:layout_marginStart=
"12dp"
android:layout_marginEnd=
"12dp"
android:textColor=
"#9495A0"
android:maxLines=
"1"
android:ellipsize=
"end"
android:textSize=
"12sp"
app:layout_constraintBottom_toBottomOf=
"@+id/card_view"
app:layout_constraintEnd_toStartOf=
"@+id/price_content"
app:layout_constraintStart_toEndOf=
"@+id/card_view"
/>
<TextView
android:id=
"@+id/tv_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textSize=
"13sp"
android:textColor=
"#919190"
android:maxLines=
"2"
android:ellipsize=
"end"
app:layout_constraintTop_toBottomOf=
"@id/card_view"
app:layout_constraintStart_toStartOf=
"@id/card_view"
android:layout_marginTop=
"@dimen/platform_dp_15"
tools:text=
"没有人一出生就是完美的,只有不断的相信自...己…才能成就自己的梦想。"
/>
<FrameLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"8dp"
app:layout_constraintEnd_toEndOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
>
<TextView
android:id=
"@+id/tv_confide"
android:layout_width=
"40dp"
android:layout_height=
"40dp"
android:layout_marginTop=
"@dimen/platform_dp_15"
android:layout_marginEnd=
"@dimen/platform_dp_15"
android:gravity=
"center"
/>
<ImageView
android:layout_width=
"42dp"
android:layout_height=
"21dp"
android:id=
"@+id/confide_free_logo"
android:layout_marginTop=
"@dimen/platform_dp_5"
android:layout_marginStart=
"@dimen/platform_dp_8"
/>
</FrameLayout>
<View
android:layout_width=
"match_parent"
android:layout_height=
"0.5dp"
app:layout_constraintTop_toBottomOf=
"@id/tv_content"
android:layout_marginTop=
"@dimen/platform_dp_12"
android:layout_marginLeft=
"15dp"
android:background=
"#F0F0F0"
/>
</androidx.constraintlayout.widget.ConstraintLayout>
\ No newline at end of file
m-home/src/ydl/res/values/colors.xml
View file @
0f3b0868
...
...
@@ -4,5 +4,9 @@
<color
name=
"white_60"
>
#99FFFFFF
</color>
<color
name=
"white"
>
#FFFFFF
</color>
<color
name=
"home_confide_61CEAC"
>
#61CEAC
</color>
<color
name=
"home_confide_48CC95"
>
#48CC95
</color>
<color
name=
"home_confide_fe6040"
>
#fe6040
</color>
<color
name=
"home_confide_aaaeba"
>
#aaaeba
</color>
</resources>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment