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
38678631
Commit
38678631
authored
Jul 12, 2022
by
fengquan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 咨询师详情页改版
parent
aa9ca9ae
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
202 additions
and
45 deletions
+202
-45
IImService.kt
api/im/src/main/java/com/yidianling/im/api/service/IImService.kt
+6
-0
WVClickAbstractListener.java
app/src/main/java/com/ydl/component/service/web/WVClickAbstractListener.java
+11
-3
WebJavascriptHandler.kt
app/src/main/java/com/ydl/component/service/web/WebJavascriptHandler.kt
+5
-0
WebViewClientClickListener.java
app/src/main/java/com/ydl/component/service/web/WebViewClientClickListener.java
+2
-0
BasePhotoFragment.kt
m-consultant/src/main/java/com/yidianling/consultant/preview/BasePhotoFragment.kt
+8
-0
GPreviewActivity.kt
m-consultant/src/main/java/com/yidianling/consultant/preview/GPreviewActivity.kt
+41
-4
consultant_image_preview_photo.xml
m-consultant/src/main/res/layout/consultant_image_preview_photo.xml
+5
-3
IMServiceImpl.kt
m-im/src/main/java/com/yidianling/im/modular/service/IMServiceImpl.kt
+21
-0
ExpertConsultServiceItemView.kt
m-im/src/main/java/com/yidianling/uikit/custom/widget/expertConsultService/view/ExpertConsultServiceItemView.kt
+16
-1
ExpertConsultServiceListDialog2.kt
m-im/src/main/java/com/yidianling/uikit/custom/widget/expertConsultService/view/ExpertConsultServiceListDialog2.kt
+78
-32
ExpertConsultServiceView.kt
m-im/src/main/java/com/yidianling/uikit/custom/widget/expertConsultService/view/ExpertConsultServiceView.kt
+9
-2
No files found.
api/im/src/main/java/com/yidianling/im/api/service/IImService.kt
View file @
38678631
...
...
@@ -23,6 +23,7 @@ interface IImService : IProvider {
// 直接打开聊天页面,不走分配导医
fun
startChatBySessionId
(
context
:
Activity
,
toUid
:
String
)
// 打开信息前置收集页
fun
startP2PSession
(
context
:
Activity
,
location
:
Int
,
ffrom2
:
String
?)
...
...
@@ -183,4 +184,8 @@ interface IImService : IProvider {
fun
initIm
(
app
:
Application
,
activity
:
Class
<
out
Activity
>,
imInitBean
:
IMInitConfigBean
)
fun
isWifiOr3G
(
activity
:
Activity
):
Boolean
fun
showConsultServiceDialog
(
activity
:
Activity
,
toUid
:
String
,
doctorId
:
String
)
fun
dismissConsultServiceDialog
();
}
\ No newline at end of file
app/src/main/java/com/ydl/component/service/web/WVClickAbstractListener.java
View file @
38678631
...
...
@@ -23,6 +23,7 @@ import com.yidianling.muse.activity.ChooseMusicActivity;
//import static com.ydl.ydlcommon.router.IYDLRouterConstant.ROUTER_MUSE_PLAY;
import
de.greenrobot.event.EventBus
;
import
com.yidianling.im.event.CloseBottomWebviewEvent
;
import
java.util.ArrayList
;
...
...
@@ -523,13 +524,18 @@ public class WVClickAbstractListener implements WebViewClientClickListener {
.
setData
(
mThumbViewInfoList
)
.
setCurrentIndex
(
params
.
getPreview_index
())
.
setFullscreen
(
true
)
.
setToUid
(
info
.
getToUid
()
+
""
)
.
setToUid
(
info
.
getToUid
()
+
""
)
.
setDoctorId
(
info
.
getDoctorId
())
.
setType
(
GPreviewBuilder
.
IndicatorType
.
Dot
)
.
start
();
}
@Override
public
void
showDocBooking
(
H5JsBean
.
H5JsCmd
.
Params
params
)
{
ModularServiceManager
.
INSTANCE
.
provide
(
IImService
.
class
).
showConsultServiceDialog
(
mContext
,
params
.
getToUid
()
+
""
,
params
.
getDoctorId
()
+
""
);
}
@Override
public
void
switchSound
(
int
mediaId
,
long
meditationId
,
int
meditationType
,
int
businessType
,
String
buried
,
String
mediaUrl
,
String
mediaCoverUrl
,
String
title
,
String
desc
,
int
status
)
{
...
...
@@ -541,9 +547,11 @@ public class WVClickAbstractListener implements WebViewClientClickListener {
businessType
,
buried
,
mediaUrl
,
mediaCoverUrl
,
title
,
desc
,
status
);
}
}
@Override
public
void
chatCloseBottomWebView
()
{
EventBus
.
getDefault
().
post
(
new
CloseBottomWebviewEvent
(
true
));
ModularServiceManager
.
INSTANCE
.
provide
(
IImService
.
class
).
dismissConsultServiceDialog
();
}
...
...
@@ -556,8 +564,8 @@ public class WVClickAbstractListener implements WebViewClientClickListener {
@Override
public
void
setWebViewBG
(
String
rgb
,
String
alpha
)
{
if
(
mContext
instanceof
NewH5Activity
){
((
NewH5Activity
)
mContext
).
setBG
(
rgb
,
alpha
);
if
(
mContext
instanceof
NewH5Activity
)
{
((
NewH5Activity
)
mContext
).
setBG
(
rgb
,
alpha
);
}
}
}
app/src/main/java/com/ydl/component/service/web/WebJavascriptHandler.kt
View file @
38678631
...
...
@@ -465,6 +465,11 @@ class WebJavascriptHandler(private val webView: WebView?, private val wvEnventPr
wvEnventPro
?.
resourceToPreview
(
jsData
.
cmd
?.
params
)
}
"doctor_booking"
->
{
wvEnventPro
?.
showDocBooking
(
jsData
.
cmd
?.
params
)
}
}
}
}
app/src/main/java/com/ydl/component/service/web/WebViewClientClickListener.java
View file @
38678631
...
...
@@ -205,4 +205,6 @@ public interface WebViewClientClickListener {
void
switchPushStatus
(
H5JsBean
.
H5JsCmd
.
Params
params
);
void
resourceToPreview
(
H5JsBean
.
H5JsCmd
.
Params
params
);
void
showDocBooking
(
H5JsBean
.
H5JsCmd
.
Params
params
);
}
m-consultant/src/main/java/com/yidianling/consultant/preview/BasePhotoFragment.kt
View file @
38678631
...
...
@@ -382,6 +382,14 @@ class BasePhotoFragment : Fragment() {
fun
actionCancel
()
}
fun
stopVideo
()
{
if
(
videoView
!=
null
&&
videoView
!!
.
isPlaying
)
{
ivPlay
!!
.
visibility
=
VISIBLE
stopTiming
()
videoView
!!
.
pause
()
}
}
companion
object
{
/**
* 预览图片 类型
...
...
m-consultant/src/main/java/com/yidianling/consultant/preview/GPreviewActivity.kt
View file @
38678631
...
...
@@ -12,16 +12,14 @@ import androidx.fragment.app.FragmentManager
import
androidx.fragment.app.FragmentStatePagerAdapter
import
androidx.viewpager.widget.ViewPager
import
com.alibaba.android.arouter.launcher.ARouter
import
com.ydl.ydlcommon.
data.http.BaseAPIResponse
import
com.ydl.ydlcommon.
modular.ModularServiceManager
import
com.ydl.ydlcommon.utils.StatusBarUtils
import
com.yidianling.consultant.R
import
com.yidianling.consultant.preview.GPreviewBuilder.IndicatorType
import
com.yidianling.consultant.preview.SmoothImageView.onTransformListener
import
com.yidianling.im.api.service.IImService
import
io.reactivex.android.schedulers.AndroidSchedulers
import
io.reactivex.functions.Consumer
import
io.reactivex.schedulers.Schedulers
import
kotlinx.android.synthetic.main.consultant_image_preview_photo.*
import
kotlinx.android.synthetic.main.fragment_image_photo_layout.*
import
java.util.*
/**
...
...
@@ -93,11 +91,26 @@ class GPreviewActivity : AppCompatActivity() {
if
(!
toUid
.
isNullOrBlank
())
{
ARouter
.
getInstance
().
navigation
(
IImService
::
class
.
java
)
?.
startChatBySessionId
(
context
=
this
,
toUid
=
toUid
!!
)
Timer
().
schedule
(
object
:
TimerTask
()
{
override
fun
run
()
{
runOnUiThread
{
if
(
fragments
!=
null
&&
currentIndex
<
fragments
!!
.
size
)
{
fragments
!!
[
currentIndex
].
stopVideo
()
}
}
}
},
2000
)
}
}
bookingBtn
.
setOnClickListener
{
ModularServiceManager
.
provide
(
IImService
::
class
.
java
)
.
showConsultServiceDialog
(
activity
=
this
,
toUid
=
toUid
!!
,
doctorId
=
doctorId
!!
)
}
...
...
@@ -116,12 +129,34 @@ class GPreviewActivity : AppCompatActivity() {
}
override
fun
onPageSelected
(
position
:
Int
)
{
currentIndex
=
position
;
selectPosition
?.
setText
((
position
+
1
).
toString
()
+
""
)
}
override
fun
onPageScrollStateChanged
(
state
:
Int
)
{}
})
if
(
toUid
!=
null
)
{
val
unReadByUid
=
ARouter
.
getInstance
().
navigation
(
IImService
::
class
.
java
).
getUnReadByUid
(
toUid
!!
)
when
{
unReadByUid
<=
0
->
{
un_read_num_ll
.
visibility
=
View
.
GONE
}
unReadByUid
>
99
->
{
un_read_num_ll
.
visibility
=
View
.
VISIBLE
un_read_num
.
text
=
"99"
}
else
->
{
un_read_num_ll
.
visibility
=
View
.
VISIBLE
un_read_num
.
text
=
unReadByUid
.
toString
()
}
}
}
// viewPager.setOffscreenPageLimit(3);
}
...
...
@@ -136,6 +171,8 @@ class GPreviewActivity : AppCompatActivity() {
val
isScale
=
intent
.
getBooleanExtra
(
"isScale"
,
false
)
SmoothImageView
.
setIsScale
(
isScale
)
initFragment
(
imgUrls
,
currentIndex
,
BasePhotoFragment
::
class
.
java
)
}
private
fun
initFragment
(
...
...
m-consultant/src/main/res/layout/consultant_image_preview_photo.xml
View file @
38678631
...
...
@@ -25,8 +25,8 @@
android:layout_alignParentBottom=
"true"
android:layout_marginLeft=
"@dimen/platform_dp_20"
android:background=
"@drawable/consultant_bg_btn_chat"
android:text=
"立即私聊"
android:gravity=
"center"
android:text=
"立即私聊"
android:textColor=
"@color/white"
android:textSize=
"17sp"
android:textStyle=
"bold"
/>
...
...
@@ -39,26 +39,28 @@
android:layout_alignParentBottom=
"true"
android:layout_marginRight=
"@dimen/platform_dp_20"
android:background=
"@drawable/consultant_bg_btn_book"
android:text=
"立即预约"
android:gravity=
"center"
android:text=
"立即预约"
android:textColor=
"@color/white"
android:textSize=
"17sp"
android:textStyle=
"bold"
/>
<RelativeLayout
android:id=
"@+id/un_read_num_ll"
android:layout_width=
"@dimen/platform_dp_17"
android:layout_height=
"@dimen/platform_dp_17"
android:layout_alignTop=
"@+id/chatBtn"
android:layout_alignRight=
"@+id/chatBtn"
android:layout_marginTop=
"-10dp"
android:layout_marginRight=
"@dimen/platform_dp_10"
android:visibility=
"gone"
android:background=
"@drawable/consultant_bg_chat_unread_num"
>
<TextView
android:id=
"@+id/un_read_num"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerHorizontal=
"true"
android:text=
"3"
android:textColor=
"@color/white"
android:textSize=
"@dimen/sp_12"
/>
...
...
m-im/src/main/java/com/yidianling/im/modular/service/IMServiceImpl.kt
View file @
38678631
...
...
@@ -43,6 +43,7 @@ import com.yidianling.im.ui.page.NewMultiMessageFragment
import
com.yidianling.nimbase.common.media.picker.PickImageHelper
import
com.yidianling.uikit.api.NimUIKit
import
com.yidianling.uikit.business.session.helper.MessageListPanelHelper
import
com.yidianling.uikit.custom.widget.expertConsultService.view.ExpertConsultServiceListDialog2
import
io.reactivex.android.schedulers.AndroidSchedulers
import
io.reactivex.schedulers.Schedulers
...
...
@@ -53,6 +54,8 @@ import io.reactivex.schedulers.Schedulers
@Route
(
path
=
"/im/ImService"
)
class
IMServiceImpl
:
IImService
{
private
var
expertConsultServiceListDialog2
:
ExpertConsultServiceListDialog2
?=
null
override
fun
isHasUnread
():
Boolean
{
return
MsgReceiveHelper
.
isHasUnread
}
...
...
@@ -411,4 +414,21 @@ class IMServiceImpl : IImService {
override
fun
isWifiOr3G
(
activity
:
Activity
):
Boolean
{
return
NetworkUtil
.
isWifiOr3G
(
activity
)
}
override
fun
showConsultServiceDialog
(
activity
:
Activity
,
toUid
:
String
,
doctorId
:
String
)
{
// 获取专家是否在繁忙状态
if
(
activity
!=
null
)
{
expertConsultServiceListDialog2
=
ExpertConsultServiceListDialog2
(
activity
,
null
,
false
,
toUid
,
doctorId
)
expertConsultServiceListDialog2
?.
show
()
}
}
override
fun
dismissConsultServiceDialog
()
{
expertConsultServiceListDialog2
?.
changeItem
()
}
}
\ No newline at end of file
m-im/src/main/java/com/yidianling/uikit/custom/widget/expertConsultService/view/ExpertConsultServiceItemView.kt
View file @
38678631
...
...
@@ -55,6 +55,21 @@ class ExpertConsultServiceItemView : LinearLayout {
View
.
inflate
(
mContext
,
R
.
layout
.
im_expert_consult_service_item_view
,
this
)
}
fun
updateBusyStatus
(
isBusy
:
Boolean
)
{
mIsBusy
=
isBusy
if
(
mIsBusy
)
{
im_expert_service_list_btn
.
visibility
=
View
.
GONE
tv_add
.
visibility
=
View
.
VISIBLE
tv_add
.
setOnClickListener
{
mListener
?.
addTime
()
}
}
else
{
im_expert_service_list_btn
.
visibility
=
View
.
VISIBLE
tv_add
.
visibility
=
View
.
GONE
}
}
/**
* 设置数据
*/
...
...
@@ -149,7 +164,7 @@ class ExpertConsultServiceItemView : LinearLayout {
null
)
)
}
else
{
}
else
{
//新增需求,如果没有绑定手机号,跳转到绑定手机号页面
bindPhoneDialog
()
}
...
...
m-im/src/main/java/com/yidianling/uikit/custom/widget/expertConsultService/view/ExpertConsultServiceListDialog2.kt
View file @
38678631
...
...
@@ -16,20 +16,30 @@ import com.netease.nimlib.sdk.RequestCallback
import
com.netease.nimlib.sdk.msg.MessageBuilder
import
com.netease.nimlib.sdk.msg.MsgService
import
com.netease.nimlib.sdk.msg.constant.SessionTypeEnum
import
com.ydl.ydlcommon.data.http.BaseAPIResponse
import
com.ydl.ydlcommon.utils.actionutil.ActionCountUtils
import
com.yidianling.common.tools.RxDeviceTool
import
com.yidianling.common.tools.RxImageTool
import
com.yidianling.common.tools.ToastUtil
import
com.yidianling.im.R
import
com.yidianling.im.bean.BusyBean
import
com.yidianling.im.session.extension.CustomAttachSubScriptTime
import
com.yidianling.uikit.business.session.helper.MessageListPanelHelper
import
com.yidianling.uikit.custom.bridge.ActionHandlerStorage
import
com.yidianling.uikit.custom.http.ServiceImpl
import
com.yidianling.uikit.custom.http.ServiceImpl.Companion.instance
import
com.yidianling.uikit.custom.http.response.ServiceItemBean
import
com.yidianling.uikit.custom.widget.expertConsultService.callback.ConsultServiceViewCallback
import
io.reactivex.android.schedulers.AndroidSchedulers
import
io.reactivex.functions.Consumer
import
io.reactivex.schedulers.Schedulers
import
kotlinx.android.synthetic.main.im_expert_consult_service_list_dialog_layout.dialog_bottom_scroll_view
import
kotlinx.android.synthetic.main.im_expert_consult_service_list_fragment_layout.*
class
ExpertConsultServiceListDialog2
(
val
mContext
:
Context
,
val
mList
:
List
<
ServiceItemBean
>,
val
mIsBusy
:
Boolean
,
val
toUid
:
String
,
val
doctorID
:
String
)
:
BottomSheetDialogFragment
()
{
class
ExpertConsultServiceListDialog2
(
val
mContext
:
Context
,
val
mList
:
List
<
ServiceItemBean
>?,
val
mIsBusy
:
Boolean
,
val
toUid
:
String
,
val
doctorID
:
String
)
:
BottomSheetDialogFragment
()
{
private
var
mConsultServiceListView
:
ExpertConsultServiceView
?
=
null
private
var
mWebviewView
:
ExpertConsultWebview
?
=
null
...
...
@@ -37,10 +47,9 @@ class ExpertConsultServiceListDialog2(val mContext: Context, val mList: List<Ser
private
var
mSelectType
:
String
=
"全部"
var
bottomSheet
:
FrameLayout
?
=
null
private
var
behavior
:
BottomSheetBehavior
<*>?
=
null
fun
changeItem
(){
fun
changeItem
()
{
dialog_bottom_scroll_view
.
currentItem
=
0
}
...
...
@@ -55,32 +64,72 @@ class ExpertConsultServiceListDialog2(val mContext: Context, val mList: List<Ser
container
:
ViewGroup
?,
savedInstanceState
:
Bundle
?
):
View
?
{
return
inflater
.
inflate
(
R
.
layout
.
im_expert_consult_service_list_fragment_layout
,
container
,
false
)
return
inflater
.
inflate
(
R
.
layout
.
im_expert_consult_service_list_fragment_layout
,
container
,
false
)
}
override
fun
onViewCreated
(
view
:
View
,
savedInstanceState
:
Bundle
?)
{
super
.
onViewCreated
(
view
,
savedInstanceState
)
var
typeList
:
ArrayList
<
String
>
=
ArrayList
()
var
typeList
:
ArrayList
<
String
>
=
ArrayList
()
typeList
.
add
(
mSelectType
)
//默认选中
if
(
mList
!=
null
)
{
mList
.
forEach
{
item
->
typeList
.
add
(
item
.
cateName
)
}
onViewCreate
(
typeList
,
mList
)
}
else
{
ServiceImpl
.
instance
.
serviceList
(
doctorID
)
.
subscribeOn
(
Schedulers
.
io
())
.
observeOn
(
AndroidSchedulers
.
mainThread
())
.
subscribe
(
Consumer
<
BaseAPIResponse
<
List
<
ServiceItemBean
>>>
{
res
:
BaseAPIResponse
<
List
<
ServiceItemBean
>>
->
if
(
res
.
data
!=
null
&&
res
.
data
.
size
>
0
)
{
var
serviceItemBeanList
=
res
.
data
serviceItemBeanList
.
forEach
{
item
->
typeList
.
add
(
item
.
cateName
)
}
onViewCreate
(
typeList
,
serviceItemBeanList
)
// 获取专家是否在繁忙状态
instance
.
queryDoctorIsBusy
(
doctorID
)
.
subscribeOn
(
Schedulers
.
io
())
.
observeOn
(
AndroidSchedulers
.
mainThread
())
.
subscribe
(
{
res
:
BaseAPIResponse
<
BusyBean
>
->
var
isBusy
=
res
.
data
.
success
mConsultServiceListView
?.
setBusyStatus
(
isBusy
)
}
)
{
throwable
:
Throwable
?
->
}
}
else
{
ToastUtil
.
toastShort
(
"咨询师暂未发布服务"
)
}
},
Consumer
{
throwable
:
Throwable
?
->
})
}
}
mConsultServiceListView
=
ExpertConsultServiceView
(
mContext
,
mIsBusy
)
private
fun
onViewCreate
(
typeList
:
ArrayList
<
String
>,
mList
:
List
<
ServiceItemBean
>)
{
mConsultServiceListView
=
ExpertConsultServiceView
(
mContext
,
mIsBusy
)
(
mConsultServiceListView
as
ExpertConsultServiceView
).
setDataAndClick
(
typeList
,
mList
,
object
:
(
mConsultServiceListView
as
ExpertConsultServiceView
).
setDataAndClick
(
typeList
,
mList
,
object
:
ConsultServiceViewCallback
{
override
fun
onCloseClick
()
{
dismiss
()
}
override
fun
onItemClick
(
serviceBean
:
ServiceItemBean
.
ProductsBean
)
{
// if (mConsultServiceDetailView != null) {
// mConsultServiceDetailView?.updateData(serviceBean)
// dialog_bottom_scroll_view.currentItem = 1
// }
mWebviewView
?.
setData
(
serviceBean
)
dialog_bottom_scroll_view
.
currentItem
=
1
}
...
...
@@ -88,12 +137,20 @@ class ExpertConsultServiceListDialog2(val mContext: Context, val mList: List<Ser
override
fun
addTime
()
{
// 提醒添加时间回调
dismiss
()
// 埋点
ActionCountUtils
.
baiDuCountSign3
(
"ydl_user_product_page"
,
"remind_add_click"
,
toUid
,
ActionHandlerStorage
.
getL
(
toUid
).
info
.
name
,
""
)
ActionCountUtils
.
baiDuCountSign3
(
"ydl_user_product_page"
,
"remind_add_click"
,
toUid
,
ActionHandlerStorage
.
getL
(
toUid
).
info
.
name
,
""
)
// 发送提醒消息
val
customTime
=
CustomAttachSubScriptTime
(
"请尽快添加可预约时间"
)
val
message
=
MessageBuilder
.
createCustomMessage
(
toUid
,
SessionTypeEnum
.
P2P
,
"请尽快添加可预约时间"
,
customTime
)
NIMClient
.
getService
(
MsgService
::
class
.
java
).
sendMessage
(
message
,
false
).
setCallback
(
object
:
val
message
=
MessageBuilder
.
createCustomMessage
(
toUid
,
SessionTypeEnum
.
P2P
,
"请尽快添加可预约时间"
,
customTime
)
NIMClient
.
getService
(
MsgService
::
class
.
java
).
sendMessage
(
message
,
false
)
.
setCallback
(
object
:
RequestCallback
<
Void
>
{
override
fun
onSuccess
(
param
:
Void
?)
{
MessageListPanelHelper
.
getInstance
().
notifyAddMessage
(
message
)
...
...
@@ -112,24 +169,15 @@ class ExpertConsultServiceListDialog2(val mContext: Context, val mList: List<Ser
})
consult_service_dialog_close
.
setOnTouchListener
{
v
,
event
->
when
(
event
.
action
)
{
MotionEvent
.
ACTION_DOWN
->{
when
(
event
.
action
)
{
MotionEvent
.
ACTION_DOWN
->
{
behavior
?.
isHideable
=
true
}
}
true
}
mViewList
.
add
(
mConsultServiceListView
as
View
)
// mConsultServiceDetailView = ExpertConsultServiceDetailView(mContext, object : ConsultServiceViewCallback {
// override fun onBackClick() {
// dialog_bottom_scroll_view.currentItem = 0
// }
// },mIsBusy,toUid)
// mViewList.add(mConsultServiceDetailView as View)
mWebviewView
=
ExpertConsultWebview
(
mContext
,
doctorID
=
doctorID
)
mWebviewView
=
ExpertConsultWebview
(
mContext
,
doctorID
=
doctorID
)
mViewList
.
add
(
mWebviewView
as
View
)
dialog_bottom_scroll_view
.
adapter
=
ConsultServicePagerAdapter
()
...
...
@@ -137,8 +185,6 @@ class ExpertConsultServiceListDialog2(val mContext: Context, val mList: List<Ser
}
override
fun
setCancelable
(
cancelable
:
Boolean
)
{
val
dialog
=
dialog
val
touchOutsideView
=
...
...
@@ -231,7 +277,7 @@ class ExpertConsultServiceListDialog2(val mContext: Context, val mList: List<Ser
}
fun
show
()
{
if
(
mContext
is
FragmentActivity
){
if
(
mContext
is
FragmentActivity
)
{
show
(
mContext
.
supportFragmentManager
,
"consult_bottom_showdialog"
)
}
...
...
m-im/src/main/java/com/yidianling/uikit/custom/widget/expertConsultService/view/ExpertConsultServiceView.kt
View file @
38678631
...
...
@@ -4,7 +4,6 @@ import android.content.Context
import
android.util.AttributeSet
import
android.view.View
import
android.widget.LinearLayout
import
com.yidianling.avchatkit.common.log.LogUtil
import
com.yidianling.common.tools.RxDeviceTool
import
com.yidianling.im.R
import
com.yidianling.uikit.custom.http.response.ServiceItemBean
...
...
@@ -53,7 +52,6 @@ class ExpertConsultServiceView : LinearLayout {
private
fun
initView
()
{
val
mWidth
:
Int
=
RxDeviceTool
.
getScreenWidth
(
mContext
)
val
mHeight
:
Int
=
LayoutParams
.
MATCH_PARENT
...
...
@@ -68,6 +66,15 @@ class ExpertConsultServiceView : LinearLayout {
View
.
inflate
(
mContext
,
R
.
layout
.
im_expert_consult_service_view
,
this
)
}
fun
setBusyStatus
(
isBusy
:
Boolean
){
this
.
mIsBusy
=
isBusy
for
(
i
in
0
until
expert_consult_service_service_list
.
childCount
){
val
view
=
expert_consult_service_service_list
.
getChildAt
(
i
)
if
(
view
is
ExpertConsultServiceItemView
)
{
view
.
updateBusyStatus
(
mIsBusy
)
}
}
}
/**
* typeList 类型列表
* serviceList 服务列表
...
...
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