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
e6b2422b
Commit
e6b2422b
authored
Aug 13, 2019
by
阮思源
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改下加好友之后发送关键词等的逻辑
parent
233755c6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
12 deletions
+17
-12
BookGuideBizImpl.java
...a/com/pcloud/book/keywords/biz/impl/BookGuideBizImpl.java
+17
-12
No files found.
pcloud-service-book/src/main/java/com/pcloud/book/keywords/biz/impl/BookGuideBizImpl.java
View file @
e6b2422b
...
@@ -112,19 +112,24 @@ public class BookGuideBizImpl implements BookGuideBiz {
...
@@ -112,19 +112,24 @@ public class BookGuideBizImpl implements BookGuideBiz {
log
.
info
(
"[同意加好友发送欢迎语] 暗号为空 agreeAddUserDTO:{}"
,
agreeAddUserDTO
);
log
.
info
(
"[同意加好友发送欢迎语] 暗号为空 agreeAddUserDTO:{}"
,
agreeAddUserDTO
);
return
;
return
;
}
}
SendTextMessageVO
vo
=
new
SendTextMessageVO
();
vo
.
setContent
(
"你好,我是本书智能小助手,请回复你的进群暗号,获取本书资源服务,以及入群链接如果忘了进群暗号,请重新扫描书上的二维码,点击入群即可获取"
);
vo
.
setCode
(
SendMessageTypeEnum
.
SELF
.
getCode
());
vo
.
setWxId
(
agreeAddUserDTO
.
getRobotWxId
());
vo
.
setAltId
(
agreeAddUserDTO
.
getRobotWxId
());
vo
.
setWxGroupId
(
agreeAddUserDTO
.
getUserWxId
());
vo
.
setIp
(
agreeAddUserDTO
.
getIp
());
log
.
info
(
"[同意加好友发送欢迎语] : {}"
,
vo
);
WxGroupSDK
.
sendTextMessage
(
vo
);
// 根据暗号获取分类id和bookGroupId推送关键词欢迎语
final
JoinGroupCipherDTO
dto
=
joinGroupCipherDao
.
getDTOByCipher
(
cipher
);
final
JoinGroupCipherDTO
dto
=
joinGroupCipherDao
.
getDTOByCipher
(
cipher
);
List
<
KeywordDTO
>
keywords
=
bookKeywordBiz
.
listFiveKeyword
(
dto
.
getClassifyId
(),
dto
.
getBookGroupId
());
if
(
agreeAddUserDTO
.
getFirst
()
!=
null
&&
agreeAddUserDTO
.
getFirst
())
{
SendWeixinRequestTools
.
sendKeywordsInfo
(
keywords
,
agreeAddUserDTO
.
getRobotWxId
(),
agreeAddUserDTO
.
getUserWxId
(),
agreeAddUserDTO
.
getIp
());
// 如果是第一次就只发欢迎文案
SendTextMessageVO
vo
=
new
SendTextMessageVO
();
vo
.
setContent
(
"你好,我是本书智能小助手,请回复你的进群暗号,获取本书资源服务,以及入群链接如果忘了进群暗号,请重新扫描书上的二维码,点击入群即可获取"
);
vo
.
setCode
(
SendMessageTypeEnum
.
SELF
.
getCode
());
vo
.
setWxId
(
agreeAddUserDTO
.
getRobotWxId
());
vo
.
setAltId
(
agreeAddUserDTO
.
getRobotWxId
());
vo
.
setWxGroupId
(
agreeAddUserDTO
.
getUserWxId
());
vo
.
setIp
(
agreeAddUserDTO
.
getIp
());
log
.
info
(
"[同意加好友发送欢迎语] : {}"
,
vo
);
WxGroupSDK
.
sendTextMessage
(
vo
);
}
else
{
// 如果不是第一次就发关键词
// 根据暗号获取分类id和bookGroupId推送关键词欢迎语
List
<
KeywordDTO
>
keywords
=
bookKeywordBiz
.
listFiveKeyword
(
dto
.
getClassifyId
(),
dto
.
getBookGroupId
());
SendWeixinRequestTools
.
sendKeywordsInfo
(
keywords
,
agreeAddUserDTO
.
getRobotWxId
(),
agreeAddUserDTO
.
getUserWxId
(),
agreeAddUserDTO
.
getIp
());
}
// 拉群
// 拉群
final
String
wxGroupId
=
bookGroupClassifyBiz
.
getWxGroupIdByClassifyIdAndWechatId
(
dto
.
getClassifyId
(),
dto
.
getWechatUserId
());
final
String
wxGroupId
=
bookGroupClassifyBiz
.
getWxGroupIdByClassifyIdAndWechatId
(
dto
.
getClassifyId
(),
dto
.
getWechatUserId
());
final
Integer
peopleCounts
=
WxGroupSDK
.
getPeopleCounts
(
wxGroupId
,
agreeAddUserDTO
.
getRobotWxId
(),
agreeAddUserDTO
.
getIp
());
final
Integer
peopleCounts
=
WxGroupSDK
.
getPeopleCounts
(
wxGroupId
,
agreeAddUserDTO
.
getRobotWxId
(),
agreeAddUserDTO
.
getIp
());
...
...
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