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
f09b9019
Commit
f09b9019
authored
5 years ago
by
严久程
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
华为渠道特殊处理
parent
e428403e
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
73 additions
and
23 deletions
+73
-23
config.gradle
config.gradle
+1
-1
ExpertSearchFragment.kt
m-consultant/src/main/java/com/yidianling/consultant/ExpertSearchFragment.kt
+1
-1
ExpertSearchAdapter.kt
m-consultant/src/main/java/com/yidianling/consultant/adapter/ExpertSearchAdapter.kt
+22
-0
consultant_expert_search_item_view.xml
m-consultant/src/main/res/layout/consultant_expert_search_item_view.xml
+0
-0
YdlHomeAdapter.kt
m-home/src/xlzx/java/com/yidianling/home/adapter/YdlHomeAdapter.kt
+37
-19
HomeButtonBannerView.kt
m-home/src/xlzx/java/com/yidianling/home/ui/view/HomeButtonBannerView.kt
+12
-2
No files found.
config.gradle
View file @
f09b9019
ext
{
ext
{
kotlin_version
=
"1.3.21"
kotlin_version
=
"1.3.21"
dev_mode
=
fals
e
dev_mode
=
tru
e
ydl_app
=
[
ydl_app
=
[
...
...
This diff is collapsed.
Click to expand it.
m-consultant/src/main/java/com/yidianling/consultant/ExpertSearchFragment.kt
View file @
f09b9019
...
@@ -77,7 +77,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
...
@@ -77,7 +77,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
initData
()
initData
()
val
ffrom
=
PlatformDataManager
.
getRam
().
getChannelName
()
val
ffrom
=
PlatformDataManager
.
getRam
().
getChannelName
()
if
(!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
endsWith
(
"huawei"
))
{
if
(!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
startsWith
(
"ATK_7"
)
&&
ffrom
.
endsWith
(
"huawei"
))
{
rl_hot_fix_for_huawei
.
visibility
=
View
.
GONE
rl_hot_fix_for_huawei
.
visibility
=
View
.
GONE
}
else
{
}
else
{
rl_hot_fix_for_huawei
.
visibility
=
View
.
VISIBLE
rl_hot_fix_for_huawei
.
visibility
=
View
.
VISIBLE
...
...
This diff is collapsed.
Click to expand it.
m-consultant/src/main/java/com/yidianling/consultant/adapter/ExpertSearchAdapter.kt
View file @
f09b9019
...
@@ -15,6 +15,7 @@ import com.ydl.webview.NewH5Activity
...
@@ -15,6 +15,7 @@ import com.ydl.webview.NewH5Activity
import
com.ydl.ydl_image.config.SimpleImageOpConfiger
import
com.ydl.ydl_image.config.SimpleImageOpConfiger
import
com.ydl.ydl_image.module.GlideApp
import
com.ydl.ydl_image.module.GlideApp
import
com.ydl.ydlcommon.base.config.HttpConfig
import
com.ydl.ydlcommon.base.config.HttpConfig
import
com.ydl.ydlcommon.data.PlatformDataManager
import
com.ydl.ydlcommon.router.IYDLRouterConstant
import
com.ydl.ydlcommon.router.IYDLRouterConstant
import
com.ydl.ydlcommon.utils.BuryPointUtils
import
com.ydl.ydlcommon.utils.BuryPointUtils
import
com.ydl.ydlcommon.utils.URLUtils
import
com.ydl.ydlcommon.utils.URLUtils
...
@@ -50,6 +51,8 @@ class ExpertSearchAdapter(
...
@@ -50,6 +51,8 @@ class ExpertSearchAdapter(
const
val
EMPTY_VIEW
=
2
const
val
EMPTY_VIEW
=
2
}
}
private
val
ffrom
=
PlatformDataManager
.
getRam
().
getChannelName
()
//记录当前选择主题的id
//记录当前选择主题的id
var
cateId
:
String
?
=
null
var
cateId
:
String
?
=
null
...
@@ -66,6 +69,10 @@ class ExpertSearchAdapter(
...
@@ -66,6 +69,10 @@ class ExpertSearchAdapter(
@SuppressLint
(
"SetTextI18n"
)
@SuppressLint
(
"SetTextI18n"
)
override
fun
onBindViewHolder
(
holder
:
RecyclerView
.
ViewHolder
?,
position
:
Int
)
{
override
fun
onBindViewHolder
(
holder
:
RecyclerView
.
ViewHolder
?,
position
:
Int
)
{
if
(
holder
is
NormalViewHolder
)
{
if
(
holder
is
NormalViewHolder
)
{
val
isFromXinliZiXunHuawei
=
!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
startsWith
(
"ATK_7"
)
&&
ffrom
.
endsWith
(
"huawei"
)
val
itemBean
=
listData
[
position
]
val
itemBean
=
listData
[
position
]
//头像
//头像
val
headConfig
=
SimpleImageOpConfiger
()
val
headConfig
=
SimpleImageOpConfiger
()
...
@@ -283,6 +290,19 @@ class ExpertSearchAdapter(
...
@@ -283,6 +290,19 @@ class ExpertSearchAdapter(
}
}
}
}
}
}
if
(
isFromXinliZiXunHuawei
)
{
holder
.
ll_honor_layout
.
visibility
=
View
.
GONE
holder
.
ll_tags
.
visibility
=
View
.
GONE
holder
.
imgHead_online
.
visibility
=
View
.
GONE
holder
.
imgHead_online_server
.
visibility
=
View
.
GONE
holder
.
tvPrice
.
visibility
=
View
.
GONE
holder
.
tvPriceContent
.
visibility
=
View
.
GONE
holder
.
tvPriceContent
.
visibility
=
View
.
GONE
holder
.
tvChat
.
text
=
"咨询"
}
}
else
if
(
holder
is
FooterViewHolder
)
{
}
else
if
(
holder
is
FooterViewHolder
)
{
if
(
hasMore
)
{
if
(
hasMore
)
{
holder
.
itemView
.
visibility
=
View
.
VISIBLE
holder
.
itemView
.
visibility
=
View
.
VISIBLE
...
@@ -340,6 +360,8 @@ class ExpertSearchAdapter(
...
@@ -340,6 +360,8 @@ class ExpertSearchAdapter(
val
imgServiceFree
=
itemView
.
imgServiceFree
!!
val
imgServiceFree
=
itemView
.
imgServiceFree
!!
//新驻图标
//新驻图标
val
imgNewEnter
=
itemView
.
imgNewEnter
!!
val
imgNewEnter
=
itemView
.
imgNewEnter
!!
//荣誉标签
val
ll_honor_layout
=
itemView
.
ll_honor_layout
!!
//好评率
//好评率
val
ll_feedbackRate
=
itemView
.
ll_feedbackRate
!!
val
ll_feedbackRate
=
itemView
.
ll_feedbackRate
!!
//xxx人点评
//xxx人点评
...
...
This diff is collapsed.
Click to expand it.
m-consultant/src/main/res/layout/consultant_expert_search_item_view.xml
View file @
f09b9019
This diff is collapsed.
Click to expand it.
m-home/src/xlzx/java/com/yidianling/home/adapter/YdlHomeAdapter.kt
View file @
f09b9019
...
@@ -6,7 +6,7 @@ import android.text.TextUtils
...
@@ -6,7 +6,7 @@ import android.text.TextUtils
import
android.view.LayoutInflater
import
android.view.LayoutInflater
import
android.view.View
import
android.view.View
import
android.view.ViewGroup
import
android.view.ViewGroup
import
com.ydl.ydlcommon.data.PlatformDataManager
.getRam
import
com.ydl.ydlcommon.data.PlatformDataManager
import
com.yidianling.home.R
import
com.yidianling.home.R
import
com.yidianling.home.constract.YdlHomeViewHolderConstract
import
com.yidianling.home.constract.YdlHomeViewHolderConstract
import
com.yidianling.home.event.HomeImpl
import
com.yidianling.home.event.HomeImpl
...
@@ -29,6 +29,7 @@ class YdlHomeAdapter(
...
@@ -29,6 +29,7 @@ class YdlHomeAdapter(
private
var
list
:
ArrayList
<
HomePagerDataBean
>
private
var
list
:
ArrayList
<
HomePagerDataBean
>
)
:
RecyclerView
.
Adapter
<
RecyclerView
.
ViewHolder
>()
{
)
:
RecyclerView
.
Adapter
<
RecyclerView
.
ViewHolder
>()
{
private
val
ffrom
=
PlatformDataManager
.
getRam
().
getChannelName
()
private
val
mInflater
:
LayoutInflater
=
LayoutInflater
.
from
(
mContext
)
private
val
mInflater
:
LayoutInflater
=
LayoutInflater
.
from
(
mContext
)
/**
/**
* 倾述item的position
* 倾述item的position
...
@@ -151,21 +152,31 @@ class YdlHomeAdapter(
...
@@ -151,21 +152,31 @@ class YdlHomeAdapter(
}
}
//倾诉*排解模块
//倾诉*排解模块
is
HomeConfideViewHolder
->
{
is
HomeConfideViewHolder
->
{
holder
.
confideViewView
.
setTitle
(
if
(!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
endsWith
(
"huawei"
))
{
list
[
position
].
headerBean
?.
listenCategoryDate
,
val
parm
=
holder
.
itemView
.
layoutParams
confideSelectPosition
parm
.
height
=
0
)
holder
.
itemView
.
layoutParams
=
parm
holder
.
confideViewView
.
setConfideExpertInfoView
(
list
[
position
].
confideBean
?.
body
)
}
else
{
confidePosition
=
position
holder
.
confideViewView
.
setTitle
(
list
[
position
].
headerBean
?.
listenCategoryDate
,
confideSelectPosition
)
holder
.
confideViewView
.
setConfideExpertInfoView
(
list
[
position
].
confideBean
?.
body
)
confidePosition
=
position
}
}
}
//课程*成长模块
//课程*成长模块
is
HomeCourseViewHolder
->
{
is
HomeCourseViewHolder
->
{
holder
.
courseViewView
.
initData
(
list
[
position
].
courseBean
?.
list
)
if
(!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
endsWith
(
"huawei"
))
{
val
parm
=
holder
.
itemView
.
layoutParams
parm
.
height
=
0
holder
.
itemView
.
layoutParams
=
parm
}
else
{
holder
.
courseViewView
.
initData
(
list
[
position
].
courseBean
?.
list
)
}
}
}
//解忧*问答模块
//解忧*问答模块
is
HomeAssuageGriefViewHolder
->
{
is
HomeAssuageGriefViewHolder
->
{
val
ffrom
=
getRam
().
getChannelName
()
if
(!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
endsWith
(
"huawei"
))
{
if
(!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
endsWith
(
"huawei"
))
{
val
parm
=
holder
.
itemView
.
layoutParams
val
parm
=
holder
.
itemView
.
layoutParams
parm
.
height
=
0
parm
.
height
=
0
...
@@ -180,15 +191,22 @@ class YdlHomeAdapter(
...
@@ -180,15 +191,22 @@ class YdlHomeAdapter(
}
}
//咨询模块
//咨询模块
is
HomeConsultViewHolder
->
{
is
HomeConsultViewHolder
->
{
holder
.
consultView
.
setTitle
(
if
(!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
endsWith
(
"huawei"
))
{
list
[
position
].
headerBean
?.
consultCategoryData
,
val
parm
=
holder
.
itemView
.
layoutParams
consultSelectPosition
parm
.
height
=
0
)
holder
.
itemView
.
layoutParams
=
parm
holder
.
consultView
.
setConsultInfoView
(
}
else
{
list
[
position
].
consultBean
?.
list
,
list
[
position
].
headerBean
?.
consultCategoryData
?.
get
(
consultSelectPosition
)
holder
.
consultView
.
setTitle
(
)
list
[
position
].
headerBean
?.
consultCategoryData
,
consultPosition
=
position
consultSelectPosition
)
holder
.
consultView
.
setConsultInfoView
(
list
[
position
].
consultBean
?.
list
,
list
[
position
].
headerBean
?.
consultCategoryData
?.
get
(
consultSelectPosition
)
)
consultPosition
=
position
}
}
}
//测试模块
//测试模块
is
HomeTestViewHolder
->
{
is
HomeTestViewHolder
->
{
...
...
This diff is collapsed.
Click to expand it.
m-home/src/xlzx/java/com/yidianling/home/ui/view/HomeButtonBannerView.kt
View file @
f09b9019
...
@@ -61,6 +61,9 @@ class HomeButtonBannerView(private val mContext: Context, private var homeEvent:
...
@@ -61,6 +61,9 @@ class HomeButtonBannerView(private val mContext: Context, private var homeEvent:
val
ffrom
=
PlatformDataManager
.
getRam
().
getChannelName
()
val
ffrom
=
PlatformDataManager
.
getRam
().
getChannelName
()
if
(!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
endsWith
(
"huawei"
))
{
if
(!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
endsWith
(
"huawei"
))
{
homeModuleButtonBannerThird
.
visibility
=
View
.
GONE
homeModuleButtonBannerSecond
.
visibility
=
View
.
GONE
homeModuleButtonBannerFirst
.
background
=
homeModuleButtonBannerFirst
.
background
=
resources
.
getDrawable
(
R
.
drawable
.
home_dcotor_bt_bg_huawei
)
resources
.
getDrawable
(
R
.
drawable
.
home_dcotor_bt_bg_huawei
)
homeModuleButtonBannerSecond
.
background
=
homeModuleButtonBannerSecond
.
background
=
...
@@ -101,8 +104,15 @@ class HomeButtonBannerView(private val mContext: Context, private var homeEvent:
...
@@ -101,8 +104,15 @@ class HomeButtonBannerView(private val mContext: Context, private var homeEvent:
homeCategory
:
List
<
HomeHeaderBean
.
AskCategoryDataBean
>?
homeCategory
:
List
<
HomeHeaderBean
.
AskCategoryDataBean
>?
)
{
)
{
setRealTextView
(
homeSaleData
)
setRealTextView
(
homeSaleData
)
homeEvent
?.
let
{
home_category_view
.
setEvent
(
it
)
};
home_category_view
.
initData
(
homeCategory
)
val
ffrom
=
PlatformDataManager
.
getRam
().
getChannelName
()
if
(!
TextUtils
.
isEmpty
(
ffrom
)
&&
ffrom
.
endsWith
(
"huawei"
))
{
home_category_view
.
visibility
=
View
.
GONE
}
else
{
homeEvent
?.
let
{
home_category_view
.
setEvent
(
it
)
}
home_category_view
.
initData
(
homeCategory
)
}
}
}
/**
/**
...
...
This diff is collapsed.
Click to expand it.
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