Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-manage3.0
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
haoban3.0
haoban-manage3.0
Commits
35d5fcc2
Commit
35d5fcc2
authored
Dec 06, 2022
by
徐高华
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sql
parent
349a6fce
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
56 additions
and
41 deletions
+56
-41
GroupChatPlanOwnerLogService.java
...ge/service/service/chat/GroupChatPlanOwnerLogService.java
+4
-0
GroupChatPlanOwnerLogServiceImpl.java
...e/service/chat/impl/GroupChatPlanOwnerLogServiceImpl.java
+6
-0
GroupChatPlanServiceImpl.java
...e/service/service/chat/impl/GroupChatPlanServiceImpl.java
+44
-40
GroupChatPlanLogMapper.xml
...src/main/resources/mapper/chat/GroupChatPlanLogMapper.xml
+2
-1
No files found.
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/chat/GroupChatPlanOwnerLogService.java
View file @
35d5fcc2
package
com
.
gic
.
haoban
.
manage
.
service
.
service
.
chat
;
package
com
.
gic
.
haoban
.
manage
.
service
.
service
.
chat
;
import
java.util.Date
;
import
java.util.Date
;
import
java.util.List
;
import
com.gic.api.base.commons.BasePageInfo
;
import
com.gic.api.base.commons.BasePageInfo
;
import
com.gic.api.base.commons.Page
;
import
com.gic.api.base.commons.Page
;
...
@@ -18,5 +19,7 @@ public interface GroupChatPlanOwnerLogService {
...
@@ -18,5 +19,7 @@ public interface GroupChatPlanOwnerLogService {
public
Page
<
GroupChatPlanOwnerLogDTO
>
listPage
(
Long
planId
,
GroupChatPlanSearchQDTO
qdto
,
public
Page
<
GroupChatPlanOwnerLogDTO
>
listPage
(
Long
planId
,
GroupChatPlanSearchQDTO
qdto
,
BasePageInfo
basePageInfo
);
BasePageInfo
basePageInfo
);
List
<
TabGroupChatPlanOwnerLog
>
listForTimer
()
;
}
}
\ No newline at end of file
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/chat/impl/GroupChatPlanOwnerLogServiceImpl.java
View file @
35d5fcc2
...
@@ -133,5 +133,10 @@ public class GroupChatPlanOwnerLogServiceImpl implements GroupChatPlanOwnerLogSe
...
@@ -133,5 +133,10 @@ public class GroupChatPlanOwnerLogServiceImpl implements GroupChatPlanOwnerLogSe
}
}
this
.
groupChatPlanOwnerLogMapper
.
insert
(
log
);
this
.
groupChatPlanOwnerLogMapper
.
insert
(
log
);
}
}
@Override
public
List
<
TabGroupChatPlanOwnerLog
>
listForTimer
()
{
return
null
;
}
}
}
\ No newline at end of file
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/chat/impl/GroupChatPlanServiceImpl.java
View file @
35d5fcc2
...
@@ -153,51 +153,55 @@ public class GroupChatPlanServiceImpl implements GroupChatPlanService {
...
@@ -153,51 +153,55 @@ public class GroupChatPlanServiceImpl implements GroupChatPlanService {
@Override
@Override
public
void
doPlanSendInfoTimer
(
String
params
)
{
public
void
doPlanSendInfoTimer
(
String
params
)
{
Long
owner_log_id
=
472092751301763073L
;
List
<
TabGroupChatPlanOwnerLog
>
logList
=
this
.
groupChatPlanOwnerLogService
.
listForTimer
()
;
TabGroupChatPlanOwnerLog
ownerLog
=
this
.
groupChatPlanOwnerLogService
.
getById
(
owner_log_id
);
for
(
TabGroupChatPlanOwnerLog
log
:
logList
)
{
String
wxEnterpriseId
=
ownerLog
.
getWxEnterpriseId
();
Long
ownerLogId
=
log
.
getOwnerLogId
();
String
enterpriseId
=
ownerLog
.
getEnterpriseId
();
TabGroupChatPlanOwnerLog
ownerLog
=
this
.
groupChatPlanOwnerLogService
.
getById
(
ownerLogId
);
String
msgid
=
ownerLog
.
getMsgid
();
String
wxEnterpriseId
=
ownerLog
.
getWxEnterpriseId
();
WxEnterpriseQwDTO
qwDTO
=
this
.
wxEnterpriseService
.
getQwInfo
(
wxEnterpriseId
);
String
enterpriseId
=
ownerLog
.
getEnterpriseId
();
if
(
qwDTO
!=
null
)
{
String
msgid
=
ownerLog
.
getMsgid
();
}
WxEnterpriseQwDTO
qwDTO
=
this
.
wxEnterpriseService
.
getQwInfo
(
wxEnterpriseId
);
if
(
qwDTO
!=
null
)
{
}
String
staffId
=
ownerLog
.
getStaffId
();
String
staffId
=
ownerLog
.
getStaffId
();
TabHaobanStaff
staff
=
this
.
staffMapper
.
selectByPrimaryKey
(
staffId
);
TabHaobanStaff
staff
=
this
.
staffMapper
.
selectByPrimaryKey
(
staffId
);
String
userid
=
staff
.
getWxUserId
();
String
userid
=
staff
.
getWxUserId
();
if
(
qwDTO
.
needOpenUserId3th
())
{
if
(
qwDTO
.
needOpenUserId3th
())
{
userid
=
staff
.
getWxOpenUseId
();
userid
=
staff
.
getWxOpenUseId
();
}
}
JSONResponse
respon
=
qywxSuiteApiService
.
resultExternalMessage
(
qwDTO
.
getThirdCorpid
(),
config
.
getWxSuiteid
(),
JSONResponse
respon
=
qywxSuiteApiService
.
resultExternalMessage
(
qwDTO
.
getThirdCorpid
(),
config
.
getWxSuiteid
(),
msgid
,
null
,
userid
);
msgid
,
null
,
userid
);
logger
.
info
(
JSON
.
toJSONString
(
respon
));
logger
.
info
(
JSON
.
toJSONString
(
respon
));
if
(
respon
.
getErrorCode
()
==
0
)
{
if
(
respon
.
getErrorCode
()
==
0
)
{
List
<
QywxSendMessageResultDTO
>
list
=
(
List
<
QywxSendMessageResultDTO
>)
respon
.
getList
();
List
<
QywxSendMessageResultDTO
>
list
=
(
List
<
QywxSendMessageResultDTO
>)
respon
.
getList
();
if
(
CollectionUtils
.
isNotEmpty
(
list
))
{
if
(
CollectionUtils
.
isNotEmpty
(
list
))
{
int
sendCount
=
list
.
size
();
int
sendCount
=
list
.
size
();
this
.
groupChatPlanOwnerLogService
.
updateSendCount
(
ownerLog
.
getOwnerLogId
(),
sendCount
,
this
.
groupChatPlanOwnerLogService
.
updateSendCount
(
ownerLog
.
getOwnerLogId
(),
sendCount
,
list
.
get
(
0
).
getSendTime
());
list
.
get
(
0
).
getSendTime
());
for
(
QywxSendMessageResultDTO
item
:
list
)
{
for
(
QywxSendMessageResultDTO
item
:
list
)
{
String
wxChatId3th
=
item
.
getChatId
();
String
wxChatId3th
=
item
.
getChatId
();
Date
sendTime
=
item
.
getSendTime
();
Date
sendTime
=
item
.
getSendTime
();
TabGroupChatPlanLog
entity
=
new
TabGroupChatPlanLog
();
TabGroupChatPlanLog
entity
=
new
TabGroupChatPlanLog
();
entity
.
setLogId
(
UniqueIdUtils
.
uniqueLong
());
entity
.
setLogId
(
UniqueIdUtils
.
uniqueLong
());
entity
.
setPlanId
(
ownerLog
.
getPlanId
());
entity
.
setPlanId
(
ownerLog
.
getPlanId
());
entity
.
setOwnLogId
(
ownerLog
.
getOwnerLogId
());
entity
.
setOwnLogId
(
ownerLog
.
getOwnerLogId
());
entity
.
setWxEnterpriseId
(
wxEnterpriseId
);
entity
.
setWxEnterpriseId
(
wxEnterpriseId
);
entity
.
setEnterpriseId
(
enterpriseId
);
entity
.
setEnterpriseId
(
enterpriseId
);
entity
.
setWxChatId3th
(
wxChatId3th
);
entity
.
setWxChatId3th
(
wxChatId3th
);
GroupChatBO
chat
=
this
.
groupChatService
.
getByWxChatId3th
(
wxEnterpriseId
,
wxChatId3th
);
entity
.
setStaffId
(
staffId
);
if
(
null
!=
chat
)
{
GroupChatBO
chat
=
this
.
groupChatService
.
getByWxChatId3th
(
wxEnterpriseId
,
wxChatId3th
);
entity
.
setGroupChatId
(
chat
.
getGroupChatId
());
if
(
null
!=
chat
)
{
entity
.
setGroupChatId
(
chat
.
getGroupChatId
());
}
entity
.
setSendTime
(
sendTime
);
entity
.
setSendStatus
(
1
);
this
.
groupChatPlanLogMapper
.
insert
(
entity
);
}
}
entity
.
setSendTime
(
sendTime
);
entity
.
setSendStatus
(
1
);
this
.
groupChatPlanLogMapper
.
insert
(
entity
);
}
}
}
}
}
}
}
}
...
...
haoban-manage3-service/src/main/resources/mapper/chat/GroupChatPlanLogMapper.xml
View file @
35d5fcc2
...
@@ -80,6 +80,6 @@
...
@@ -80,6 +80,6 @@
LEFT JOIN tab_haoban_group_chat_plan_owner_log b ON a.`own_log_id` = b.`owner_log_id`
LEFT JOIN tab_haoban_group_chat_plan_owner_log b ON a.`own_log_id` = b.`owner_log_id`
LEFT JOIN tab_haoban_staff c ON a.`staff_id` = c.`staff_id`
LEFT JOIN tab_haoban_staff c ON a.`staff_id` = c.`staff_id`
LEFT JOIN tab_haoban_group_chat d ON a.group_chat_id = d.group_chat_id
LEFT JOIN tab_haoban_group_chat d ON a.group_chat_id = d.group_chat_id
where a.wx_enterprise_id = #{wxEnterpriseId} and plan_id = #{planId}
where a.wx_enterprise_id = #{wxEnterpriseId} and
a.
plan_id = #{planId}
</select>
</select>
</mapper>
</mapper>
\ No newline at end of file
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