Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
O
operate-customer-service
概览
概览
详情
活动
周期分析
版本库
存储库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
沈振路
operate-customer-service
Commits
0e497a89
提交
0e497a89
authored
5月 18, 2024
作者:
沈振路
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
公众号关回、关键词添加小程序卡片发送类型
上级
77eb8a44
隐藏空白字符变更
内嵌
并排
正在显示
9 个修改的文件
包含
109 行增加
和
3 行删除
+109
-3
CustomerKeywordComponent.java
...aoyaozw/customer/components/CustomerKeywordComponent.java
+4
-1
FollowReplyComponent.java
...om/yaoyaozw/customer/components/FollowReplyComponent.java
+4
-1
CustomerMaterialConstant.java
...yaoyaozw/customer/constants/CustomerMaterialConstant.java
+4
-1
FollowReplySaveDTO.java
.../com/yaoyaozw/customer/dto/follow/FollowReplySaveDTO.java
+16
-0
CustomerKeywordSaveDTO.java
...yaoyaozw/customer/dto/keyword/CustomerKeywordSaveDTO.java
+15
-0
CustomerFollowReply.java
...ava/com/yaoyaozw/customer/entity/CustomerFollowReply.java
+18
-0
CustomerKeyword.java
...in/java/com/yaoyaozw/customer/entity/CustomerKeyword.java
+18
-0
FollowReplyInfoVO.java
...va/com/yaoyaozw/customer/vo/follow/FollowReplyInfoVO.java
+14
-0
CustomerKeywordInfoVO.java
...m/yaoyaozw/customer/vo/keyword/CustomerKeywordInfoVO.java
+16
-0
没有找到文件。
src/main/java/com/yaoyaozw/customer/components/CustomerKeywordComponent.java
浏览文件 @
0e497a89
...
...
@@ -149,12 +149,15 @@ public class CustomerKeywordComponent {
entity
.
setOriginMediaUrl
(
sourceMaterial
.
getOriginMediaUrl
());
entity
.
setExtendTitle
(
sourceMaterial
.
getExtendTitle
());
entity
.
setExtendDesc
(
sourceMaterial
.
getExtendDesc
());
entity
.
setMpTitle
(
sourceMaterial
.
getMpTitle
());
entity
.
setMpAppId
(
sourceMaterial
.
getMpAppId
());
entity
.
setMpPath
(
sourceMaterial
.
getMpPath
());
if
(
CustomerMaterialConstant
.
needUpload
(
entity
.
getType
()))
{
// 向腾讯后台上传素材文件
TencentMediaResponseVO
uploadResult
=
tencentCustomerUtil
.
uploadTencentMedia
(
targetAuth
.
getAppId
(),
entity
.
getOriginMediaUrl
(),
entity
.
getType
());
if
(
StringUtils
.
isNotEmpty
(
uploadResult
.
getErrmsg
()))
{
localLog
.
warn
(
"公众号: {} 上传素材失败
"
,
targetAuth
.
getAccountName
());
localLog
.
warn
(
"公众号: {} 上传素材失败
{}"
,
targetAuth
.
getAccountName
(),
uploadResult
.
getErrmsg
());
}
entity
.
setTxMediaUrl
(
uploadResult
.
getUrl
());
entity
.
setTxMediaId
(
uploadResult
.
getMedia_id
());
...
...
src/main/java/com/yaoyaozw/customer/components/FollowReplyComponent.java
浏览文件 @
0e497a89
...
...
@@ -157,12 +157,15 @@ public class FollowReplyComponent {
entity
.
setExtendTitle
(
sourceMaterial
.
getExtendTitle
());
entity
.
setExtendDesc
(
sourceMaterial
.
getExtendDesc
());
entity
.
setSort
(
sourceMaterial
.
getSort
());
entity
.
setMpTitle
(
sourceMaterial
.
getMpTitle
());
entity
.
setMpAppId
(
sourceMaterial
.
getMpAppId
());
entity
.
setMpPath
(
sourceMaterial
.
getMpPath
());
if
(
CustomerMaterialConstant
.
needUpload
(
entity
.
getType
()))
{
// 向腾讯后台上传素材文件
TencentMediaResponseVO
uploadResult
=
tencentCustomerUtil
.
uploadTencentMedia
(
targetAuth
.
getAppId
(),
entity
.
getOriginMediaUrl
(),
entity
.
getType
());
if
(
StringUtils
.
isNotEmpty
(
uploadResult
.
getErrmsg
()))
{
localLog
.
warn
(
"公众号: {} 上传素材失败"
,
targetAuth
.
getAccountName
());
localLog
.
error
(
"公众号: {} 上传素材失败 {}"
,
targetAuth
.
getAccountName
(),
uploadResult
.
getErrmsg
());
}
entity
.
setTxMediaUrl
(
uploadResult
.
getUrl
());
entity
.
setTxMediaId
(
uploadResult
.
getMedia_id
());
...
...
src/main/java/com/yaoyaozw/customer/constants/CustomerMaterialConstant.java
浏览文件 @
0e497a89
...
...
@@ -18,13 +18,14 @@ public class CustomerMaterialConstant {
public
final
static
String
TENCENT_MEDIA_TYPE_PIC
=
"image"
;
public
final
static
String
TENCENT_MEDIA_TYPE_VOICE
=
"voice"
;
public
final
static
String
TENCENT_MEDIA_TYPE_MINI_PROGRAM
=
"miniprogrampage"
;
public
final
static
String
TENCENT_MEDIA_TYPE_NEWS
=
"news"
;
public
final
static
String
TENCENT_MEDIA_TYPE_TEXT
=
"text"
;
public
final
static
String
TENCENT_MEDIA_TYPE_MULTI_NEWS
=
"multi_news"
;
public
static
Boolean
needUpload
(
String
type
)
{
return
TENCENT_MEDIA_TYPE_PIC
.
equals
(
type
)
||
TENCENT_MEDIA_TYPE_VOICE
.
equals
(
type
);
return
TENCENT_MEDIA_TYPE_PIC
.
equals
(
type
)
||
TENCENT_MEDIA_TYPE_VOICE
.
equals
(
type
)
||
TENCENT_MEDIA_TYPE_MINI_PROGRAM
.
equals
(
type
)
;
}
public
static
Boolean
needReferral
(
String
type
)
{
...
...
@@ -41,6 +42,8 @@ public class CustomerMaterialConstant {
return
"图文"
;
}
else
if
(
TENCENT_MEDIA_TYPE_TEXT
.
equals
(
type
))
{
return
"文本"
;
}
else
if
(
TENCENT_MEDIA_TYPE_MINI_PROGRAM
.
equals
(
type
))
{
return
"小程序"
;
}
return
""
;
...
...
src/main/java/com/yaoyaozw/customer/dto/follow/FollowReplySaveDTO.java
浏览文件 @
0e497a89
...
...
@@ -34,6 +34,22 @@ public class FollowReplySaveDTO implements Serializable {
private
String
extendDesc
;
/**
* 小程序标题
*/
private
String
mpTitle
;
/**
* 小程序appId
*/
private
String
mpAppId
;
/**
* 小程序跳转路径
*/
private
String
mpPath
;
@NotNull
(
message
=
"素材排序不能为空"
)
private
Integer
sort
;
...
...
src/main/java/com/yaoyaozw/customer/dto/keyword/CustomerKeywordSaveDTO.java
浏览文件 @
0e497a89
...
...
@@ -31,5 +31,20 @@ public class CustomerKeywordSaveDTO implements Serializable {
private
String
extendDesc
;
/**
* 小程序标题
*/
private
String
mpTitle
;
/**
* 小程序appId
*/
private
String
mpAppId
;
/**
* 小程序跳转路径
*/
private
String
mpPath
;
private
CommonReferralBody
referralBody
;
}
src/main/java/com/yaoyaozw/customer/entity/CustomerFollowReply.java
浏览文件 @
0e497a89
...
...
@@ -85,6 +85,24 @@ public class CustomerFollowReply implements Serializable {
private
String
content
;
/**
* 小程序标题
*/
@TableField
(
"mp_title"
)
private
String
mpTitle
;
/**
* 小程序appId
*/
@TableField
(
"mp_app_id"
)
private
String
mpAppId
;
/**
* 小程序跳转路径
*/
@TableField
(
"mp_path"
)
private
String
mpPath
;
/**
* 发文排序
*/
@TableField
(
"sort"
)
...
...
src/main/java/com/yaoyaozw/customer/entity/CustomerKeyword.java
浏览文件 @
0e497a89
...
...
@@ -85,6 +85,24 @@ public class CustomerKeyword implements Serializable {
private
String
content
;
/**
* 小程序标题
*/
@TableField
(
"mp_title"
)
private
String
mpTitle
;
/**
* 小程序appId
*/
@TableField
(
"mp_app_id"
)
private
String
mpAppId
;
/**
* 小程序跳转路径
*/
@TableField
(
"mp_path"
)
private
String
mpPath
;
/**
* 状态
*/
@TableField
(
"status"
)
...
...
src/main/java/com/yaoyaozw/customer/vo/follow/FollowReplyInfoVO.java
浏览文件 @
0e497a89
...
...
@@ -33,6 +33,20 @@ public class FollowReplyInfoVO implements Serializable {
private
String
extendTitle
;
private
String
extendDesc
;
/**
* 小程序标题
*/
private
String
mpTitle
;
/**
* 小程序appId
*/
private
String
mpAppId
;
/**
* 小程序跳转路径
*/
private
String
mpPath
;
private
Integer
sort
;
...
...
src/main/java/com/yaoyaozw/customer/vo/keyword/CustomerKeywordInfoVO.java
浏览文件 @
0e497a89
...
...
@@ -33,6 +33,22 @@ public class CustomerKeywordInfoVO implements Serializable {
private
String
extendDesc
;
/**
* 小程序标题
*/
private
String
mpTitle
;
/**
* 小程序appId
*/
private
String
mpAppId
;
/**
* 小程序跳转路径
*/
private
String
mpPath
;
private
Integer
sort
;
private
AuthInfoVO
authInfo
;
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论