Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
ibznotify
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
ibiz4jteam
ibznotify
提交
8c9ee466
提交
8c9ee466
编写于
2月 07, 2021
作者:
ibizdev
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
ibiz4j 发布系统代码 [ibiz-notify,通知消息]
上级
3a759ee5
变更
8
隐藏空白字符变更
内嵌
并排
正在显示
8 个修改的文件
包含
32 行增加
和
23 行删除
+32
-23
h2_table.xml
ibznotify-core/src/main/resources/liquibase/h2_table.xml
+5
-5
ibznotify.json
ibznotify-core/src/main/resources/sysmodel/ibznotify.json
+1
-1
MsgBodyDTO.java
...ider-api/src/main/java/cn/ibizlab/api/dto/MsgBodyDTO.java
+1
-1
MsgOpenAccessResource.java
.../main/java/cn/ibizlab/api/rest/MsgOpenAccessResource.java
+5
-3
MsgTemplateResource.java
...rc/main/java/cn/ibizlab/api/rest/MsgTemplateResource.java
+5
-3
MsgUserAccountResource.java
...main/java/cn/ibizlab/api/rest/MsgUserAccountResource.java
+5
-3
DELogicAspect.java
...l/src/main/java/cn/ibizlab/util/aspect/DELogicAspect.java
+4
-1
LayeringCache.java
.../main/java/cn/ibizlab/util/cache/cache/LayeringCache.java
+6
-6
未找到文件。
ibznotify-core/src/main/resources/liquibase/h2_table.xml
浏览文件 @
8c9ee466
...
...
@@ -4,7 +4,7 @@
<!--输出实体[MSG_BODY]数据结构 -->
<changeSet
author=
"
root"
id=
"tab-msg_body-19
-1"
>
<changeSet
author=
"
a_A_5d9d78509"
id=
"tab-msg_body-20
-1"
>
<createTable
tableName=
"IBZMSGBODY"
>
<column
name=
"ISERROR"
remarks=
""
type=
"INT"
>
</column>
...
...
@@ -33,7 +33,7 @@
</column>
<column
name=
"TEMPLPARAMS"
remarks=
""
type=
"TEXT(1048576)"
>
</column>
<column
name=
"USERDATA2"
remarks=
""
type=
"VARCHAR(200)"
>
<column
name=
"USERDATA2"
remarks=
""
type=
"VARCHAR(200
0
)"
>
</column>
<column
name=
"MSGLINK_PC"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
...
...
@@ -42,7 +42,7 @@
<!--输出实体[MSG_OPEN_ACCESS]数据结构 -->
<changeSet
author=
"
root
"
id=
"tab-msg_open_access-8-2"
>
<changeSet
author=
"
a_A_5d9d78509
"
id=
"tab-msg_open_access-8-2"
>
<createTable
tableName=
"IBZOPENACCESS"
>
<column
name=
"ACCESSID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_MSG_OPEN_ACCESS_ACCESSID"
/>
...
...
@@ -74,7 +74,7 @@
<!--输出实体[MSG_TEMPLATE]数据结构 -->
<changeSet
author=
"
root
"
id=
"tab-msg_template-3-3"
>
<changeSet
author=
"
a_A_5d9d78509
"
id=
"tab-msg_template-3-3"
>
<createTable
tableName=
"IBZMSGTEMPL"
>
<column
name=
"TID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_MSG_TEMPLATE_TID"
/>
...
...
@@ -100,7 +100,7 @@
<!--输出实体[MSG_USER_ACCOUNT]数据结构 -->
<changeSet
author=
"
root
"
id=
"tab-msg_user_account-6-4"
>
<changeSet
author=
"
a_A_5d9d78509
"
id=
"tab-msg_user_account-6-4"
>
<createTable
tableName=
"IBZUSERAUTH"
>
<column
name=
"AUTHID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_MSG_USER_ACCOUNT_AUTHID"
/>
...
...
ibznotify-core/src/main/resources/sysmodel/ibznotify.json
浏览文件 @
8c9ee466
...
...
@@ -204,7 +204,7 @@
"nullable"
:
1
,
"physical_field"
:
1
,
"data_type"
:
"VARCHAR"
,
"data_length"
:
200
,
"data_length"
:
200
0
,
"key_field"
:
0
,
"show_order"
:
1000
,
"major_field"
:
0
...
...
ibznotify-provider/ibznotify-provider-api/src/main/java/cn/ibizlab/api/dto/MsgBodyDTO.java
浏览文件 @
8c9ee466
...
...
@@ -149,7 +149,7 @@ public class MsgBodyDTO extends DTOBase implements Serializable {
*/
@JSONField
(
name
=
"user_data2"
)
@JsonProperty
(
"user_data2"
)
@Size
(
min
=
0
,
max
=
200
,
message
=
"内容长度必须小于等于[2
00]"
)
@Size
(
min
=
0
,
max
=
200
0
,
message
=
"内容长度必须小于等于[20
00]"
)
private
String
userData2
;
/**
...
...
ibznotify-provider/ibznotify-provider-api/src/main/java/cn/ibizlab/api/rest/MsgOpenAccessResource.java
浏览文件 @
8c9ee466
...
...
@@ -72,7 +72,7 @@ public class MsgOpenAccessResource {
MsgOpenAccess
domain
=
msgopenaccessMapping
.
toDomain
(
msgopenaccessdto
);
domain
.
setId
(
msgopenaccess_id
);
msgopenaccessService
.
update
(
domain
);
MsgOpenAccessDTO
dto
=
msgopenaccessMapping
.
toDto
(
domain
);
MsgOpenAccessDTO
dto
=
msgopenaccessMapping
.
toDto
(
domain
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
...
...
@@ -124,8 +124,10 @@ public class MsgOpenAccessResource {
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibznotify-MsgOpenAccess-Save-all')"
)
@ApiOperation
(
value
=
"保存接入开放平台"
,
tags
=
{
"接入开放平台"
},
notes
=
"保存接入开放平台"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/msgopenaccesses/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
MsgOpenAccessDTO
msgopenaccessdto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
msgopenaccessService
.
save
(
msgopenaccessMapping
.
toDomain
(
msgopenaccessdto
)));
public
ResponseEntity
<
MsgOpenAccessDTO
>
save
(
@RequestBody
MsgOpenAccessDTO
msgopenaccessdto
)
{
MsgOpenAccess
domain
=
msgopenaccessMapping
.
toDomain
(
msgopenaccessdto
);
msgopenaccessService
.
save
(
domain
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
msgopenaccessMapping
.
toDto
(
domain
));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibznotify-MsgOpenAccess-Save-all')"
)
...
...
ibznotify-provider/ibznotify-provider-api/src/main/java/cn/ibizlab/api/rest/MsgTemplateResource.java
浏览文件 @
8c9ee466
...
...
@@ -72,7 +72,7 @@ public class MsgTemplateResource {
MsgTemplate
domain
=
msgtemplateMapping
.
toDomain
(
msgtemplatedto
);
domain
.
setTid
(
msgtemplate_id
);
msgtemplateService
.
update
(
domain
);
MsgTemplateDTO
dto
=
msgtemplateMapping
.
toDto
(
domain
);
MsgTemplateDTO
dto
=
msgtemplateMapping
.
toDto
(
domain
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
...
...
@@ -124,8 +124,10 @@ public class MsgTemplateResource {
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibznotify-MsgTemplate-Save-all')"
)
@ApiOperation
(
value
=
"保存消息模板"
,
tags
=
{
"消息模板"
},
notes
=
"保存消息模板"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/msgtemplates/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
MsgTemplateDTO
msgtemplatedto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
msgtemplateService
.
save
(
msgtemplateMapping
.
toDomain
(
msgtemplatedto
)));
public
ResponseEntity
<
MsgTemplateDTO
>
save
(
@RequestBody
MsgTemplateDTO
msgtemplatedto
)
{
MsgTemplate
domain
=
msgtemplateMapping
.
toDomain
(
msgtemplatedto
);
msgtemplateService
.
save
(
domain
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
msgtemplateMapping
.
toDto
(
domain
));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibznotify-MsgTemplate-Save-all')"
)
...
...
ibznotify-provider/ibznotify-provider-api/src/main/java/cn/ibizlab/api/rest/MsgUserAccountResource.java
浏览文件 @
8c9ee466
...
...
@@ -72,7 +72,7 @@ public class MsgUserAccountResource {
MsgUserAccount
domain
=
msguseraccountMapping
.
toDomain
(
msguseraccountdto
);
domain
.
setId
(
msguseraccount_id
);
msguseraccountService
.
update
(
domain
);
MsgUserAccountDTO
dto
=
msguseraccountMapping
.
toDto
(
domain
);
MsgUserAccountDTO
dto
=
msguseraccountMapping
.
toDto
(
domain
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
...
...
@@ -123,8 +123,10 @@ public class MsgUserAccountResource {
@ApiOperation
(
value
=
"保存绑定消息账号"
,
tags
=
{
"绑定消息账号"
},
notes
=
"保存绑定消息账号"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/msguseraccounts/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
MsgUserAccountDTO
msguseraccountdto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
msguseraccountService
.
save
(
msguseraccountMapping
.
toDomain
(
msguseraccountdto
)));
public
ResponseEntity
<
MsgUserAccountDTO
>
save
(
@RequestBody
MsgUserAccountDTO
msguseraccountdto
)
{
MsgUserAccount
domain
=
msguseraccountMapping
.
toDomain
(
msguseraccountdto
);
msguseraccountService
.
save
(
domain
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
msguseraccountMapping
.
toDto
(
domain
));
}
@ApiOperation
(
value
=
"批量保存绑定消息账号"
,
tags
=
{
"绑定消息账号"
},
notes
=
"批量保存绑定消息账号"
)
...
...
ibznotify-util/src/main/java/cn/ibizlab/util/aspect/DELogicAspect.java
浏览文件 @
8c9ee466
...
...
@@ -66,7 +66,7 @@ public class DELogicAspect {
* @return
* @throws Throwable
*/
@Around
(
"execution(* cn.ibizlab.core.*.service.*.*(..))"
)
@Around
(
"execution(* cn.ibizlab.core.*.service.*.*(..))
&& !execution(* cn.ibizlab.core.es.service.*.*(..))
"
)
public
Object
executeLogic
(
ProceedingJoinPoint
point
)
throws
Throwable
{
Object
args
[]
=
point
.
getArgs
();
if
(
ObjectUtils
.
isEmpty
(
args
)
||
args
.
length
==
0
)
{
...
...
@@ -90,6 +90,9 @@ public class DELogicAspect {
if
(
entity
!=
null
)
{
executeBeforeLogic
(
entity
,
action
);
Object
result
=
point
.
proceed
();
if
(
"get"
.
equalsIgnoreCase
(
action
)
&&
result
instanceof
EntityBase
){
entity
=
(
EntityBase
)
result
;
}
executeLogic
(
entity
,
action
);
executeAfterLogic
(
entity
,
action
);
return
result
;
...
...
ibznotify-util/src/main/java/cn/ibizlab/util/cache/cache/LayeringCache.java
浏览文件 @
8c9ee466
...
...
@@ -59,15 +59,15 @@ public class LayeringCache extends AbstractValueAdaptingCache {
@Override
public
ValueWrapper
get
(
Object
key
)
{
ValueWrapper
wrapper
=
caffeineCache
.
get
(
key
);
Object
value
=
ObjectUtils
.
isEmpty
(
wrapper
)?
null
:
wrapper
.
get
();
log
.
debug
(
"查询一级缓存 key:{}
,value:{}"
,
key
,
value
);
Object
value
=
ObjectUtils
.
isEmpty
(
wrapper
)
?
null
:
wrapper
.
get
();
log
.
debug
(
"查询一级缓存 key:{}
"
,
key
,
value
);
if
(
ObjectUtils
.
isEmpty
(
value
))
{
wrapper
=
redisCache
.
get
(
key
);
value
=
ObjectUtils
.
isEmpty
(
wrapper
)?
null
:
wrapper
.
get
();
log
.
debug
(
"查询二级缓存 key:{}
,value:{}"
,
key
,
value
);
if
(!
ObjectUtils
.
isEmpty
(
value
))
{
value
=
ObjectUtils
.
isEmpty
(
wrapper
)
?
null
:
wrapper
.
get
();
log
.
debug
(
"查询二级缓存 key:{}
"
,
key
);
if
(!
ObjectUtils
.
isEmpty
(
value
))
{
caffeineCache
.
put
(
key
,
value
);
log
.
debug
(
"查询二级缓存,并将数据放到一级缓存。 key:{}
,value:{}"
,
key
,
value
);
log
.
debug
(
"查询二级缓存,并将数据放到一级缓存。 key:{}
"
,
key
);
}
}
return
wrapper
;
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录