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
cc3b6d32
Commit
cc3b6d32
authored
Jun 07, 2022
by
upwork.021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 主题弹窗优化,ui验收优化,bug修复
parent
2e5b358b
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
573 additions
and
373 deletions
+573
-373
config.gradle
config.gradle
+2
-2
ExpertSearchActivity.kt
m-consultant/src/main/java/com/yidianling/consultant/ExpertSearchActivity.kt
+162
-105
ExpertSearchFragment.kt
m-consultant/src/main/java/com/yidianling/consultant/ExpertSearchFragment.kt
+134
-94
HotSearchActivity.kt
m-consultant/src/main/java/com/yidianling/consultant/HotSearchActivity.kt
+42
-15
ExpertSearchAdapter.kt
m-consultant/src/main/java/com/yidianling/consultant/adapter/ExpertSearchAdapter.kt
+29
-6
SearchWordsBean.kt
m-consultant/src/main/java/com/yidianling/consultant/bean/SearchWordsBean.kt
+1
-1
ConsultBIConstants.kt
m-consultant/src/main/java/com/yidianling/consultant/constants/ConsultBIConstants.kt
+4
-2
ConsultAssistantDialogUtils.kt
m-consultant/src/main/java/com/yidianling/consultant/modular/singlton/ConsultAssistantDialogUtils.kt
+3
-3
CategoryPopupWindow.kt
m-consultant/src/main/java/com/yidianling/consultant/ui/view/CategoryPopupWindow.kt
+57
-0
FilterPopupWindow.kt
m-consultant/src/main/java/com/yidianling/consultant/ui/view/FilterPopupWindow.kt
+4
-8
consultant_ui_subject_popup_window.xml
m-consultant/src/main/res/layout/consultant_ui_subject_popup_window.xml
+135
-137
No files found.
config.gradle
View file @
cc3b6d32
...
...
@@ -6,7 +6,7 @@ ext {
// -------------- 业务模块 --------------
//第三步 若干
"m-confide"
:
"0.0.49.72"
,
"m-consultant"
:
"0.0.60.
45
"
,
"m-consultant"
:
"0.0.60.
56
"
,
"m-fm"
:
"0.0.30.08"
,
"m-user"
:
"0.0.62.04"
,
"m-home"
:
"0.0.23.80"
,
...
...
@@ -92,7 +92,7 @@ ext {
//第三步 若干
"m-confide"
:
"0.0.49.72"
,
"m-consultant"
:
"0.0.60.
44
"
,
"m-consultant"
:
"0.0.60.
56
"
,
"m-fm"
:
"0.0.30.08"
,
"m-user"
:
"0.0.62.04"
,
"m-home"
:
"0.0.23.41"
,
...
...
m-consultant/src/main/java/com/yidianling/consultant/ExpertSearchActivity.kt
View file @
cc3b6d32
...
...
@@ -91,7 +91,7 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
override
fun
initDataAndEvent
()
{
window
.
setSoftInputMode
(
WindowManager
.
LayoutParams
.
SOFT_INPUT_ADJUST_RESIZE
or
WindowManager
.
LayoutParams
.
SOFT_INPUT_STATE_HIDDEN
)
initViews
()
initData
(
intent
,
false
)
initData
(
intent
,
false
)
rl_hot_fix_for_huawei
.
visibility
=
View
.
VISIBLE
}
...
...
@@ -109,6 +109,7 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
private
const
val
EXTRA_IS_SHOW_HOT
=
"isInitShowHot"
private
const
val
EXTRA_SEARCH_WORD
=
"searchWord"
private
const
val
EXTRA_RELATED_WORD
=
"related_word"
private
const
val
EXTRA_IS_RECCOMMEND_WORD
=
"is_reccommend_word"
private
const
val
EXTRA_IS_FROM_SPLASH
=
"isFromSplash"
private
const
val
FILTER_STATUS_NORMAL
=
0
//默认筛选状态
private
const
val
FILTER_STATUS_FILTERED
=
1
//非默认筛选状态
...
...
@@ -149,12 +150,20 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
* 搜索页面过来的
* @param sign2为14 仅用于埋点
* @param relatedWord 搜索内容的关联词
* @param isRecommendWords 是否是推荐词
*/
fun
startSearch
(
context
:
Context
,
searchWord
:
String
?,
sign2
:
String
,
relatedWord
:
String
)
{
fun
startSearch
(
context
:
Context
,
searchWord
:
String
?,
sign2
:
String
,
relatedWord
:
String
,
isRecommendWords
:
Boolean
)
{
val
intent
=
Intent
(
context
,
ExpertSearchActivity
::
class
.
java
)
intent
.
putExtra
(
EXTRA_SEARCH_WORD
,
searchWord
)
intent
.
putExtra
(
EXTRA_RELATED_WORD
,
relatedWord
)
intent
.
putExtra
(
"sign2"
,
sign2
)
intent
.
putExtra
(
EXTRA_IS_RECCOMMEND_WORD
,
isRecommendWords
)
intent
.
putExtra
(
"sign2"
,
sign2
)
context
.
startActivity
(
intent
)
}
...
...
@@ -236,7 +245,7 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
val
layoutManager
=
LinearLayoutManager
(
this
,
LinearLayoutManager
.
VERTICAL
,
false
)
rvExperts
.
layoutManager
=
layoutManager
rvExperts
.
adapter
=
doctorAdapter
doctorAdapter
.
setOnClickLister
(
object
:
ExpertSearchAdapter
.
OnClickLister
{
doctorAdapter
.
setOnClickLister
(
object
:
ExpertSearchAdapter
.
OnClickLister
{
override
fun
onClick
(
searchWords
:
String
)
{
allFilter
.
searchWord
=
searchWords
...
...
@@ -372,49 +381,64 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
}
}
private
fun
initData
(
mIntent
:
Intent
,
isRefresh
:
Boolean
)
{
private
fun
initData
(
mIntent
:
Intent
,
isRefresh
:
Boolean
)
{
fromPageType
=
mIntent
.
getIntExtra
(
EXTRA_FROM_PAGE
,
-
1
)
initCategory
=
mIntent
.
getStringExtra
(
EXTRA_CATEGORY
)
?:
""
initShowType
=
mIntent
.
getIntExtra
(
EXTRA_SHOW_TYPE
,
0
)
val
relatedWord
=
mIntent
.
getStringExtra
(
EXTRA_RELATED_WORD
)
// 搜索内容的联想词
val
searchWord
=
mIntent
.
getStringExtra
(
EXTRA_SEARCH_WORD
)
if
(!
TextUtils
.
isEmpty
(
relatedWord
)){
// 判断搜索内容的联想词为空,则用搜索词进行搜索
val
isRecommendWords
=
mIntent
.
getBooleanExtra
(
EXTRA_IS_RECCOMMEND_WORD
,
false
)
if
(!
TextUtils
.
isEmpty
(
relatedWord
))
{
// 判断搜索内容的联想词为空,则用搜索词进行搜索
allFilter
.
searchWord
=
relatedWord
}
else
{
}
else
{
allFilter
.
searchWord
=
searchWord
}
mSign2
=
mIntent
.
getStringExtra
(
"sign2"
)
?:
""
mSign2
=
mIntent
.
getStringExtra
(
"sign2"
)
?:
""
getRouterParam
()
allFilter
.
showType
.
key
=
initShowType
if
(!
TextUtils
.
isEmpty
(
initCategory
)){
if
(!
TextUtils
.
isEmpty
(
initCategory
))
{
allFilter
.
categoryId2List
.
add
(
initCategory
)
}
if
(!
TextUtils
.
isEmpty
(
cateName
)){
if
(!
TextUtils
.
isEmpty
(
cateName
))
{
tvSubject
.
text
=
cateName
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_FILTERED
)
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_FILTERED
)
}
getPresenter
().
fetchListHead
()
if
(
isRefresh
){
if
(
isRefresh
)
{
refresh
(
false
)
}
tv_search_content
.
text
=
searchWord
// 判断搜索词和联想词不一样,则显示匹配结果
if
(!
TextUtils
.
isEmpty
(
searchWord
)&&!
TextUtils
.
isEmpty
(
relatedWord
)&&
searchWord
!=
relatedWord
){
doctorList
.
add
(
ExpertServiceItem
(
true
,
searchWord
,
relatedWord
))
LogUtil
.
e
(
"searchWord:${searchWord}"
)
LogUtil
.
e
(
"relatedWord:${relatedWord}"
)
if
(!
TextUtils
.
isEmpty
(
searchWord
)
&&
!
TextUtils
.
isEmpty
(
relatedWord
)
&&
searchWord
!=
relatedWord
)
{
if
(
doctorList
.
size
>
0
&&
doctorList
[
0
].
is_head_view
)
{
doctorList
[
0
]
=
ExpertServiceItem
(
true
,
searchWord
,
relatedWord
)
}
else
if
(
doctorList
.
size
>
0
)
{
doctorList
.
add
(
0
,
ExpertServiceItem
(
true
,
searchWord
,
relatedWord
))
}
else
{
doctorList
.
add
(
ExpertServiceItem
(
true
,
searchWord
,
relatedWord
))
}
}
else
{
if
(
doctorList
.
size
>
0
&&
doctorList
[
0
].
is_head_view
)
{
doctorList
.
removeAt
(
0
)
}
}
v_loading
.
visibility
=
View
.
VISIBLE
v_loading
.
setViewType
(
LogoLoadingView
.
TYPE_LOADING
,
null
)
doctorAdapter
.
clickCount
=
0
doctorAdapter
.
setIsRecommendWords
(
isRecommendWords
)
doctorAdapter
.
setEntrance
(
1
)
}
override
fun
onNewIntent
(
intent
:
Intent
?)
{
super
.
onNewIntent
(
intent
)
initData
(
intent
!!
,
true
)
initData
(
intent
!!
,
true
)
}
...
...
@@ -438,44 +462,52 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
//设置热门搜索
initHotViews
(
lin_filter2
,
it
.
highlighter
)
}
it
.
cates
[
0
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
0
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
childList
.
add
(
childrenBean
)
}
it
.
cates
[
1
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
1
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
stressList
.
add
(
childrenBean
)
}
it
.
cates
[
2
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
2
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
loveEmotionList
.
add
(
childrenBean
)
}
it
.
cates
[
3
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
3
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
marriedFamilyList
.
add
(
childrenBean
)
}
it
.
cates
[
4
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
4
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
personalGrowthList
.
add
(
childrenBean
)
}
it
.
cates
[
5
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
5
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
interpersonalRelationshipList
.
add
(
childrenBean
)
}
it
.
cates
[
6
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
6
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
careerDevelopmentList
.
add
(
childrenBean
)
}
it
.
cates
[
7
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
7
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
mentalHealthList
.
add
(
childrenBean
)
}
}
...
...
@@ -508,8 +540,13 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
textView
.
isSelected
=
true
textView
.
paint
.
isFakeBoldText
=
true
// 埋点
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_CHOICE_FILTER_CLICK
,
hot
.
value
!!
,
"app"
,
""
)
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_CHOICE_FILTER_CLICK
,
hot
.
value
!!
,
"app"
,
""
)
}
filterLabelSet
()
//开始筛选数据
...
...
@@ -797,33 +834,37 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
/**
* 获取专家列表数据
*/
override
fun
onDoctorListFetched
(
data
:
MutableList
<
ExpertServiceItem
>,
extras
:
Extras
?,
curPage
:
Int
)
{
override
fun
onDoctorListFetched
(
data
:
MutableList
<
ExpertServiceItem
>,
extras
:
Extras
?,
curPage
:
Int
)
{
if
(
rvExperts
.
adapter
!=
doctorAdapter
)
{
rvExperts
.
adapter
=
doctorAdapter
}
// 如果是第一页
if
(
curPage
==
1
)
{
if
(
data
.
size
>=
10
)
{
if
(
curPage
==
1
)
{
if
(
data
.
size
>=
10
)
{
hasMore
=
true
doctorAdapter
.
hasMore
=
true
}
else
{
}
else
{
hasMore
=
false
doctorAdapter
.
hasMore
=
false
}
if
(
doctorList
.
size
>
0
)
{
if
(
doctorList
.
size
>
0
&&
doctorList
[
0
].
is_head_view
)
{
val
expertServiceItem
=
doctorList
[
0
]
doctorList
.
clear
()
doctorList
.
add
(
expertServiceItem
)
}
else
{
}
else
{
doctorList
.
clear
()
}
}
if
(
data
.
size
==
0
)
{
// data的长度为0的时候为最后一页
if
(
data
.
size
==
0
)
{
// data的长度为0的时候为最后一页
hasMore
=
false
doctorAdapter
.
hasMore
=
false
}
else
{
}
else
{
doctorList
.
addAll
(
data
)
}
doctorAdapter
.
notifyDataSetChanged
()
...
...
@@ -838,8 +879,14 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
srlContainer
.
isRefreshing
=
false
// 埋点
val
sign1
=
data
.
joinToString
(
","
){
it
.
id
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
POSITION_CONSULT_COUNSELOR_LIST_PAGE_VISIT
,
sign1
,
mSign2
,
"app"
)
val
sign1
=
data
.
joinToString
(
","
)
{
it
.
id
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
POSITION_CONSULT_COUNSELOR_LIST_PAGE_VISIT
,
sign1
,
mSign2
,
"app"
)
}
override
fun
fetchListFailed
(
msg
:
String
?)
{
...
...
@@ -865,23 +912,26 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
isDoSearch
=
false
isRecommend
=
false
if
(
doctorList
.
size
==
0
||
doctorList
.
size
>
0
&&
TextUtils
.
isEmpty
(
doctorList
[
0
].
related_word
))
{
tv_reload
.
visibility
=
View
.
GONE
tv_reload_hint
.
text
=
msg
ll_network_error
.
visibility
=
View
.
VISIBLE
iv_exception
.
setImageResource
(
R
.
drawable
.
platform_ico_img_zixun_empty
)
if
(
doctorList
.
size
>
0
&&
doctorList
[
0
].
is_head_view
)
{
val
expertServiceItem
=
doctorList
[
0
]
doctorList
.
clear
()
doctorList
.
add
(
expertServiceItem
)
doctorAdapter
.
notifyDataSetChanged
(
)
rvExperts
.
visibility
=
View
.
GONE
dismissProgressDialog
()
srlContainer
.
isRefreshing
=
false
}
else
{
doctorAdapter
.
notifyDataSetChanged
()
v_loading
.
visibility
=
View
.
GONE
ll_network_error
.
visibility
=
View
.
GONE
v_loading
.
visibility
=
View
.
GONE
ll_network_error
.
visibility
=
View
.
GONE
rvExperts
.
visibility
=
View
.
VISIBLE
}
rvExperts
.
visibility
=
View
.
VISIBLE
}
else
{
tv_reload
.
visibility
=
View
.
GONE
tv_reload_hint
.
text
=
msg
ll_network_error
.
visibility
=
View
.
VISIBLE
iv_exception
.
setImageResource
(
R
.
drawable
.
platform_ico_img_zixun_empty
)
rvExperts
.
visibility
=
View
.
GONE
dismissProgressDialog
()
srlContainer
.
isRefreshing
=
false
}
}
...
...
@@ -1035,25 +1085,33 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
//筛选确认回调
override
fun
onFilterConfirmed
()
{
updateFilterTextViewStatus
(
tvFilter
,
FILTER_STATUS_OPEN
)
LogUtil
.
d
(
"filter: "
+
tempFilter
.
showType
.
value
+
","
+
tempFilter
.
enquiries
.
map
{
it
.
value
}.
joinToString
(
","
)
+
","
+
tempFilter
.
ages
.
map
{
it
.
value
}.
joinToString
(
","
)
+
","
+
tempFilter
.
others
.
map
{
it
.
value
}.
joinToString
(
","
)+
","
+
tempFilter
.
doctorEdu
.
map
{
it
.
value
}.
joinToString
(
","
))
LogUtil
.
d
(
"filter: "
+
tempFilter
.
showType
.
value
+
","
+
tempFilter
.
enquiries
.
map
{
it
.
value
}.
joinToString
(
","
)
+
","
+
tempFilter
.
ages
.
map
{
it
.
value
}.
joinToString
(
","
)
+
","
+
tempFilter
.
others
.
map
{
it
.
value
}.
joinToString
(
","
)
+
","
+
tempFilter
.
doctorEdu
.
map
{
it
.
value
}.
joinToString
(
","
)
)
props1
.
put
(
"filtrate_second"
,
tempFilter
.
showType
.
value
+
","
+
tempFilter
.
enquiries
.
map
{
it
.
value
}.
joinToString
(
","
)
+
","
+
tempFilter
.
ages
.
map
{
it
.
value
}.
joinToString
(
","
)
+
","
+
tempFilter
.
others
.
map
{
it
.
value
}.
joinToString
(
","
)
+
","
+
tempFilter
.
others
.
map
{
it
.
value
}.
joinToString
(
","
)
+
","
+
tempFilter
.
doctorEdu
.
map
{
it
.
value
}.
joinToString
(
","
)
)
BuryPointUtils
.
buryPoint
(
"Filtrate"
,
props1
)
// 埋点
if
(
tempFilter
.
specialityCrowd
.
size
>
0
){
val
sign1
=
tempFilter
.
specialityCrowd
.
joinToString
(
","
){
it
.
value
!!
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_FILTER_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_GOODAT_CROWD_CLICK
,
sign1
,
"app"
,
""
)
if
(
tempFilter
.
specialityCrowd
.
size
>
0
)
{
val
sign1
=
tempFilter
.
specialityCrowd
.
joinToString
(
","
)
{
it
.
value
!!
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_FILTER_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_GOODAT_CROWD_CLICK
,
sign1
,
"app"
,
""
)
}
...
...
@@ -1364,33 +1422,26 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
}
}
private
var
categoryPopup
:
CategoryPopupWindow
?
=
null
private
var
mHandler
:
Handler
?=
null
private
var
mHandler
:
Handler
?
=
null
/**
* 显示主题弹窗
*/
private
fun
showSubjectPopupWindow
()
{
if
(
categoryPopup
==
null
)
{
categoryPopup
=
CategoryPopupWindow
(
this
,
allFilter
)
mHandler
=
Handler
()
mHandler
!!
.
post
{
categoryPopup
!!
.
updateData
()
}
categoryPopup
!!
.
setOnDismissListener
{
viewDim
.
visibility
=
View
.
INVISIBLE
ConsultAssistantDialogUtils
.
INSTANCE
.
fitRequest
(
this
,
"doctor_list"
,
true
)
}
ConsultAssistantDialogUtils
.
INSTANCE
.
hideAssistantActivity
()
categoryPopup
!!
.
onSubjectsSelectedListener
=
this
categoryPopup
!!
.
showAsDropDown
(
viewSep2
)
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_OPEN
)
viewDim
.
visibility
=
View
.
VISIBLE
}
else
{
ConsultAssistantDialogUtils
.
INSTANCE
.
hideAssistantActivity
()
categoryPopup
!!
.
showAsDropDown
(
viewSep2
)
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_OPEN
)
viewDim
.
visibility
=
View
.
VISIBLE
val
categoryPopup
=
CategoryPopupWindow
(
this
,
allFilter
)
mHandler
=
Handler
()
mHandler
!!
.
post
{
categoryPopup
.
updateData
()
}
categoryPopup
.
setOnDismissListener
{
viewDim
.
visibility
=
View
.
INVISIBLE
ConsultAssistantDialogUtils
.
INSTANCE
.
fitRequest
(
this
,
"doctor_list"
,
true
)
}
ConsultAssistantDialogUtils
.
INSTANCE
.
hideAssistantActivity
()
categoryPopup
.
onSubjectsSelectedListener
=
this
categoryPopup
.
showAsDropDown
(
viewSep2
)
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_OPEN
)
viewDim
.
visibility
=
View
.
VISIBLE
}
/**
...
...
@@ -1398,15 +1449,21 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
*
* 新增逻辑:当主题选择后,需要判断热门筛选中是否也有该主题,如果有,也需要同步更新选中状态
*/
override
fun
onCategoriesSelected
(
signLit
:
ArrayList
<
String
>)
{
if
(
signLit
.
isNotEmpty
()){
val
sign1
=
signLit
.
joinToString
(
","
){
it
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_TWO_CATEGORY_CLICK
,
sign1
,
"app"
,
""
)
override
fun
onCategoriesSelected
(
signLit
:
ArrayList
<
String
>)
{
if
(
signLit
.
isNotEmpty
())
{
val
sign1
=
signLit
.
joinToString
(
","
)
{
it
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_TWO_CATEGORY_CLICK
,
sign1
,
"app"
,
""
)
}
if
(
allFilter
.
categoryId2List
.
size
>
0
||
allFilter
.
categoryId3List
.
size
>
0
)
{
if
(
allFilter
.
categoryId2List
.
size
>
0
||
allFilter
.
categoryId3List
.
size
>
0
)
{
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_FILTERED
)
}
else
{
}
else
{
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_NORMAL
)
}
refresh
()
...
...
@@ -1421,7 +1478,7 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
private
fun
refresh
(
isShowRefresh
:
Boolean
?
=
true
)
{
srlContainer
.
isRefreshing
=
isShowRefresh
!!
onScrollListener
.
resetState
()
getPresenter
().
mExtras
=
null
getPresenter
().
mExtras
=
null
getPresenter
().
fetchListData
(
allFilter
,
getPresenter
().
mExtras
)
rvExperts
.
scrollToPosition
(
0
)
}
...
...
@@ -1503,7 +1560,7 @@ class ExpertSearchActivity : BaseMvpActivity<IExpertSearchView, ExpertSearchPres
override
fun
onDestroy
()
{
super
.
onDestroy
()
mHandler
=
null
mHandler
=
null
ConsultAssistantDialogUtils
.
INSTANCE
.
expertSearchResetStatus
()
}
}
m-consultant/src/main/java/com/yidianling/consultant/ExpertSearchFragment.kt
View file @
cc3b6d32
...
...
@@ -62,14 +62,15 @@ import org.json.JSONObject
import
java.util.concurrent.Executors
@Route
(
path
=
"/consultant/consultant"
)
class
ExpertSearchFragment
:
BaseMvpFragment
<
IExpertSearchView
,
ExpertSearchPresenter
>(),
View
.
OnClickListener
,
IExpertSearchView
,
class
ExpertSearchFragment
:
BaseMvpFragment
<
IExpertSearchView
,
ExpertSearchPresenter
>(),
View
.
OnClickListener
,
IExpertSearchView
,
OnCategoriesSelectedListener
,
OnSortItemSelectedListener
,
OnFilterConfirmListener
,
SwipeRefreshLayout
.
OnRefreshListener
{
private
lateinit
var
mContext
:
Context
private
lateinit
var
mActivity
:
FragmentActivity
var
startTime
=
0L
var
endTime
=
0L
private
var
mIdssign1
:
String
=
""
// 列表埋点咨询师列表id拼接参数
var
startTime
=
0L
var
endTime
=
0L
private
var
mIdssign1
:
String
=
""
// 列表埋点咨询师列表id拼接参数
override
fun
layoutResId
():
Int
{
return
R
.
layout
.
consultant_activity_expert_search_list
...
...
@@ -286,15 +287,18 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
override
fun
setUserVisibleHint
(
isVisibleToUser
:
Boolean
)
{
super
.
setUserVisibleHint
(
isVisibleToUser
)
if
(
isVisibleToUser
&&
isResumed
)
{
startTime
=
System
.
currentTimeMillis
()
startTime
=
System
.
currentTimeMillis
()
showConsultAssistantDialog
()
}
else
{
hideConsultAssistantDialog
()
if
(
startTime
!=
0L
){
endTime
=
System
.
currentTimeMillis
()
ActionCountUtils
.
count
(
ConsultBIConstants
.
ConsultEvent
.
YDL_USER_CONSULT_PAGE_STAY_VISIT
,(
endTime
-
startTime
).
toString
())
if
(
startTime
!=
0L
)
{
endTime
=
System
.
currentTimeMillis
()
ActionCountUtils
.
count
(
ConsultBIConstants
.
ConsultEvent
.
YDL_USER_CONSULT_PAGE_STAY_VISIT
,
(
endTime
-
startTime
).
toString
()
)
}
}
}
if
(
isVisibleToUser
&&
isResumed
)
{
onResume
()
}
...
...
@@ -352,44 +356,52 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
//设置热门搜索
initHotViews
(
lin_filter2
,
it
.
highlighter
)
}
it
.
cates
[
0
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
0
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
childList
.
add
(
childrenBean
)
}
it
.
cates
[
1
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
1
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
stressList
.
add
(
childrenBean
)
}
it
.
cates
[
2
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
2
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
loveEmotionList
.
add
(
childrenBean
)
}
it
.
cates
[
3
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
3
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
marriedFamilyList
.
add
(
childrenBean
)
}
it
.
cates
[
4
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
4
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
personalGrowthList
.
add
(
childrenBean
)
}
it
.
cates
[
5
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
5
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
interpersonalRelationshipList
.
add
(
childrenBean
)
}
it
.
cates
[
6
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
6
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
careerDevelopmentList
.
add
(
childrenBean
)
}
it
.
cates
[
7
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
it
.
cates
[
7
].
children
?.
forEachIndexed
{
index
,
children
->
val
type
=
if
(
children
.
cate_name
.
length
>
4
)
2
else
1
val
childrenBean
=
ChildrenBean
(
children
.
cate_name
,
children
.
cate_id
,
index
<=
12
,
type
)
allFilter
.
mentalHealthList
.
add
(
childrenBean
)
}
}
...
...
@@ -421,8 +433,13 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
textView
.
isSelected
=
true
textView
.
paint
.
isFakeBoldText
=
true
// 埋点
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_CHOICE_FILTER_CLICK
,
hot
.
value
!!
,
"app"
,
""
)
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_CHOICE_FILTER_CLICK
,
hot
.
value
!!
,
"app"
,
""
)
}
filterLabelSet
()
//开始筛选数据
...
...
@@ -564,7 +581,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
}
}
}
if
(
allFilter
.
others
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
doctorEdu
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
>
0
)
{
if
(
allFilter
.
others
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
doctorEdu
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
>
0
)
{
updateFilterTextViewStatus
(
tvFilter
,
FILTER_STATUS_FILTERED
)
}
else
{
updateFilterTextViewStatus
(
tvFilter
,
FILTER_STATUS_NORMAL
)
...
...
@@ -584,7 +601,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
}
}
}
if
(
allFilter
.
others
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
>
0
)
{
if
(
allFilter
.
others
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
>
0
)
{
updateFilterTextViewStatus
(
tvFilter
,
FILTER_STATUS_FILTERED
)
}
else
{
updateFilterTextViewStatus
(
tvFilter
,
FILTER_STATUS_NORMAL
)
...
...
@@ -604,7 +621,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
}
}
}
if
(
allFilter
.
others
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
>
0
)
{
if
(
allFilter
.
others
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
>
0
)
{
updateFilterTextViewStatus
(
tvFilter
,
FILTER_STATUS_FILTERED
)
}
else
{
updateFilterTextViewStatus
(
tvFilter
,
FILTER_STATUS_NORMAL
)
...
...
@@ -624,7 +641,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
}
}
}
if
(
allFilter
.
others
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
>
0
)
{
if
(
allFilter
.
others
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
>
0
)
{
updateFilterTextViewStatus
(
tvFilter
,
FILTER_STATUS_FILTERED
)
}
else
{
updateFilterTextViewStatus
(
tvFilter
,
FILTER_STATUS_NORMAL
)
...
...
@@ -708,30 +725,32 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
/**
* 获取专家列表数据
*/
override
fun
onDoctorListFetched
(
data
:
MutableList
<
ExpertServiceItem
>,
extras
:
Extras
?,
curPage
:
Int
)
{
override
fun
onDoctorListFetched
(
data
:
MutableList
<
ExpertServiceItem
>,
extras
:
Extras
?,
curPage
:
Int
)
{
if
(
rvExperts
.
adapter
!=
doctorAdapter
)
{
rvExperts
.
adapter
=
doctorAdapter
}
LogUtil
.
d
(
"data size "
+
data
.
size
)
// 如果是第一页
if
(
curPage
==
1
)
{
if
(
data
.
size
>=
10
)
{
if
(
curPage
==
1
)
{
if
(
data
.
size
>=
10
)
{
hasMore
=
true
doctorAdapter
.
hasMore
=
true
}
else
{
}
else
{
hasMore
=
false
doctorAdapter
.
hasMore
=
false
}
doctorList
.
clear
()
// 加入头部数据并隐藏,否则点击事件position会错乱
doctorList
.
add
(
ExpertServiceItem
(
false
,
""
,
""
))
}
if
(
data
.
size
==
0
)
{
// data的长度为0的时候为最后一页
if
(
data
.
size
==
0
)
{
// data的长度为0的时候为最后一页
hasMore
=
false
doctorAdapter
.
hasMore
=
false
}
else
{
}
else
{
doctorList
.
addAll
(
data
)
}
doctorAdapter
.
notifyDataSetChanged
()
...
...
@@ -746,8 +765,14 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
srlContainer
.
isRefreshing
=
false
// 埋点
mIdssign1
=
data
.
joinToString
(
","
){
it
.
id
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
POSITION_CONSULT_COUNSELOR_LIST_PAGE_VISIT
,
mIdssign1
,
sign2
,
"app"
)
mIdssign1
=
data
.
joinToString
(
","
)
{
it
.
id
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
POSITION_CONSULT_COUNSELOR_LIST_PAGE_VISIT
,
mIdssign1
,
sign2
,
"app"
)
}
override
fun
fetchListFailed
(
msg
:
String
?)
{
...
...
@@ -904,7 +929,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
filterPopupWindow
.
setOnDismissListener
{
viewDim
.
visibility
=
View
.
INVISIBLE
viewDim_filter
.
visibility
=
View
.
GONE
if
(
allFilter
.
others
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
doctorEdu
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
>
0
||
!
TextUtils
.
isEmpty
(
if
(
allFilter
.
others
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
doctorEdu
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
>
0
||
!
TextUtils
.
isEmpty
(
allFilter
.
priceRanges
?.
minPrice
)
||
!
TextUtils
.
isEmpty
(
allFilter
.
priceRanges
?.
maxPrice
)
)
{
...
...
@@ -941,9 +966,15 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
BuryPointUtils
.
buryPoint
(
"Filtrate"
,
props1
)
// 埋点
if
(
tempFilter
.
specialityCrowd
.
size
>
0
){
val
sign1
=
tempFilter
.
specialityCrowd
.
joinToString
(
","
){
it
.
value
!!
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_FILTER_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_GOODAT_CROWD_CLICK
,
sign1
,
"app"
,
""
)
if
(
tempFilter
.
specialityCrowd
.
size
>
0
)
{
val
sign1
=
tempFilter
.
specialityCrowd
.
joinToString
(
","
)
{
it
.
value
!!
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_FILTER_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_GOODAT_CROWD_CLICK
,
sign1
,
"app"
,
""
)
}
...
...
@@ -1062,7 +1093,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
//筛选标题显示处理
private
fun
filterLabelSet
()
{
if
((
allFilter
.
others
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
doctorEdu
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
)
==
1
)
{
if
((
allFilter
.
others
.
size
+
allFilter
.
ages
.
size
+
allFilter
.
doctorEdu
.
size
+
allFilter
.
enquiries
.
size
+
allFilter
.
title
.
size
+
allFilter
.
specialityCrowd
.
size
)
==
1
)
{
var
text
:
String
?
=
""
when
{
allFilter
.
others
.
size
==
1
->
{
...
...
@@ -1077,10 +1108,10 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
allFilter
.
title
.
size
==
1
->
{
text
=
allFilter
.
title
[
0
].
value
}
allFilter
.
specialityCrowd
.
size
==
1
->
{
allFilter
.
specialityCrowd
.
size
==
1
->
{
text
=
allFilter
.
specialityCrowd
[
0
].
value
}
allFilter
.
doctorEdu
.
size
==
1
->
{
allFilter
.
doctorEdu
.
size
==
1
->
{
text
=
allFilter
.
doctorEdu
[
0
].
value
}
else
->
{
...
...
@@ -1174,7 +1205,12 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
//显示地区弹窗
private
fun
showAreaPopupWindow
()
{
if
(
headData
?.
region
!=
null
)
{
val
regionPopupWindow
=
AreaPopupWindow
(
mActivity
,
headData
?.
region
?:
ArrayList
(),
allFilter
.
region
,
allFilter
.
sub
)
val
regionPopupWindow
=
AreaPopupWindow
(
mActivity
,
headData
?.
region
?:
ArrayList
(),
allFilter
.
region
,
allFilter
.
sub
)
regionPopupWindow
.
showAsDropDown
(
viewSep2
)
viewDim
.
visibility
=
View
.
VISIBLE
updateFilterTextViewStatus
(
tvArea
,
FILTER_STATUS_OPEN
)
...
...
@@ -1192,7 +1228,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
updateFilterTextViewStatus
(
tvArea
,
FILTER_STATUS_OPEN
)
allFilter
.
region
=
region
allFilter
.
sub
=
sub
if
(
TextUtils
.
isEmpty
(
region
.
code
)
&&
TextUtils
.
isEmpty
(
sub
.
code
))
{
if
(
TextUtils
.
isEmpty
(
region
.
code
)
&&
TextUtils
.
isEmpty
(
sub
.
code
))
{
tvArea
.
text
=
"地区"
}
else
if
(!
TextUtils
.
isEmpty
(
region
.
code
)
&&
!
TextUtils
.
isEmpty
(
sub
.
code
))
{
if
(
region
.
value
?.
length
?:
0
>
4
)
{
...
...
@@ -1250,49 +1286,47 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
}
}
private
var
categoryPopup
:
CategoryPopupWindow
?
=
null
private
var
mHandler
:
Handler
?=
null
private
var
mHandler
:
Handler
?
=
null
/**
* 显示八大类弹窗
*/
private
fun
showSubjectPopupWindow
()
{
if
(
categoryPopup
==
null
)
{
categoryPopup
=
CategoryPopupWindow
(
mActivity
,
allFilter
)
mHandler
=
Handler
()
mHandler
!!
.
post
{
categoryPopup
!!
.
updateData
()
}
categoryPopup
!!
.
setOnDismissListener
{
viewDim
.
visibility
=
View
.
INVISIBLE
showConsultAssistantDialog
()
}
hideConsultAssistantDialog
()
categoryPopup
!!
.
onSubjectsSelectedListener
=
this
categoryPopup
!!
.
showAsDropDown
(
viewSep2
)
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_OPEN
)
viewDim
.
visibility
=
View
.
VISIBLE
}
else
{
hideConsultAssistantDialog
()
categoryPopup
!!
.
showAsDropDown
(
viewSep2
)
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_OPEN
)
viewDim
.
visibility
=
View
.
VISIBLE
val
categoryPopup
=
CategoryPopupWindow
(
mActivity
,
allFilter
)
mHandler
=
Handler
()
mHandler
!!
.
post
{
categoryPopup
.
updateData
()
}
categoryPopup
.
setOnDismissListener
{
viewDim
.
visibility
=
View
.
INVISIBLE
showConsultAssistantDialog
()
}
hideConsultAssistantDialog
()
categoryPopup
.
onSubjectsSelectedListener
=
this
categoryPopup
.
showAsDropDown
(
viewSep2
)
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_OPEN
)
viewDim
.
visibility
=
View
.
VISIBLE
}
/**
* 主题选择确认回调
*
*/
override
fun
onCategoriesSelected
(
signLit
:
ArrayList
<
String
>)
{
if
(
signLit
.
isNotEmpty
()){
val
sign1
=
signLit
.
joinToString
(
","
){
it
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_TWO_CATEGORY_CLICK
,
sign1
,
"app"
,
""
)
override
fun
onCategoriesSelected
(
signLit
:
ArrayList
<
String
>)
{
if
(
signLit
.
isNotEmpty
())
{
val
sign1
=
signLit
.
joinToString
(
","
)
{
it
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
ConsultEvent
.
POSITION_TWO_CATEGORY_CLICK
,
sign1
,
"app"
,
""
)
}
if
(
allFilter
.
categoryId2List
.
size
>
0
||
allFilter
.
categoryId3List
.
size
>
0
)
{
if
(
allFilter
.
categoryId2List
.
size
>
0
||
allFilter
.
categoryId3List
.
size
>
0
)
{
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_FILTERED
)
}
else
{
}
else
{
updateFilterTextViewStatus
(
tvSubject
,
FILTER_STATUS_NORMAL
)
}
refresh
()
...
...
@@ -1308,15 +1342,21 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
* EventBus从首页某个位置点击事件传递
* sign 仅用于埋点事件统计
*/
private
var
sign2
=
""
private
var
sign2
=
""
fun
onEvent
(
event
:
HomeModuleTabEvent
)
{
if
(!
TextUtils
.
isEmpty
(
event
.
sign
)){
sign2
=
event
.
sign
if
(!
TextUtils
.
isEmpty
(
event
.
sign
))
{
sign2
=
event
.
sign
// 埋点
if
(!
TextUtils
.
isEmpty
(
mIdssign1
)){
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
POSITION_CONSULT_COUNSELOR_LIST_PAGE_VISIT
,
mIdssign1
,
sign2
,
"app"
)
if
(!
TextUtils
.
isEmpty
(
mIdssign1
))
{
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
,
ConsultBIConstants
.
POSITION_CONSULT_COUNSELOR_LIST_PAGE_VISIT
,
mIdssign1
,
sign2
,
"app"
)
}
}
}
}
//刷新列表
...
...
@@ -1382,13 +1422,13 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
super
.
onResume
()
refresh
(
false
)
ActionCountUtils
.
count
(
ConsultBIConstants
.
ConsultEvent
.
APP_CONSULT_LIST_PAGE_VISIT
)
ActionCountUtils
.
count
(
"daoyi_advertisement_page|daoyi_advertisement_visit"
,
"6"
)
ActionCountUtils
.
count
(
"daoyi_advertisement_page|daoyi_advertisement_visit"
,
"6"
)
}
override
fun
onDestroy
()
{
super
.
onDestroy
()
EventBus
.
getDefault
().
unregister
(
this
)
mHandler
=
null
mHandler
=
null
ConsultAssistantDialogUtils
.
INSTANCE
.
resetStatus
()
}
}
m-consultant/src/main/java/com/yidianling/consultant/HotSearchActivity.kt
View file @
cc3b6d32
...
...
@@ -98,14 +98,24 @@ class HotSearchActivity : BaseMvpActivity<IHotSearchContract.View, IHotSearchCon
if
(
actionId
==
EditorInfo
.
IME_ACTION_SEARCH
)
{
// 搜索的关联词
var
relatedWords
=
""
var
isRecommendWords
=
false
if
(
searchSuggestList
.
isNotEmpty
()&&
searchSuggestList
.
size
>
0
){
searchSuggestList
[
0
].
suggest_relations
?.
let
{
if
(
it
.
size
>
0
){
relatedWords
=
it
[
0
]
}
if
(
searchSuggestList
[
0
].
suggest_relations
.
size
>
0
){
relatedWords
=
searchSuggestList
[
0
].
suggest_relations
[
0
]
isRecommendWords
=
true
}
if
(
TextUtils
.
isEmpty
(
relatedWords
)&&!
TextUtils
.
isEmpty
(
searchSuggestList
[
0
].
suggest_content
)){
relatedWords
=
searchSuggestList
[
0
].
suggest_content
}
doSearch
(
etSearch
.
text
.
toString
(),
relatedWords
,
isRecommendWords
)
}
else
{
val
searchWords
=
etSearch
.
text
.
toString
()
if
(
TextUtils
.
isEmpty
(
searchWords
)){
doSearch
(
searchWords
,
""
,
isRecommendWords
)
}
else
{
getSearchWords
(
etSearch
.
text
.
toString
(),
true
)
}
}
doSearch
(
etSearch
.
text
.
toString
(),
relatedWords
)
}
true
}
...
...
@@ -138,12 +148,20 @@ class HotSearchActivity : BaseMvpActivity<IHotSearchContract.View, IHotSearchCon
searchWordsAdapter
.
setOnItemClickListener
{
adapter
,
view
,
position
->
// 搜索的关联词
var
relatedWords
=
""
var
isRecommendWords
=
false
if
(
searchSuggestList
.
isNotEmpty
()&&
searchSuggestList
.
size
>
0
){
searchSuggestList
[
position
].
suggest_relations
?.
let
{
relatedWords
=
it
[
0
]
if
(
searchSuggestList
[
position
].
suggest_relations
.
size
>
0
){
relatedWords
=
searchSuggestList
[
position
].
suggest_relations
[
0
]
isRecommendWords
=
true
}
if
(
TextUtils
.
isEmpty
(
relatedWords
)&&!
TextUtils
.
isEmpty
(
searchSuggestList
[
position
].
suggest_content
)){
relatedWords
=
searchSuggestList
[
position
].
suggest_content
}
}
doSearch
(
searchSuggestList
[
position
].
suggest_content
,
relatedWords
)
doSearch
(
searchSuggestList
[
position
].
suggest_content
,
relatedWords
,
isRecommendWords
)
// 埋点
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_YDL_USER_MAIN_PAGE
,
ConsultBIConstants
.
POSITION_YDL_USER_ASSOCIATE_WORD_CLICK
,
etSearch
.
text
.
toString
(),
searchSuggestList
[
position
].
suggest_content
,
"app"
)
}
etSearch
.
addTextChangedListener
(
object
:
TextWatcher
{
override
fun
afterTextChanged
(
s
:
Editable
?)
{
...
...
@@ -167,6 +185,7 @@ class HotSearchActivity : BaseMvpActivity<IHotSearchContract.View, IHotSearchCon
})
}
/**
* 获取搜索联想词
* @param isClickWords 是否是点击历史搜索、热门搜索等进行搜索
...
...
@@ -186,20 +205,27 @@ class HotSearchActivity : BaseMvpActivity<IHotSearchContract.View, IHotSearchCon
if
(
isClickWords
){
// 搜索的关联词
var
relatedWords
=
""
var
isRecommendWords
=
false
if
(!
searchWordsBean
.
search_suggests
.
isNullOrEmpty
()&&
searchWordsBean
.
search_suggests
.
size
>
0
){
searchWordsBean
.
search_suggests
[
0
].
suggest_relations
?.
let
{
if
(
it
.
size
>
0
){
relatedWords
=
it
[
0
]
}
if
(
searchWordsBean
.
search_suggests
[
0
].
suggest_relations
.
size
>
0
){
relatedWords
=
searchWordsBean
.
search_suggests
[
0
].
suggest_relations
[
0
]
isRecommendWords
=
true
}
if
(
TextUtils
.
isEmpty
(
relatedWords
)&&!
TextUtils
.
isEmpty
(
searchWordsBean
.
search_suggests
[
0
].
suggest_content
)){
relatedWords
=
searchWordsBean
.
search_suggests
[
0
].
suggest_content
}
}
doSearch
(
searchContent
,
relatedWords
)
doSearch
(
searchContent
,
relatedWords
,
isRecommendWords
)
}
else
{
searchSuggestList
.
clear
()
if
(!
searchWordsBean
.
search_suggests
.
isNullOrEmpty
()){
rv_search_words
.
visibility
=
View
.
VISIBLE
searchSuggestList
.
addAll
(
searchWordsBean
.
search_suggests
)
searchWordsAdapter
.
notifyDataAndSetSearchWord
(
mSearchContent
)
// 埋点
val
sign2
=
searchSuggestList
.
joinToString
(
","
){
it
.
suggest_content
}
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_YDL_USER_MAIN_PAGE
,
ConsultBIConstants
.
POSITION_YDL_USER_ASSOCIATE_WORD_VISIT
,
searchContent
,
sign2
,
"app"
)
}
else
{
rv_search_words
.
visibility
=
View
.
GONE
}
...
...
@@ -358,8 +384,9 @@ class HotSearchActivity : BaseMvpActivity<IHotSearchContract.View, IHotSearchCon
/**
* 搜索
* @param isRecommendWords 是否是推荐词
*/
private
fun
doSearch
(
searchWords
:
String
,
relatedWords
:
String
)
{
private
fun
doSearch
(
searchWords
:
String
,
relatedWords
:
String
,
isRecommendWords
:
Boolean
)
{
val
view
=
this
.
currentFocus
if
(
view
!=
null
)
{
val
imm
=
getSystemService
(
Context
.
INPUT_METHOD_SERVICE
)
as
InputMethodManager
...
...
@@ -375,7 +402,7 @@ class HotSearchActivity : BaseMvpActivity<IHotSearchContract.View, IHotSearchCon
Gson
().
toJson
(
historyList
)
)
}
ExpertSearchActivity
.
startSearch
(
this
,
searchWords
,
"14"
,
relatedWords
)
ExpertSearchActivity
.
startSearch
(
this
,
searchWords
,
"14"
,
relatedWords
,
isRecommendWords
)
finish
()
}
...
...
m-consultant/src/main/java/com/yidianling/consultant/adapter/ExpertSearchAdapter.kt
View file @
cc3b6d32
...
...
@@ -29,6 +29,7 @@ import com.yidianling.consultant.constants.ConsultBIConstants
import
com.yidianling.consultant.model.bean.ExpertServiceItem
import
com.yidianling.consultant.modular.utils.TempH5RouteUtils
import
com.yidianling.consultant.router.ConsultantIn
import
kotlinx.android.synthetic.main.consultant_activity_hot_search.*
import
kotlinx.android.synthetic.main.consultant_expert_search_feedbackrate.view.*
import
kotlinx.android.synthetic.main.consultant_expert_search_header_view.view.*
import
kotlinx.android.synthetic.main.consultant_expert_search_item_view.view.*
...
...
@@ -71,12 +72,18 @@ class ExpertSearchAdapter(
var
hasMore
=
true
var
pageIndex
:
Int
=
0
private
var
clickCount
=
0
// 搜索结果提示标签点击次数
var
clickCount
=
0
// 搜索结果提示标签点击次数
var
mIsRecommendWords
=
false
// 是否是推荐词
fun
setEntrance
(
pageIndex
:
Int
)
{
this
.
pageIndex
=
pageIndex
}
fun
setIsRecommendWords
(
isRecommend
:
Boolean
){
mIsRecommendWords
=
isRecommend
}
@SuppressLint
(
"SetTextI18n"
)
override
fun
onBindViewHolder
(
holder
:
RecyclerView
.
ViewHolder
,
position
:
Int
)
{
if
(
holder
is
HeaderViewHolder
)
{
// 搜索结果提示头部
...
...
@@ -87,6 +94,12 @@ class ExpertSearchAdapter(
var
text
=
"根据匹配,为您推荐“${listData[0].related_word}”相关词"
holder
.
tvSearchRelatedWord
.
text
=
setTextBold
(
text
,
listData
[
0
].
related_word
)
holder
.
tvSearchWord
.
text
=
listData
[
0
].
search_content
// 埋点
if
(
mIsRecommendWords
){
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_YDL_USER_MAIN_PAGE
,
"ydl_user_map_word_visit"
,
listData
[
0
].
search_content
,
listData
[
0
].
related_word
,
"app"
)
}
else
{
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_YDL_USER_MAIN_PAGE
,
"ydl_user_correction_word_visit"
,
listData
[
0
].
search_content
,
listData
[
0
].
related_word
,
"app"
)
}
holder
.
tvSearchWord
.
setOnClickListener
{
mOnClickLister
.
onClick
(
holder
.
tvSearchWord
.
text
.
toString
())
++
clickCount
...
...
@@ -95,14 +108,24 @@ class ExpertSearchAdapter(
holder
.
tvSearchRelatedWord
.
text
=
setTextBold
(
text
,
listData
[
0
].
search_content
)
holder
.
tvSearchTips
.
text
=
"你要找的是不是"
holder
.
tvSearchWord
.
text
=
listData
[
0
].
related_word
// 埋点
if
(
mIsRecommendWords
){
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_YDL_USER_MAIN_PAGE
,
"ydl_user_map_inputword_click"
,
listData
[
0
].
related_word
,
listData
[
0
].
search_content
,
"app"
)
}
else
{
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_YDL_USER_MAIN_PAGE
,
"ydl_user_correction_inputword_click"
,
listData
[
0
].
related_word
,
listData
[
0
].
search_content
,
"app"
)
}
}
else
if
(
clickCount
==
2
){
// 第二次点击搜索标签隐藏搜索匹配结果提示
// 埋点
if
(
mIsRecommendWords
){
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_YDL_USER_MAIN_PAGE
,
"ydl_user_map_recommendword_click"
,
listData
[
0
].
search_content
,
listData
[
0
].
related_word
,
"app"
)
}
else
{
ActionCountUtils
.
baiDuCountSign3
(
ConsultBIConstants
.
PART_ID_YDL_USER_MAIN_PAGE
,
"ydl_user_correction_recommendword_click"
,
listData
[
0
].
search_content
,
listData
[
0
].
related_word
,
"app"
)
}
listData
.
removeAt
(
0
)
clickCount
=
0
// 点击两次后重置为0
}
}
}
}
else
{
holder
.
clSearchWords
.
visibility
=
View
.
GONE
// listData.removeAt(0)
}
}
}
else
if
(
holder
is
NormalViewHolder
)
{
...
...
@@ -423,10 +446,10 @@ class ExpertSearchAdapter(
override
fun
getItemViewType
(
position
:
Int
):
Int
=
when
{
position
==
0
->{
position
==
0
&&
listData
.
size
>
0
&&
listData
[
0
].
is_head_view
->{
HEADER_VIEW
}
position
>
0
&&
position
<
listData
.
size
->
{
position
<
listData
.
size
->
{
NORMAL_VIEW
}
!
hasMore
&&
listData
.
size
==
0
->
{
...
...
m-consultant/src/main/java/com/yidianling/consultant/bean/SearchWordsBean.kt
View file @
cc3b6d32
...
...
@@ -11,7 +11,7 @@ data class SearchSuggestListBean(
val
id
:
String
,
val
score
:
String
,
val
suggest_content
:
String
,
val
suggest_relations
:
ArrayList
<
String
>
?
,
val
suggest_relations
:
ArrayList
<
String
>,
val
search_count
:
Int
,
val
suggest_classify_types
:
ArrayList
<
String
>,
val
mapping_classify_type_exist
:
Boolean
...
...
m-consultant/src/main/java/com/yidianling/consultant/constants/ConsultBIConstants.kt
View file @
cc3b6d32
...
...
@@ -21,7 +21,10 @@ class ConsultBIConstants {
const
val
POSITION_DAOYI_ADVERTISEMENT_CLICK
=
"daoyi_advertisement_page|daoyi_advertisement_click"
const
val
PART_ID_CONSULT_COUNSELOR_LIST_PAGE
=
"consult_counselor_list_page"
// 咨询师列表页面浏览part_id
const
val
PART_ID_YDL_USER_MAIN_PAGE
=
"ydl_user_main_page"
// 联想词part_id
const
val
POSITION_CONSULT_COUNSELOR_LIST_PAGE_VISIT
=
"consult_counselor_list_page_visit"
// 咨询师列表页面浏览position
const
val
POSITION_YDL_USER_ASSOCIATE_WORD_VISIT
=
"ydl_user_associate_word_visit"
// 联想词曝光position
const
val
POSITION_YDL_USER_ASSOCIATE_WORD_CLICK
=
"ydl_user_associate_word_click"
// 联想词点击position
}
//====================APP咨询列表页(app_consult_list_page)====================
...
...
@@ -75,8 +78,7 @@ class ConsultBIConstants {
class
UserMainEvent
{
companion
object
{
private
const
val
YDL_USER_MAIN_PAGE
:
String
=
"ydl_user_main_page|"
//壹点灵用户版首页 partId
private
const
val
YDL_USER_MAIN_PAGE
:
String
=
"ydl_user_main_page|"
//壹点灵用户版首页 partId
const
val
YDL_USER_SEARCH_CLICK
:
String
=
YDL_USER_MAIN_PAGE
+
"ydl_user_search_click"
//搜索栏
...
...
m-consultant/src/main/java/com/yidianling/consultant/modular/singlton/ConsultAssistantDialogUtils.kt
View file @
cc3b6d32
...
...
@@ -403,7 +403,7 @@ class ConsultAssistantDialogUtils private constructor() {
.
getSecondTaskActivity
()
?.
finish
()
activity
.
finish
()
}
else
{
if
(
null
!=
activity
&&
!
activity
.
isFinishing
)
{
if
(!
activity
.
isFinishing
)
{
activity
.
finish
()
}
}
...
...
@@ -417,10 +417,10 @@ class ConsultAssistantDialogUtils private constructor() {
ffrom
)
}
if
(
null
!=
activity
&&
activity
is
ConsultAssistantCenterActivity
&&
!
activity
.
isFinishing
)
activity
.
finish
()
if
(
activity
is
ConsultAssistantCenterActivity
&&
!
activity
.
isFinishing
)
activity
.
finish
()
},
object
:
ThrowableConsumer
()
{
override
fun
accept
(
msg
:
String
)
{
if
(
null
!=
activity
&&
activity
is
ConsultAssistantCenterActivity
&&
!
activity
.
isFinishing
)
activity
.
finish
()
if
(
activity
is
ConsultAssistantCenterActivity
&&
!
activity
.
isFinishing
)
activity
.
finish
()
}
}
)
...
...
m-consultant/src/main/java/com/yidianling/consultant/ui/view/CategoryPopupWindow.kt
View file @
cc3b6d32
...
...
@@ -6,6 +6,7 @@ import android.view.LayoutInflater
import
android.view.View
import
android.view.ViewGroup
import
android.widget.ImageView
import
android.widget.LinearLayout
import
android.widget.PopupWindow
import
com.yidianling.common.tools.RxImageTool
import
com.yidianling.consultant.R
...
...
@@ -506,6 +507,7 @@ class CategoryPopupWindow(context: Context,allFilter:AllFilter) : PopupWindow(Vi
if
(
mAllFilter
.
childList
.
size
>
12
){
ivSortChildEducationOpen
.
visibility
=
View
.
VISIBLE
view
.
ll_sort_child_education_open
.
setOnClickListener
{
val
params
=
rvSortChildEducation
.
layoutParams
as
LinearLayout
.
LayoutParams
if
(!
childEducationAdapter
.
isVisible
){
if
(
childList
.
size
<=
12
){
childList
.
addAll
(
mAllFilter
.
childList
.
subList
(
12
,
mAllFilter
.
childList
.
size
))
...
...
@@ -513,9 +515,15 @@ class CategoryPopupWindow(context: Context,allFilter:AllFilter) : PopupWindow(Vi
}
childEducationAdapter
.
setAllVisible
()
ivSortChildEducationOpen
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_open
)
// 展开的布局设置自适应
params
.
height
=
LinearLayout
.
LayoutParams
.
WRAP_CONTENT
rvSortChildEducation
.
layoutParams
=
params
}
else
{
childEducationAdapter
.
setGone
()
ivSortChildEducationOpen
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_close
)
// 关闭的时候布局设置为固定高度
params
.
height
=
RxImageTool
.
dp2px
(
138f
)
rvSortChildEducation
.
layoutParams
=
params
}
}
}
...
...
@@ -529,6 +537,7 @@ class CategoryPopupWindow(context: Context,allFilter:AllFilter) : PopupWindow(Vi
if
(
mAllFilter
.
stressList
.
size
>
12
){
ivSortEmotionalStress
.
visibility
=
View
.
VISIBLE
view
.
ll_sort_emotional_stress
.
setOnClickListener
{
val
params
=
rvSortEmotionalStress
.
layoutParams
as
LinearLayout
.
LayoutParams
if
(!
stressAdapter
.
isVisible
){
if
(
stressList
.
size
<=
12
){
stressList
.
addAll
(
mAllFilter
.
stressList
.
subList
(
12
,
mAllFilter
.
stressList
.
size
))
...
...
@@ -536,9 +545,15 @@ class CategoryPopupWindow(context: Context,allFilter:AllFilter) : PopupWindow(Vi
}
stressAdapter
.
setAllVisible
()
ivSortEmotionalStress
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_open
)
// 展开的布局设置自适应
params
.
height
=
LinearLayout
.
LayoutParams
.
WRAP_CONTENT
rvSortEmotionalStress
.
layoutParams
=
params
}
else
{
stressAdapter
.
setGone
()
ivSortEmotionalStress
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_close
)
// 关闭的时候布局设置为固定高度
params
.
height
=
RxImageTool
.
dp2px
(
138f
)
rvSortEmotionalStress
.
layoutParams
=
params
}
}
}
...
...
@@ -551,12 +566,19 @@ class CategoryPopupWindow(context: Context,allFilter:AllFilter) : PopupWindow(Vi
if
(
loveEmotionList
.
size
>
12
){
ivSortLoveEmotion
.
visibility
=
View
.
VISIBLE
view
.
ll_sort_love_emotion
.
setOnClickListener
{
val
params
=
view
.
rv_sort_love_emotion
.
layoutParams
as
LinearLayout
.
LayoutParams
if
(!
loveEmotionAdapter
.
isVisible
){
loveEmotionAdapter
.
setAllVisible
()
ivSortLoveEmotion
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_open
)
// 展开的布局设置自适应
params
.
height
=
LinearLayout
.
LayoutParams
.
WRAP_CONTENT
view
.
rv_sort_love_emotion
.
layoutParams
=
params
}
else
{
loveEmotionAdapter
.
setGone
()
ivSortLoveEmotion
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_close
)
// 关闭的时候布局设置为固定高度
params
.
height
=
RxImageTool
.
dp2px
(
138f
)
view
.
rv_sort_love_emotion
.
layoutParams
=
params
}
}
}
...
...
@@ -566,12 +588,19 @@ class CategoryPopupWindow(context: Context,allFilter:AllFilter) : PopupWindow(Vi
if
(
marriedFamilyList
.
size
>
12
){
ivSortMarriedFamily
.
visibility
=
View
.
VISIBLE
view
.
ll_sort_married_family
.
setOnClickListener
{
val
params
=
view
.
rv_sort_married_family
.
layoutParams
as
LinearLayout
.
LayoutParams
if
(!
marriedFamilyAdapter
.
isVisible
){
marriedFamilyAdapter
.
setAllVisible
()
ivSortMarriedFamily
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_open
)
// 展开的布局设置自适应
params
.
height
=
LinearLayout
.
LayoutParams
.
WRAP_CONTENT
view
.
rv_sort_married_family
.
layoutParams
=
params
}
else
{
marriedFamilyAdapter
.
setGone
()
ivSortMarriedFamily
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_close
)
// 关闭的时候布局设置为固定高度
params
.
height
=
RxImageTool
.
dp2px
(
138f
)
view
.
rv_sort_married_family
.
layoutParams
=
params
}
}
}
...
...
@@ -581,12 +610,19 @@ class CategoryPopupWindow(context: Context,allFilter:AllFilter) : PopupWindow(Vi
if
(
personalGrowthList
.
size
>
12
){
ivSortPersonalGrowth
.
visibility
=
View
.
VISIBLE
view
.
ll_sort_personal_growth
.
setOnClickListener
{
val
params
=
view
.
rv_sort_personal_growth
.
layoutParams
as
LinearLayout
.
LayoutParams
if
(!
personalGrowthAdapter
.
isVisible
){
personalGrowthAdapter
.
setAllVisible
()
ivSortPersonalGrowth
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_open
)
// 展开的布局设置自适应
params
.
height
=
LinearLayout
.
LayoutParams
.
WRAP_CONTENT
view
.
rv_sort_personal_growth
.
layoutParams
=
params
}
else
{
personalGrowthAdapter
.
setGone
()
ivSortPersonalGrowth
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_close
)
// 关闭的时候布局设置为固定高度
params
.
height
=
RxImageTool
.
dp2px
(
138f
)
view
.
rv_sort_personal_growth
.
layoutParams
=
params
}
}
}
...
...
@@ -596,12 +632,19 @@ class CategoryPopupWindow(context: Context,allFilter:AllFilter) : PopupWindow(Vi
if
(
interpersonalRelationshipList
.
size
>
12
){
ivSortInterpersonalRelationship
.
visibility
=
View
.
VISIBLE
view
.
ll_sort_interpersonal_relationship
.
setOnClickListener
{
val
params
=
view
.
rv_sort_interpersonal_relationship
.
layoutParams
as
LinearLayout
.
LayoutParams
if
(!
interpersonalRelationshipAdapter
.
isVisible
){
interpersonalRelationshipAdapter
.
setAllVisible
()
ivSortInterpersonalRelationship
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_open
)
// 展开的布局设置自适应
params
.
height
=
LinearLayout
.
LayoutParams
.
WRAP_CONTENT
view
.
rv_sort_interpersonal_relationship
.
layoutParams
=
params
}
else
{
interpersonalRelationshipAdapter
.
setGone
()
ivSortInterpersonalRelationship
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_close
)
// 关闭的时候布局设置为固定高度
params
.
height
=
RxImageTool
.
dp2px
(
138f
)
view
.
rv_sort_interpersonal_relationship
.
layoutParams
=
params
}
}
}
...
...
@@ -611,12 +654,19 @@ class CategoryPopupWindow(context: Context,allFilter:AllFilter) : PopupWindow(Vi
if
(
careerDevelopmentList
.
size
>
12
){
ivSortCareerDevelopment
.
visibility
=
View
.
VISIBLE
view
.
ll_sort_career_development
.
setOnClickListener
{
val
params
=
view
.
rv_sort_career_development
.
layoutParams
as
LinearLayout
.
LayoutParams
if
(!
careerDevelopmentAdapter
.
isVisible
){
careerDevelopmentAdapter
.
setAllVisible
()
ivSortCareerDevelopment
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_open
)
// 展开的布局设置自适应
params
.
height
=
LinearLayout
.
LayoutParams
.
WRAP_CONTENT
view
.
rv_sort_career_development
.
layoutParams
=
params
}
else
{
careerDevelopmentAdapter
.
setGone
()
ivSortCareerDevelopment
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_close
)
// 关闭的时候布局设置为固定高度
params
.
height
=
RxImageTool
.
dp2px
(
138f
)
view
.
rv_sort_career_development
.
layoutParams
=
params
}
}
}
...
...
@@ -626,12 +676,19 @@ class CategoryPopupWindow(context: Context,allFilter:AllFilter) : PopupWindow(Vi
if
(
mentalHealthList
.
size
>
12
){
ivSortMentalHealth
.
visibility
=
View
.
VISIBLE
view
.
ll_sort_mental_health
.
setOnClickListener
{
val
params
=
view
.
rv_sort_mental_health
.
layoutParams
as
LinearLayout
.
LayoutParams
if
(!
mentalHealthAdapter
.
isVisible
){
mentalHealthAdapter
.
setAllVisible
()
ivSortMentalHealth
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_open
)
// 展开的布局设置自适应
params
.
height
=
LinearLayout
.
LayoutParams
.
WRAP_CONTENT
view
.
rv_sort_mental_health
.
layoutParams
=
params
}
else
{
mentalHealthAdapter
.
setGone
()
ivSortMentalHealth
.
setImageResource
(
R
.
drawable
.
consultant_ic_sort_close
)
// 关闭的时候布局设置为固定高度
params
.
height
=
RxImageTool
.
dp2px
(
138f
)
view
.
rv_sort_mental_health
.
layoutParams
=
params
}
}
}
...
...
m-consultant/src/main/java/com/yidianling/consultant/ui/view/FilterPopupWindow.kt
View file @
cc3b6d32
...
...
@@ -4,33 +4,29 @@ import android.annotation.SuppressLint
import
android.app.Activity
import
android.content.Context
import
android.graphics.drawable.BitmapDrawable
import
android.os.Build
import
androidx.core.content.ContextCompat
import
android.text.*
import
android.text.style.AbsoluteSizeSpan
import
android.util.Log
import
android.view.*
import
android.view.KeyEvent
import
android.view.LayoutInflater
import
android.view.View
import
android.view.ViewGroup
import
android.view.inputmethod.EditorInfo
import
android.view.inputmethod.InputMethodManager
import
android.widget.*
import
com.bumptech.glide.Glide
import
com.ydl.ydlcommon.data.http.RxUtils
import
com.ydl.ydlcommon.utils.actionutil.ActionCountUtils
import
com.ydl.ydlcommon.utils.remind.ToastHelper
import
com.yidianling.common.tools.RxDeviceTool
import
com.yidianling.common.tools.RxImageTool
import
com.yidianling.common.tools.RxKeyboardTool
import
com.yidianling.consultant.R
import
com.yidianling.consultant.constants.ConsultBIConstants
import
com.yidianling.consultant.http.ExpertSearchDataManager
import
com.yidianling.consultant.listener.OnFilterConfirmListener
import
com.yidianling.consultant.model.bean.AllFilter
import
com.yidianling.consultant.model.bean.Filters
import
com.yidianling.consultant.model.bean.PriceRangesItem
import
io.reactivex.android.schedulers.AndroidSchedulers
import
io.reactivex.disposables.CompositeDisposable
import
io.reactivex.disposables.Disposable
import
io.reactivex.schedulers.Schedulers
import
kotlinx.android.synthetic.main.consultant_item_filter.view.*
import
kotlinx.android.synthetic.main.consultant_item_price_range.view.*
import
kotlinx.android.synthetic.main.consultant_ui_filter_popup.view.*
...
...
m-consultant/src/main/res/layout/consultant_ui_subject_popup_window.xml
View file @
cc3b6d32
<?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"
android:layout_width=
"match_parent"
android:layout_height=
"566dp"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
android:background=
"@color/platform_white"
android:orientation=
"vertical"
>
<androidx.core.widget.NestedScrollView
android:layout_width=
"match_parent"
android:layout_height=
"
wrap_cont
ent"
app:layout_constraintTop_toTopOf=
"parent"
>
android:layout_height=
"
match_par
ent"
app:layout_constraintTop_toTopOf=
"parent"
>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
android:layout_height=
"match_parent"
android:layout_marginBottom=
"68dp"
>
android:orientation=
"vertical"
>
<LinearLayout
android:id=
"@+id/ll_sort_child_education_open"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"horizontal"
android:paddingStart=
"@dimen/platform_dp_16"
android:paddingEnd=
"@dimen/platform_dp_16"
android:layout_marginTop=
"@dimen/platform_dp_17"
android:gravity=
"center_vertical"
>
android:orientation=
"horizontal"
android:paddingStart=
"@dimen/platform_dp_16"
android:paddingEnd=
"@dimen/platform_dp_16"
>
<TextView
android:layout_width=
"0dp"
android:layout_weight=
"1"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
android:includeFontPadding=
"false"
android:textStyle=
"bold"
android:text=
"亲子教育"
android:textSize=
"16sp"
android:textColor=
"@color/platform_color_242424"
android:includeFontPadding=
"false"
android:fontFamily=
"sans-serif-medium"
/>
android:textSize=
"16sp"
/>
<ImageView
android:id=
"@+id/iv_sort_child_education_open"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:layout_width=
"
20dp
"
android:layout_height=
"
20dp
"
android:src=
"@drawable/consultant_ic_sort_close"
android:visibility=
"gone"
/>
android:visibility=
"gone"
/>
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id=
"@+id/rv_sort_child_education"
android:layout_width=
"match_parent"
android:layout_height=
"
wrap_content
"
android:layout_height=
"
138dp
"
android:layout_marginStart=
"6dp"
android:overScrollMode=
"never"
/>
android:layout_marginEnd=
"12dp"
android:nestedScrollingEnabled=
"false"
android:overScrollMode=
"never"
/>
<LinearLayout
android:id=
"@+id/ll_sort_emotional_stress"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/platform_dp_25"
android:gravity=
"center_vertical"
android:orientation=
"horizontal"
android:paddingStart=
"@dimen/platform_dp_16"
android:paddingEnd=
"@dimen/platform_dp_16"
android:layout_marginTop=
"@dimen/platform_dp_21"
android:gravity=
"center_vertical"
>
android:paddingEnd=
"@dimen/platform_dp_16"
>
<TextView
android:layout_width=
"0dp"
android:layout_weight=
"1"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
android:textStyle=
"bold"
android:includeFontPadding=
"false"
android:text=
"情绪压力"
android:textSize=
"16sp"
android:textColor=
"@color/platform_color_242424"
android:includeFontPadding=
"false"
android:fontFamily=
"sans-serif-medium"
/>
android:textSize=
"16sp"
/>
<ImageView
android:id=
"@+id/iv_sort_emotional_stress"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:layout_width=
"
20dp
"
android:layout_height=
"
20dp
"
android:src=
"@drawable/consultant_ic_sort_close"
android:visibility=
"gone"
/>
android:visibility=
"gone"
/>
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id=
"@+id/rv_sort_emotional_stress"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_height=
"138dp"
android:layout_marginEnd=
"12dp"
android:layout_marginStart=
"6dp"
android:
overScrollMode=
"never
"
/>
android:
nestedScrollingEnabled=
"false
"
android:overScrollMode=
"never"
/>
<LinearLayout
android:id=
"@+id/ll_sort_love_emotion"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/platform_dp_25"
android:gravity=
"center_vertical"
android:orientation=
"horizontal"
android:paddingStart=
"@dimen/platform_dp_16"
android:paddingEnd=
"@dimen/platform_dp_16"
android:layout_marginTop=
"@dimen/platform_dp_21"
android:gravity=
"center_vertical"
>
android:paddingEnd=
"@dimen/platform_dp_16"
>
<TextView
android:layout_width=
"0dp"
android:layout_weight=
"1"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
android:textStyle=
"bold"
android:includeFontPadding=
"false"
android:text=
"恋爱情感"
android:textSize=
"16sp"
android:textColor=
"@color/platform_color_242424"
android:includeFontPadding=
"false"
android:fontFamily=
"sans-serif-medium"
/>
android:textSize=
"16sp"
/>
<ImageView
android:id=
"@+id/iv_sort_love_emotion"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:layout_width=
"
20dp
"
android:layout_height=
"
20dp
"
android:src=
"@drawable/consultant_ic_sort_close"
android:visibility=
"gone"
/>
android:visibility=
"gone"
/>
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id=
"@+id/rv_sort_love_emotion"
android:layout_width=
"match_parent"
android:layout_height=
"
wrap_content
"
android:layout_height=
"
138dp
"
android:layout_marginStart=
"6dp"
android:overScrollMode=
"never"
/>
android:layout_marginEnd=
"12dp"
android:nestedScrollingEnabled=
"false"
android:overScrollMode=
"never"
/>
<LinearLayout
android:id=
"@+id/ll_sort_married_family"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/platform_dp_25"
android:gravity=
"center_vertical"
android:orientation=
"horizontal"
android:paddingStart=
"@dimen/platform_dp_16"
android:paddingEnd=
"@dimen/platform_dp_16"
android:layout_marginTop=
"@dimen/platform_dp_21"
android:gravity=
"center_vertical"
>
android:paddingEnd=
"@dimen/platform_dp_16"
>
<TextView
android:layout_width=
"0dp"
android:layout_weight=
"1"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
android:textStyle=
"bold"
android:includeFontPadding=
"false"
android:text=
"婚姻家庭"
android:textSize=
"16sp"
android:textColor=
"@color/platform_color_242424"
android:includeFontPadding=
"false"
android:fontFamily=
"sans-serif-medium"
/>
android:textSize=
"16sp"
/>
<ImageView
android:id=
"@+id/iv_sort_married_family"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:layout_width=
"
20dp
"
android:layout_height=
"
20dp
"
android:src=
"@drawable/consultant_ic_sort_close"
android:visibility=
"gone"
/>
android:visibility=
"gone"
/>
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id=
"@+id/rv_sort_married_family"
android:layout_width=
"match_parent"
android:layout_height=
"
wrap_content
"
android:layout_height=
"
138dp
"
android:layout_marginStart=
"6dp"
android:overScrollMode=
"never"
/>
android:layout_marginEnd=
"12dp"
android:nestedScrollingEnabled=
"false"
android:overScrollMode=
"never"
/>
<LinearLayout
android:id=
"@+id/ll_sort_personal_growth"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/platform_dp_25"
android:gravity=
"center_vertical"
android:orientation=
"horizontal"
android:paddingStart=
"@dimen/platform_dp_16"
android:paddingEnd=
"@dimen/platform_dp_16"
android:layout_marginTop=
"@dimen/platform_dp_21"
android:gravity=
"center_vertical"
>
android:paddingEnd=
"@dimen/platform_dp_16"
>
<TextView
android:layout_width=
"0dp"
android:layout_weight=
"1"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
android:textStyle=
"bold"
android:includeFontPadding=
"false"
android:text=
"个人成长"
android:textSize=
"16sp"
android:textColor=
"@color/platform_color_242424"
android:includeFontPadding=
"false"
android:fontFamily=
"sans-serif-medium"
/>
android:textSize=
"16sp"
/>
<ImageView
android:id=
"@+id/iv_sort_personal_growth"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:layout_width=
"
20dp
"
android:layout_height=
"
20dp
"
android:src=
"@drawable/consultant_ic_sort_close"
android:visibility=
"gone"
/>
android:visibility=
"gone"
/>
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id=
"@+id/rv_sort_personal_growth"
android:layout_width=
"match_parent"
android:layout_height=
"
wrap_content
"
android:layout_height=
"
138dp
"
android:layout_marginStart=
"6dp"
android:overScrollMode=
"never"
/>
android:layout_marginEnd=
"12dp"
android:nestedScrollingEnabled=
"false"
android:overScrollMode=
"never"
/>
<LinearLayout
android:id=
"@+id/ll_sort_interpersonal_relationship"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/platform_dp_25"
android:gravity=
"center_vertical"
android:orientation=
"horizontal"
android:paddingStart=
"@dimen/platform_dp_16"
android:paddingEnd=
"@dimen/platform_dp_16"
android:layout_marginTop=
"@dimen/platform_dp_21"
android:gravity=
"center_vertical"
>
android:paddingEnd=
"@dimen/platform_dp_16"
>
<TextView
android:layout_width=
"0dp"
android:layout_weight=
"1"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
android:textStyle=
"bold"
android:includeFontPadding=
"false"
android:text=
"人际关系"
android:textSize=
"16sp"
android:textColor=
"@color/platform_color_242424"
android:includeFontPadding=
"false"
android:fontFamily=
"sans-serif-medium"
/>
android:textSize=
"16sp"
/>
<ImageView
android:id=
"@+id/iv_sort_interpersonal_relationship"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:layout_width=
"
20dp
"
android:layout_height=
"
20dp
"
android:src=
"@drawable/consultant_ic_sort_close"
android:visibility=
"gone"
/>
android:visibility=
"gone"
/>
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id=
"@+id/rv_sort_interpersonal_relationship"
android:layout_width=
"match_parent"
android:layout_height=
"
wrap_content
"
android:layout_height=
"
138dp
"
android:layout_marginStart=
"6dp"
android:overScrollMode=
"never"
/>
android:layout_marginEnd=
"12dp"
android:nestedScrollingEnabled=
"false"
android:overScrollMode=
"never"
/>
<LinearLayout
android:id=
"@+id/ll_sort_career_development"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/platform_dp_25"
android:gravity=
"center_vertical"
android:orientation=
"horizontal"
android:paddingStart=
"@dimen/platform_dp_16"
android:paddingEnd=
"@dimen/platform_dp_16"
android:layout_marginTop=
"@dimen/platform_dp_21"
android:gravity=
"center_vertical"
>
android:paddingEnd=
"@dimen/platform_dp_16"
>
<TextView
android:layout_width=
"0dp"
android:layout_weight=
"1"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
android:textStyle=
"bold"
android:includeFontPadding=
"false"
android:text=
"职场发展"
android:textSize=
"16sp"
android:textColor=
"@color/platform_color_242424"
android:includeFontPadding=
"false"
android:fontFamily=
"sans-serif-medium"
/>
android:textSize=
"16sp"
/>
<ImageView
android:id=
"@+id/iv_sort_career_development"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:layout_width=
"
20dp
"
android:layout_height=
"
20dp
"
android:src=
"@drawable/consultant_ic_sort_close"
android:visibility=
"gone"
/>
android:visibility=
"gone"
/>
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id=
"@+id/rv_sort_career_development"
android:layout_width=
"match_parent"
android:layout_height=
"
wrap_content
"
android:layout_height=
"
138dp
"
android:layout_marginStart=
"6dp"
android:overScrollMode=
"never"
/>
android:layout_marginEnd=
"12dp"
android:nestedScrollingEnabled=
"false"
android:overScrollMode=
"never"
/>
<LinearLayout
android:id=
"@+id/ll_sort_mental_health"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/platform_dp_25"
android:gravity=
"center_vertical"
android:orientation=
"horizontal"
android:paddingStart=
"@dimen/platform_dp_16"
android:paddingEnd=
"@dimen/platform_dp_16"
android:layout_marginTop=
"@dimen/platform_dp_21"
android:gravity=
"center_vertical"
>
android:paddingEnd=
"@dimen/platform_dp_16"
>
<TextView
android:layout_width=
"0dp"
android:layout_weight=
"1"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
android:textStyle=
"bold"
android:includeFontPadding=
"false"
android:text=
"心理健康"
android:textSize=
"16sp"
android:textColor=
"@color/platform_color_242424"
android:includeFontPadding=
"false"
android:fontFamily=
"sans-serif-medium"
/>
android:textSize=
"16sp"
/>
<ImageView
android:id=
"@+id/iv_sort_mental_health"
android:layout_width=
"
wrap_content
"
android:layout_height=
"
wrap_content
"
android:layout_width=
"
20dp
"
android:layout_height=
"
20dp
"
android:src=
"@drawable/consultant_ic_sort_close"
android:visibility=
"gone"
/>
android:visibility=
"gone"
/>
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id=
"@+id/rv_sort_mental_health"
android:layout_width=
"match_parent"
android:layout_height=
"
wrap_content
"
android:layout_height=
"
138dp
"
android:layout_marginStart=
"6dp"
android:overScrollMode=
"never"
/>
android:layout_marginEnd=
"12dp"
android:nestedScrollingEnabled=
"false"
android:overScrollMode=
"never"
/>
</LinearLayout>
</androidx.core.widget.NestedScrollView>
...
...
@@ -320,36 +319,35 @@
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"68dp"
android:background=
"@color/white"
android:orientation=
"horizontal"
android:paddingStart=
"16dp"
android:paddingEnd=
"16dp"
android:paddingTop=
"8dp"
android:background=
"@color/white"
app:layout_constraintBottom_toBottomOf=
"parent"
>
android:paddingEnd=
"16dp"
app:layout_constraintBottom_toBottomOf=
"parent"
>
<TextView
android:id=
"@+id/btn_reset"
android:layout_width=
"0dp"
android:layout_weight=
"1"
android:layout_height=
"44dp"
android:layout_weight=
"1"
android:background=
"@drawable/consultant_stroke_ebebeb_r_8"
android:gravity=
"center"
android:text=
"@string/platform_reset"
android:text
Size=
"16sp
"
android:text
Color=
"@color/platform_color_242424
"
/>
android:text
Color=
"@color/platform_color_242424
"
android:text
Size=
"16sp
"
/>
<TextView
android:id=
"@+id/btnConfirm"
android:layout_width=
"0dp"
android:layout_weight=
"1"
android:layout_height=
"44dp"
android:layout_marginStart=
"13dp"
android:layout_weight=
"1"
android:background=
"@drawable/consultant_solid_main_theme_color_r_8"
android:gravity=
"center"
android:text=
"@string/platform_confirm"
android:text
Size=
"16sp
"
android:text
Color=
"@color/white
"
/>
android:text
Color=
"@color/white
"
android:text
Size=
"16sp
"
/>
</LinearLayout>
...
...
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