Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in
Toggle navigation
F
feo-jobs
Project
Project
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
探普后端
feo-jobs
Commits
3f18c112
Commit
3f18c112
authored
Aug 11, 2021
by
吴泽佳
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
早报 访问链接修改
parent
8ff7a179
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
3 deletions
+8
-3
DaySubJob.java
src/main/java/com/tanpu/feo/feojob/jobs/DaySubJob.java
+8
-3
No files found.
src/main/java/com/tanpu/feo/feojob/jobs/DaySubJob.java
View file @
3f18c112
...
@@ -110,15 +110,17 @@ public class DaySubJob {
...
@@ -110,15 +110,17 @@ public class DaySubJob {
parmMap
.
put
(
"type"
,
"text"
);
parmMap
.
put
(
"type"
,
"text"
);
StringBuilder
sb
=
new
StringBuilder
();
StringBuilder
sb
=
new
StringBuilder
();
sb
.
append
(
mainTitle
).
append
(
"\n\n"
)
sb
.
append
(
mainTitle
).
append
(
"\n\n"
)
.
append
(
morningPaperProperties
.
getSubTitle
()).
append
(
"\n\n"
)
.
append
(
morningPaperProperties
.
getSubTitle
()).
append
(
"\n\n"
);
.
append
(
"<a href=\""
).
append
(
daySubjectUrl
).
append
(
daySubjectEntity
.
getId
()).
append
(
"\">"
).
append
(
"快去转发获客吧"
).
append
(
"</a>\n\n"
);
parmMap
.
put
(
"content"
,
sb
.
toString
());
String
wxOpenId
=
userInfoEntity
.
getUiOpenid
();
String
wxOpenId
=
userInfoEntity
.
getUiOpenid
();
String
wxcpUId
=
userInfoEntity
.
getWxcpUid
();
String
wxcpUId
=
userInfoEntity
.
getWxcpUid
();
if
(
StringUtils
.
isNotBlank
(
wxcpUId
))
{
if
(
StringUtils
.
isNotBlank
(
wxcpUId
))
{
// 1 企业微信 推送
// 1 企业微信 推送
String
agentId
=
jsonKeyInfo
.
getStr
(
"agentId"
);
String
agentId
=
jsonKeyInfo
.
getStr
(
"agentId"
);
String
corpId
=
jsonKeyInfo
.
getStr
(
"corpId"
);
String
corpId
=
jsonKeyInfo
.
getStr
(
"corpId"
);
// ww=corpId&orgCode=orgId
sb
.
append
(
String
.
format
(
daySubjectUrl
,
corpId
,
orgId
,
daySubjectEntity
.
getId
())).
append
(
"\">"
).
append
(
"快去转发获客吧"
).
append
(
"</a>\n\n"
);
parmMap
.
put
(
"content"
,
sb
.
toString
());
log
.
info
(
"===企业微信 推送===userID:{} agentId:{} corpId:{} wxcpUId:{} parmMap:{}"
,
userInfoEntity
.
getId
()
,
agentId
,
corpId
,
wxcpUId
,
JSONUtil
.
toJsonStr
(
parmMap
));
log
.
info
(
"===企业微信 推送===userID:{} agentId:{} corpId:{} wxcpUId:{} parmMap:{}"
,
userInfoEntity
.
getId
()
,
agentId
,
corpId
,
wxcpUId
,
JSONUtil
.
toJsonStr
(
parmMap
));
if
(
StrUtil
.
isNotBlank
(
agentId
)
&&
StrUtil
.
isNotBlank
(
corpId
)
&&
StrUtil
.
isNotBlank
(
wxcpUId
)
&&
StrUtil
.
isNotBlank
(
JSONUtil
.
toJsonStr
(
parmMap
)))
{
if
(
StrUtil
.
isNotBlank
(
agentId
)
&&
StrUtil
.
isNotBlank
(
corpId
)
&&
StrUtil
.
isNotBlank
(
wxcpUId
)
&&
StrUtil
.
isNotBlank
(
JSONUtil
.
toJsonStr
(
parmMap
)))
{
feignClientForWxCp
.
sendMessage
(
agentId
,
corpId
,
wxcpUId
,
JSONUtil
.
toJsonStr
(
parmMap
));
feignClientForWxCp
.
sendMessage
(
agentId
,
corpId
,
wxcpUId
,
JSONUtil
.
toJsonStr
(
parmMap
));
...
@@ -127,6 +129,9 @@ public class DaySubJob {
...
@@ -127,6 +129,9 @@ public class DaySubJob {
if
(
StringUtils
.
isNotBlank
(
wxOpenId
))
{
if
(
StringUtils
.
isNotBlank
(
wxOpenId
))
{
// 2 公众号推送
// 2 公众号推送
String
wxAppID
=
jsonKeyInfo
.
getStr
(
"sendMessageAppId"
);
String
wxAppID
=
jsonKeyInfo
.
getStr
(
"sendMessageAppId"
);
// ww=wxAppID&orgCode=orgId
sb
.
append
(
"<a href=\""
).
append
(
String
.
format
(
daySubjectUrl
,
wxAppID
,
orgId
,
daySubjectEntity
.
getId
())).
append
(
"\">"
).
append
(
"快去转发获客吧"
).
append
(
"</a>\n\n"
);
parmMap
.
put
(
"content"
,
sb
.
toString
());
log
.
info
(
"===公众号 推送=== userID:{} wxAppID:{} wxOpenId:{} parmMap:{}"
,
userInfoEntity
.
getId
()
,
wxAppID
,
wxOpenId
,
JSONUtil
.
toJsonStr
(
parmMap
));
log
.
info
(
"===公众号 推送=== userID:{} wxAppID:{} wxOpenId:{} parmMap:{}"
,
userInfoEntity
.
getId
()
,
wxAppID
,
wxOpenId
,
JSONUtil
.
toJsonStr
(
parmMap
));
if
(
StrUtil
.
isNotBlank
(
wxAppID
)
&&
StrUtil
.
isNotBlank
(
wxOpenId
)
&&
StrUtil
.
isNotBlank
(
JSONUtil
.
toJsonStr
(
parmMap
)))
{
if
(
StrUtil
.
isNotBlank
(
wxAppID
)
&&
StrUtil
.
isNotBlank
(
wxOpenId
)
&&
StrUtil
.
isNotBlank
(
JSONUtil
.
toJsonStr
(
parmMap
)))
{
feignClientForWxMp
.
sendMessage
(
wxAppID
,
wxOpenId
,
JSONUtil
.
toJsonStr
(
parmMap
));
feignClientForWxMp
.
sendMessage
(
wxAppID
,
wxOpenId
,
JSONUtil
.
toJsonStr
(
parmMap
));
...
...
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