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
03e4a5ff
Commit
03e4a5ff
authored
Jan 26, 2021
by
YKai
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/4.1.66' into 4.1.66
parents
7cab7a2b
3dda4550
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
109 additions
and
0 deletions
+109
-0
SessionHelper.java
m-im/src/main/java/com/yidianling/im/session/SessionHelper.java
+3
-0
CustomAttachParser.java
m-im/src/main/java/com/yidianling/im/session/extension/CustomAttachParser.java
+4
-0
CustomAttachmentSwitchKeFuTips.java
m-im/src/main/java/com/yidianling/im/session/extension/CustomAttachmentSwitchKeFuTips.java
+37
-0
CustomAttachmentType.java
m-im/src/main/java/com/yidianling/im/session/extension/CustomAttachmentType.java
+1
-0
MsgViewHolderSwitchKeFuTips.java
m-im/src/main/java/com/yidianling/im/session/viewholder/MsgViewHolderSwitchKeFuTips.java
+38
-0
im_nim_switch_kefu_tips.xml
m-im/src/main/res/layout/im_nim_switch_kefu_tips.xml
+21
-0
im_kefu_tips_bg.xml
m-im/src/main/res_avchat/drawable/im_kefu_tips_bg.xml
+5
-0
No files found.
m-im/src/main/java/com/yidianling/im/session/SessionHelper.java
View file @
03e4a5ff
...
...
@@ -63,6 +63,7 @@ import com.yidianling.im.session.extension.CustomAttachmentReceivedTimeout;
import
com.yidianling.im.session.extension.CustomAttachmentRecommendAssistant
;
import
com.yidianling.im.session.extension.CustomAttachmentRedStatus
;
import
com.yidianling.im.session.extension.CustomAttachmentShareMsg
;
import
com.yidianling.im.session.extension.CustomAttachmentSwitchKeFuTips
;
import
com.yidianling.im.session.extension.CustomAttachmentTest
;
import
com.yidianling.im.session.extension.CustomCustomerServiceCardAttachment
;
import
com.yidianling.im.session.extension.CustomRecommendExpertListMsg
;
...
...
@@ -97,6 +98,7 @@ import com.yidianling.im.session.viewholder.MsgViewHolderSendTest;
import
com.yidianling.im.session.viewholder.MsgViewHolderShareMsg
;
import
com.yidianling.im.session.viewholder.MsgViewHolderSticker
;
import
com.yidianling.im.session.viewholder.MsgViewHolderSubscriptTime
;
import
com.yidianling.im.session.viewholder.MsgViewHolderSwitchKeFuTips
;
import
com.yidianling.im.session.viewholder.MsgViewHolderSystemTips
;
import
com.yidianling.im.session.viewholder.MsgViewHolderTip
;
import
com.yidianling.im.ui.param.BuryRedPointParam
;
...
...
@@ -454,6 +456,7 @@ public class SessionHelper {
NimUIKit
.
registerMsgItemViewHolder
(
CustomAttachAssistantReceivedMoney
.
class
,
MsgViewHolderAssistantReceivedMoney
.
class
);
NimUIKit
.
registerMsgItemViewHolder
(
CustomAttachmentBusinessCard
.
class
,
MsgViewHolderBusinessCard
.
class
);
//专家自定义名片 ,TYPE=34
NimUIKit
.
registerMsgItemViewHolder
(
CustomAttachmentJumpToDaoYi
.
class
,
MsgViewHolderJumpToDaoYi
.
class
);
//跳转导医聊天窗口触发导医分配逻辑,TYPE=35
NimUIKit
.
registerMsgItemViewHolder
(
CustomAttachmentSwitchKeFuTips
.
class
,
MsgViewHolderSwitchKeFuTips
.
class
);
//客服转介需求,TYPE=40
}
private
static
void
setSessionListener
()
{
...
...
m-im/src/main/java/com/yidianling/im/session/extension/CustomAttachParser.java
View file @
03e4a5ff
...
...
@@ -126,6 +126,10 @@ public class CustomAttachParser implements MsgAttachmentParser {
//跳转导医聊天界面
attachment
=
new
CustomAttachmentJumpToDaoYi
();
break
;
case
CustomAttachmentType
.
TYPE_SWITCH_KEFU_TIPS
:
//客服转介需求
attachment
=
new
CustomAttachmentSwitchKeFuTips
();
break
;
default
:
attachment
=
new
DefaultCustomAttachment
();
break
;
...
...
m-im/src/main/java/com/yidianling/im/session/extension/CustomAttachmentSwitchKeFuTips.java
0 → 100644
View file @
03e4a5ff
package
com
.
yidianling
.
im
.
session
.
extension
;
import
com.alibaba.fastjson.JSONObject
;
/**
* @author huozhiliang
* @描述:
* @Copyright Copyright (c) 2018
* @Company 壹点灵
* @date 2021/1/26
*/
public
class
CustomAttachmentSwitchKeFuTips
extends
CustomAttachment
{
private
static
final
String
HIDDEN_APP
=
"hidden_app"
;
private
static
final
String
TO_CONTENT
=
"to_content"
;
public
String
hidden_app
;
public
String
to_content
;
public
CustomAttachmentSwitchKeFuTips
()
{
super
(
CustomAttachmentType
.
TYPE_SWITCH_KEFU_TIPS
);
}
@Override
protected
void
parseData
(
JSONObject
data
)
{
hidden_app
=
data
.
getString
(
HIDDEN_APP
);
to_content
=
data
.
getString
(
TO_CONTENT
);
}
@Override
protected
JSONObject
packData
()
{
JSONObject
data
=
new
JSONObject
();
data
.
put
(
HIDDEN_APP
,
hidden_app
);
data
.
put
(
TO_CONTENT
,
to_content
);
return
data
;
}
}
m-im/src/main/java/com/yidianling/im/session/extension/CustomAttachmentType.java
View file @
03e4a5ff
...
...
@@ -37,4 +37,5 @@ public interface CustomAttachmentType {
int
ASSISTANT_RECEIVEDMONEY
=
33
;
//发起收款
int
TYPE_EXPERT_DETAIL_CARD
=
34
;
//专家名片
int
TYPE_JUMPTO_DAOYI
=
35
;
//跳转导医聊天界面
int
TYPE_SWITCH_KEFU_TIPS
=
40
;
//客服切换第一次提示语
}
m-im/src/main/java/com/yidianling/im/session/viewholder/MsgViewHolderSwitchKeFuTips.java
0 → 100644
View file @
03e4a5ff
package
com
.
yidianling
.
im
.
session
.
viewholder
;
import
android.widget.TextView
;
import
com.yidianling.im.R
;
import
com.yidianling.im.session.extension.CustomAttachmentSwitchKeFuTips
;
import
com.yidianling.nimbase.common.ui.recyclerview.adapter.BaseMultiItemFetchLoadAdapter
;
import
com.yidianling.uikit.business.session.viewholder.MsgViewHolderBase
;
/**
* @author huozhiliang
* @描述:
* @Copyright Copyright (c) 2018
* @Company 壹点灵
* @date 2021/1/26
*/
public
class
MsgViewHolderSwitchKeFuTips
extends
MsgViewHolderBase
{
private
TextView
textViewTips
;
public
MsgViewHolderSwitchKeFuTips
(
BaseMultiItemFetchLoadAdapter
adapter
)
{
super
(
adapter
);
}
@Override
protected
int
getContentResId
()
{
return
R
.
layout
.
im_nim_switch_kefu_tips
;
}
@Override
protected
void
inflateContentView
()
{
textViewTips
=
findViewById
(
R
.
id
.
tips_kefu
);
}
@Override
protected
void
bindContentView
()
{
CustomAttachmentSwitchKeFuTips
customBusinessCard
=
(
CustomAttachmentSwitchKeFuTips
)
message
.
getAttachment
();
textViewTips
.
setText
(
customBusinessCard
.
to_content
);
}
}
m-im/src/main/res/layout/im_nim_switch_kefu_tips.xml
0 → 100644
View file @
03e4a5ff
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:orientation=
"vertical"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:gravity=
"center_horizontal"
>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:background=
"@drawable/im_kefu_tips_bg"
android:paddingTop=
"3dp"
android:paddingBottom=
"@dimen/platform_dp_3"
android:paddingLeft=
"@dimen/platform_dp_2"
android:paddingRight=
"@dimen/platform_dp_2"
android:id=
"@+id/tips_kefu"
android:text=
"将为您服务"
/>
</LinearLayout>
\ No newline at end of file
m-im/src/main/res_avchat/drawable/im_kefu_tips_bg.xml
0 → 100644
View file @
03e4a5ff
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android=
"http://schemas.android.com/apk/res/android"
>
<solid
android:color=
"#30999999"
/>
<corners
android:radius=
"@dimen/platform_dp_10"
/>
</shape>
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