Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
midjourney-proxy
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
徐少华
midjourney-proxy
Commits
778944f9
Commit
778944f9
authored
Mar 06, 2020
by
zhuyajie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
客服接入不发唤醒熔断非关键词
parent
07acfc1d
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
4 deletions
+23
-4
DelayReceiver.java
...src/main/java/com/pcloud/book/mq/delay/DelayReceiver.java
+2
-4
PersonalStageBizImpl.java
...oud/book/personalstage/biz/impl/PersonalStageBizImpl.java
+21
-0
No files found.
pcloud-service-book/src/main/java/com/pcloud/book/mq/delay/DelayReceiver.java
View file @
778944f9
...
@@ -5,12 +5,8 @@ import com.alibaba.fastjson.JSONObject;
...
@@ -5,12 +5,8 @@ import com.alibaba.fastjson.JSONObject;
import
com.pcloud.book.personalstage.biz.PersonalStageBiz
;
import
com.pcloud.book.personalstage.biz.PersonalStageBiz
;
import
com.pcloud.book.personalstage.biz.PersonalStageJumpBiz
;
import
com.pcloud.book.personalstage.biz.PersonalStageJumpBiz
;
import
com.pcloud.book.personalstage.constant.PersonalStageConstant
;
import
com.pcloud.book.personalstage.constant.PersonalStageConstant
;
import
com.pcloud.book.personalstage.dto.WakeupDelayDTO
;
import
com.pcloud.common.core.mq.DelayQueueDTO
;
import
com.pcloud.common.core.mq.DelayQueueDTO
;
import
com.pcloud.common.core.mq.MQQueueConstants
;
import
com.pcloud.common.core.mq.MQQueueConstants
;
import
com.pcloud.common.utils.DateUtils
;
import
com.pcloud.common.utils.cache.redis.JedisClusterUtils
;
import
org.springframework.amqp.rabbit.annotation.RabbitHandler
;
import
org.springframework.amqp.rabbit.annotation.RabbitHandler
;
import
org.springframework.amqp.rabbit.annotation.RabbitListener
;
import
org.springframework.amqp.rabbit.annotation.RabbitListener
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
@@ -54,4 +50,6 @@ public class DelayReceiver {
...
@@ -54,4 +50,6 @@ public class DelayReceiver {
personalStageJumpBiz
.
delayPaper
(
dto
);
personalStageJumpBiz
.
delayPaper
(
dto
);
}
}
}
}
}
}
pcloud-service-book/src/main/java/com/pcloud/book/personalstage/biz/impl/PersonalStageBizImpl.java
View file @
778944f9
...
@@ -500,7 +500,16 @@ public class PersonalStageBizImpl implements PersonalStageBiz {
...
@@ -500,7 +500,16 @@ public class PersonalStageBizImpl implements PersonalStageBiz {
String
userWxId
=
wakeupDelayDTO
.
getWxId
();
String
userWxId
=
wakeupDelayDTO
.
getWxId
();
String
ip
=
wakeupDelayDTO
.
getIp
();
String
ip
=
wakeupDelayDTO
.
getIp
();
this
.
replacePaperUrl
(
replyItems
,
robotId
,
userWxId
,
personalStage
.
getPaperId
(),
ip
);
this
.
replacePaperUrl
(
replyItems
,
robotId
,
userWxId
,
personalStage
.
getPaperId
(),
ip
);
//判断人工客服服务状态
Boolean
state
=
false
;
Integer
serviceState
=
wechatGroupConsr
.
getServiceStateByRobotUser
(
robotId
,
userWxId
);
if
(
serviceState
==
1
){
LOGGER
.
info
(
"人工客服服务中,userWxId="
+
userWxId
+
"+robotId+"
+
robotId
);
state
=
true
;
}
if
(!
state
){
//客服介入不发唤醒
sendReplyItems
(
replyItems
,
robotId
,
userWxId
,
ip
,
wakeupDelayDTO
.
getPersonalStageUserId
());
sendReplyItems
(
replyItems
,
robotId
,
userWxId
,
ip
,
wakeupDelayDTO
.
getPersonalStageUserId
());
}
//下一个延时
//下一个延时
List
<
PersonalStageWakeup
>
wakeups
=
personalStageWakeupDao
.
getListByPersonalStageId
(
personalStageId
);
List
<
PersonalStageWakeup
>
wakeups
=
personalStageWakeupDao
.
getListByPersonalStageId
(
personalStageId
);
int
i
=
0
;
int
i
=
0
;
...
@@ -579,6 +588,12 @@ public class PersonalStageBizImpl implements PersonalStageBiz {
...
@@ -579,6 +588,12 @@ public class PersonalStageBizImpl implements PersonalStageBiz {
if
(
"重置体验"
.
equals
(
userSendContent
)){
if
(
"重置体验"
.
equals
(
userSendContent
)){
return
;
return
;
}
}
//判断人工客服服务状态
Integer
serviceState
=
wechatGroupConsr
.
getServiceStateByRobotUser
(
robotId
,
userWxId
);
if
(
serviceState
==
1
){
LOGGER
.
info
(
"人工客服服务中,userWxId="
+
userWxId
+
"+robotId+"
+
robotId
);
return
;
}
PersonalStageReply
personalStageReply
=
null
;
PersonalStageReply
personalStageReply
=
null
;
List
<
Long
>
ids
=
personalStageReplyDao
.
getIdsByRelevance
(
StageReplyRelevEnum
.
STAGE_NOT_KEYWORD
.
value
,
personalStageId
);
List
<
Long
>
ids
=
personalStageReplyDao
.
getIdsByRelevance
(
StageReplyRelevEnum
.
STAGE_NOT_KEYWORD
.
value
,
personalStageId
);
Long
replyId
=
null
;
Long
replyId
=
null
;
...
@@ -760,6 +775,12 @@ public class PersonalStageBizImpl implements PersonalStageBiz {
...
@@ -760,6 +775,12 @@ public class PersonalStageBizImpl implements PersonalStageBiz {
@ParamLog
(
"非关键词熔断回复"
)
@ParamLog
(
"非关键词熔断回复"
)
@Override
@Override
public
void
sendNotKeywordFusingReply
(
String
robotId
,
String
userWxId
,
String
ip
,
Long
personalStageId
,
Long
personalStageUserId
,
Long
paperId
)
{
public
void
sendNotKeywordFusingReply
(
String
robotId
,
String
userWxId
,
String
ip
,
Long
personalStageId
,
Long
personalStageUserId
,
Long
paperId
)
{
//判断人工客服服务状态
Integer
serviceState
=
wechatGroupConsr
.
getServiceStateByRobotUser
(
robotId
,
userWxId
);
if
(
serviceState
==
1
){
LOGGER
.
info
(
"人工客服服务中,userWxId="
+
userWxId
+
"+robotId+"
+
robotId
);
return
;
}
List
<
Long
>
ids
=
personalStageReplyDao
.
getIdsByRelevance
(
StageReplyRelevEnum
.
FUSING_NOT_KEYWORD
.
value
,
personalStageId
);
List
<
Long
>
ids
=
personalStageReplyDao
.
getIdsByRelevance
(
StageReplyRelevEnum
.
FUSING_NOT_KEYWORD
.
value
,
personalStageId
);
if
(
ListUtils
.
isEmpty
(
ids
))
{
if
(
ListUtils
.
isEmpty
(
ids
))
{
return
;
return
;
...
...
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