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
4297cd9a
Commit
4297cd9a
authored
Jul 20, 2022
by
YKai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 首页导医入口叠加,不显示问题修复
parent
6eeadfb6
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
36 deletions
+17
-36
ExpertSearchFragment.kt
m-consultant/src/main/java/com/yidianling/consultant/ExpertSearchFragment.kt
+0
-2
ConsultAssistantDialogUtils.kt
m-consultant/src/main/java/com/yidianling/consultant/modular/singlton/ConsultAssistantDialogUtils.kt
+17
-18
YdlHomeFragment.kt
m-home/src/ydl/java/com/yidianling/home/ui/fragment/YdlHomeFragment.kt
+0
-8
MineFragment.kt
m-user/src/main/java/com/yidianling/user/mine/MineFragment.kt
+0
-8
No files found.
m-consultant/src/main/java/com/yidianling/consultant/ExpertSearchFragment.kt
View file @
4297cd9a
...
...
@@ -308,9 +308,7 @@ class ExpertSearchFragment : BaseMvpFragment<IExpertSearchView, ExpertSearchPres
super
.
setUserVisibleHint
(
isVisibleToUser
)
if
(
isVisibleToUser
&&
isResumed
)
{
startTime
=
System
.
currentTimeMillis
()
showConsultAssistantDialog
()
}
else
{
hideConsultAssistantDialog
()
if
(
startTime
!=
0L
)
{
endTime
=
System
.
currentTimeMillis
()
ActionCountUtils
.
count
(
...
...
m-consultant/src/main/java/com/yidianling/consultant/modular/singlton/ConsultAssistantDialogUtils.kt
View file @
4297cd9a
...
...
@@ -40,8 +40,9 @@ class ConsultAssistantDialogUtils private constructor() {
var
consultAssistantDialogFromHomePage
:
ConsultAssistantDialog
?
=
null
// 首页展示的dialog
var
consultAssistantDialogFromMine
:
ConsultAssistantDialog
?
=
null
// 我的展示的dialog
var
consultAssistantFragmentDialog
:
ConsultAssistantDialog
?
=
null
//咨询师列表fragment页面展示的dialog
var
expertSearchPageHasShown
:
Boolean
=
false
// 专家咨询列表fragment页面是否已经展示
var
consultAssistantActivityDialog
:
ConsultAssistantDialog
?
=
null
//咨询师列表activity页面展示的dialog
var
expertSearchPageHasShown
:
Boolean
=
false
// 专家咨询列表fragment页面是否已经展示
var
confideListDialog
:
ConsultAssistantDialog
?
=
null
//倾诉列表activity页面展示的dialog
var
expertSearchActivityPageHasShown
:
Boolean
=
false
// 专家咨询列表activity页面是否已经展示
...
...
@@ -86,22 +87,20 @@ class ConsultAssistantDialogUtils private constructor() {
origin
:
String
,
fromActivity
:
Boolean
=
false
)
{
// 请求接口判断导医咨询助理按钮是否展示
SearchApi
.
getSearchApi
().
getConsultAssistantRequest
(
origin
)
.
subscribeOn
(
Schedulers
.
io
())
.
observeOn
(
AndroidSchedulers
.
mainThread
())
.
subscribe
{
if
(
it
.
data
)
{
if
(
origin
==
"home_index"
)
{
showFromYdlHome
(
activity
)
}
else
if
(
origin
==
"doctor_list"
)
{
show
(
activity
,
origin
,
fromActivity
)
}
else
if
(
origin
==
"mine_index"
)
{
showFromMine
(
activity
)
}
}
consultAssistantDialogFromHomePage
?.
dismiss
()
consultAssistantFragmentDialog
?.
dismiss
()
consultAssistantDialogFromMine
?.
dismiss
()
when
(
origin
)
{
"home_index"
->
{
showFromYdlHome
(
activity
)
}
"doctor_list"
->
{
show
(
activity
,
origin
,
fromActivity
)
}
"mine_index"
->
{
showFromMine
(
activity
)
}
}
}
////////////////////////////////////// 首页的展示隐藏逻辑 代码块start ///////////////////////////////////////////////////
...
...
@@ -109,7 +108,7 @@ class ConsultAssistantDialogUtils private constructor() {
/**
* 首页页展示
*/
fun
showFromYdlHome
(
activity
:
Activity
)
{
private
fun
showFromYdlHome
(
activity
:
Activity
)
{
if
(!
activity
.
isFinishing
)
{
if
(
consultAssistantDialogFromHomePage
==
null
)
{
consultAssistantDialogFromHomePage
=
ConsultAssistantDialog
(
...
...
@@ -268,7 +267,7 @@ class ConsultAssistantDialogUtils private constructor() {
/**
* 咨询师列表页展示浮层
*/
fun
showDialog
(
origin
:
String
,
activity
:
Activity
,
fromActivity
:
Boolean
=
false
)
{
private
fun
showDialog
(
origin
:
String
,
activity
:
Activity
,
fromActivity
:
Boolean
=
false
)
{
if
(!
fromActivity
)
{
if
(!
activity
.
isFinishing
)
{
if
(
consultAssistantFragmentDialog
==
null
)
{
...
...
m-home/src/ydl/java/com/yidianling/home/ui/fragment/YdlHomeFragment.kt
View file @
4297cd9a
...
...
@@ -491,9 +491,7 @@ open class YdlHomeFragment : BaseMvpFragment<IHomeContract.View, HomePresenterIm
super
.
setUserVisibleHint
(
isVisibleToUser
)
if
(
isVisibleToUser
&&
isResumed
)
{
startTime
=
System
.
currentTimeMillis
()
showConsultAssistantDialog
()
}
else
{
hideConsultAssistantDialog
()
if
(
startTime
!=
0L
){
endTime
=
System
.
currentTimeMillis
()
ActionCountUtils
.
count
(
HomeBIConstants
.
YDL_HOME_DWELL_TIME
,(
endTime
-
startTime
).
toString
())
...
...
@@ -506,11 +504,6 @@ open class YdlHomeFragment : BaseMvpFragment<IHomeContract.View, HomePresenterIm
}
}
private
fun
showConsultAssistantDialog
()
{
ModularServiceManager
.
provide
(
IConsultantService
::
class
.
java
)
.
showConsultAssistantDialog
(
mActivity
)
}
private
fun
getBottomWord
()
{
ModularServiceManager
.
provide
(
IConsultantService
::
class
.
java
)
.
getbottomWord
(
2
,
object
:
OnBottomWordListener
{
...
...
@@ -558,7 +551,6 @@ open class YdlHomeFragment : BaseMvpFragment<IHomeContract.View, HomePresenterIm
}
ActionCountUtils
.
count
(
HomeBIConstants
.
YDL_USER_MAIN_PAGE_VISIT
)
ActionCountUtils
.
count
(
"daoyi_advertisement_page|daoyi_advertisement_visit"
,
"1"
)
showConsultAssistantDialog
()
video_view
?.
setOnInfoListener
{
mp
,
what
,
extra
->
if
(
what
==
MediaPlayer
.
MEDIA_INFO_VIDEO_RENDERING_START
){
...
...
m-user/src/main/java/com/yidianling/user/mine/MineFragment.kt
View file @
4297cd9a
...
...
@@ -158,7 +158,6 @@ class MineFragment : BaseFragment(), SwipeRefreshLayout.OnRefreshListener, View.
endTime
=
System
.
currentTimeMillis
()
count
(
UserMyPageEvent
.
YDL_USER_MY_PAGE_STAY_VISIT
,
(
endTime
-
startTime
).
toString
())
}
hideConsultAssistantDialog
()
}
if
(
isVisibleToUser
&&
isResumed
)
{
onResume
()
...
...
@@ -175,13 +174,6 @@ class MineFragment : BaseFragment(), SwipeRefreshLayout.OnRefreshListener, View.
private
fun
showConsultAssistantDialog
()
{
count
(
"daoyi_advertisement_page|daoyi_advertisement_visit"
,
"4"
)
mActivity
?.
let
{
provide
(
IConsultantService
::
class
.
java
).
showConsultAssistantMineDialog
(
it
)
}
}
private
fun
hideConsultAssistantDialog
()
{
provide
(
IConsultantService
::
class
.
java
).
hideConsultAssistantMineDialog
()
}
/**
...
...
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