Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
O
operate-customer-service
概览
概览
详情
活动
周期分析
版本库
存储库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
沈振路
operate-customer-service
Commits
cac45307
提交
cac45307
authored
11月 17, 2025
作者:
沈振路
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
客服消息发送适配“番茄小程序”
上级
3bc6faa8
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
10 行增加
和
3 行删除
+10
-3
CustomerServiceCommonAsyncComponent.java
...tomer/components/CustomerServiceCommonAsyncComponent.java
+2
-1
CustomerGraphicsServiceImpl.java
...zw/customer/service/impl/CustomerGraphicsServiceImpl.java
+8
-2
没有找到文件。
src/main/java/com/yaoyaozw/customer/components/CustomerServiceCommonAsyncComponent.java
浏览文件 @
cac45307
...
@@ -272,7 +272,8 @@ public class CustomerServiceCommonAsyncComponent {
...
@@ -272,7 +272,8 @@ public class CustomerServiceCommonAsyncComponent {
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
LOCAL_LOG
.
warn
(
"公众号: {} 获取链接异常: {}"
,
authInfoVo
.
getAccountName
(),
e
.
getMessage
());
LOCAL_LOG
.
warn
(
"公众号: {} 获取链接异常: {}"
,
authInfoVo
.
getAccountName
(),
e
.
getMessage
());
}
}
// 所有处理结束之后,重新赋值 referralEntity 的accountId 为公众号本身的Id(主要是因为客服消息生成之后,发送的时候,referral_entity 表只有 account_id 字段可以区分推送公众号)进行保存
referralEntity
.
setAccountId
(
authInfoVo
.
getAccountId
());
referralEntityList
.
add
(
referralEntity
);
referralEntityList
.
add
(
referralEntity
);
}
}
...
...
src/main/java/com/yaoyaozw/customer/service/impl/CustomerGraphicsServiceImpl.java
浏览文件 @
cac45307
...
@@ -284,7 +284,7 @@ public class CustomerGraphicsServiceImpl extends ServiceImpl<CustomerGraphicsMap
...
@@ -284,7 +284,7 @@ public class CustomerGraphicsServiceImpl extends ServiceImpl<CustomerGraphicsMap
Date
requestDate
=
integrationRequestDTO
.
getRequestDate
();
Date
requestDate
=
integrationRequestDTO
.
getRequestDate
();
long
currentTimestamp
=
requestDate
.
getTime
();
long
currentTimestamp
=
System
.
currentTimeMillis
();
//获取待发送的开启客服
//获取待发送的开启客服
List
<
CustomerGraphics
>
customerGraphicsList
=
list
(
new
QueryWrapper
<
CustomerGraphics
>().
eq
(
CustomerGraphics
.
COL_POST_TIME
,
requestDate
).
eq
(
CustomerGraphics
.
COL_SEND_STATUS
,
CustomerCommonConstant
.
SEND_STATUS_ACTIVE
));
List
<
CustomerGraphics
>
customerGraphicsList
=
list
(
new
QueryWrapper
<
CustomerGraphics
>().
eq
(
CustomerGraphics
.
COL_POST_TIME
,
requestDate
).
eq
(
CustomerGraphics
.
COL_SEND_STATUS
,
CustomerCommonConstant
.
SEND_STATUS_ACTIVE
));
...
@@ -332,7 +332,13 @@ public class CustomerGraphicsServiceImpl extends ServiceImpl<CustomerGraphicsMap
...
@@ -332,7 +332,13 @@ public class CustomerGraphicsServiceImpl extends ServiceImpl<CustomerGraphicsMap
.
filter
(
v
->
v
.
getNewsType
()
!=
null
&&
v
.
getNewsType
()
==
-
1
)
.
filter
(
v
->
v
.
getNewsType
()
!=
null
&&
v
.
getNewsType
()
==
-
1
)
.
collect
(
Collectors
.
toList
());
.
collect
(
Collectors
.
toList
());
// 非自定义链接
// 非自定义链接
Map
<
String
,
List
<
ReferralEntityVo
>>
referralMap
=
referralList
.
stream
().
filter
(
a
->!
StringUtils
.
isAnyBlank
(
a
.
getReferral
(),
a
.
getAppid
())).
collect
(
Collectors
.
groupingBy
(
ReferralEntityVo:
:
getAppid
));
Map
<
String
,
List
<
ReferralEntityVo
>>
referralMap
=
referralList
// 允许小程序类型的不设置referral字段的值
.
stream
().
filter
(
a
->
// 过滤掉:appId 为空 或者(非小程序类型且链接为空) 的referral记录
StringUtils
.
isNotBlank
(
a
.
getAppid
())
&&
(
StringUtils
.
isNotBlank
(
a
.
getReferral
())
||
CustomerCommonConstant
.
CUSTOMER_TYPE_VALUE_MINI_PROGRAM
.
equals
(
customerGraphics
.
getType
())
))
.
collect
(
Collectors
.
groupingBy
(
ReferralEntityVo:
:
getAppid
));
//循环该人群包下的所有素材
//循环该人群包下的所有素材
int
singleUserCount
=
0
;
int
singleUserCount
=
0
;
for
(
Map
.
Entry
<
String
,
List
<
CrowdPackageUserVO
>>
usersEntry
:
appidUserMap
.
entrySet
())
{
for
(
Map
.
Entry
<
String
,
List
<
CrowdPackageUserVO
>>
usersEntry
:
appidUserMap
.
entrySet
())
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论