Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
ghsby
o2oa
提交
25e1f210
o2oa
项目概览
ghsby
/
o2oa
落后 Fork 源项目 2880 个版本
Fork自
浙江兰德纵横网络技术股份有限公司 / o2oa
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
o2oa
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
25e1f210
编写于
7月 24, 2020
作者:
liyi_hz2008
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[内容管理]修复了发布文档时会通知所有人员的问题
上级
ac7e5abd
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
17 addition
and
12 deletion
+17
-12
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/document/ActionPersistPublishAndNotify.java
...control/jaxrs/document/ActionPersistPublishAndNotify.java
+1
-1
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/document/ActionPersistPublishByWorkFlow.java
...ontrol/jaxrs/document/ActionPersistPublishByWorkFlow.java
+1
-1
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/document/ActionPersistPublishContent.java
...e/control/jaxrs/document/ActionPersistPublishContent.java
+1
-1
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/document/ActionPersistSaveDocument.java
...ble/control/jaxrs/document/ActionPersistSaveDocument.java
+1
-1
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/service/DocumentPersistService.java
.../cms/assemble/control/service/DocumentPersistService.java
+4
-2
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/service/PermissionOperateService.java
...ms/assemble/control/service/PermissionOperateService.java
+9
-6
未找到文件。
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/document/ActionPersistPublishAndNotify.java
浏览文件 @
25e1f210
...
...
@@ -177,7 +177,7 @@ public class ActionPersistPublishAndNotify extends BaseAction {
//将读者以及作者信息持久化到数据库中
if
(
!
wi
.
getSkipPermission
()
)
{
try
{
documentPersistService
.
refreshDocumentPermission
(
id
,
wi
.
getReaderList
(),
wi
.
getAuthorList
()
);
document
=
document
PersistService
.
refreshDocumentPermission
(
id
,
wi
.
getReaderList
(),
wi
.
getAuthorList
()
);
}
catch
(
Exception
e
)
{
check
=
false
;
Exception
exception
=
new
ExceptionDocumentInfoProcess
(
e
,
"系统在核对文档访问管理权限信息时发生异常!"
);
...
...
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/document/ActionPersistPublishByWorkFlow.java
浏览文件 @
25e1f210
...
...
@@ -365,7 +365,7 @@ public class ActionPersistPublishByWorkFlow extends BaseAction {
if
(
check
&&
!
wi
.
getSkipPermission
()
)
{
//将读者以及作者信息持久化到数据库中
try
{
documentPersistService
.
refreshDocumentPermission
(
document
.
getId
(),
wi
.
getReaderList
(),
wi
.
getAuthorList
()
);
document
=
document
PersistService
.
refreshDocumentPermission
(
document
.
getId
(),
wi
.
getReaderList
(),
wi
.
getAuthorList
()
);
}
catch
(
Exception
e
)
{
check
=
false
;
Exception
exception
=
new
ExceptionDocumentInfoProcess
(
e
,
"系统在核对文档访问管理权限信息时发生异常!"
);
...
...
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/document/ActionPersistPublishContent.java
浏览文件 @
25e1f210
...
...
@@ -381,7 +381,7 @@ public class ActionPersistPublishContent extends BaseAction {
if
(
check
&&
!
wi
.
getSkipPermission
()
)
{
//将读者以及作者信息持久化到数据库中
try
{
documentPersistService
.
refreshDocumentPermission
(
document
.
getId
(),
wi
.
getReaderList
(),
wi
.
getAuthorList
()
);
document
=
document
PersistService
.
refreshDocumentPermission
(
document
.
getId
(),
wi
.
getReaderList
(),
wi
.
getAuthorList
()
);
}
catch
(
Exception
e
)
{
check
=
false
;
Exception
exception
=
new
ExceptionDocumentInfoProcess
(
e
,
"系统在核对文档访问管理权限信息时发生异常!"
);
...
...
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/document/ActionPersistSaveDocument.java
浏览文件 @
25e1f210
...
...
@@ -365,7 +365,7 @@ public class ActionPersistSaveDocument extends BaseAction {
if
(
check
)
{
try
{
//将读者以及作者信息持久化到数据库中
documentPersistService
.
refreshDocumentPermission
(
document
.
getId
(),
wi
.
getReaderList
(),
wi
.
getAuthorList
()
);
document
=
document
PersistService
.
refreshDocumentPermission
(
document
.
getId
(),
wi
.
getReaderList
(),
wi
.
getAuthorList
()
);
}
catch
(
Exception
e
)
{
check
=
false
;
Exception
exception
=
new
ExceptionDocumentInfoProcess
(
e
,
"系统在核对文档访问管理权限信息时发生异常!"
);
...
...
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/service/DocumentPersistService.java
浏览文件 @
25e1f210
...
...
@@ -298,15 +298,17 @@ public class DocumentPersistService {
* @param authorList
* @throws Exception
*/
public
void
refreshDocumentPermission
(
String
docId
,
List
<
PermissionInfo
>
readerList
,
List
<
PermissionInfo
>
authorList
)
throws
Exception
{
public
Document
refreshDocumentPermission
(
String
docId
,
List
<
PermissionInfo
>
readerList
,
List
<
PermissionInfo
>
authorList
)
throws
Exception
{
if
(
StringUtils
.
isEmpty
(
docId
)
){
throw
new
Exception
(
"docId is empty!"
);
}
permissionService
.
refreshDocumentPermission
(
docId
,
readerList
,
authorList
);
Document
document
=
permissionService
.
refreshDocumentPermission
(
docId
,
readerList
,
authorList
);
new
CmsBatchOperationPersistService
().
addOperation
(
CmsBatchOperationProcessService
.
OPT_OBJ_DOCUMENT
,
CmsBatchOperationProcessService
.
OPT_TYPE_PERMISSION
,
docId
,
docId
,
"刷新文档权限:ID="
+
docId
);
return
document
;
}
/**
...
...
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/service/PermissionOperateService.java
浏览文件 @
25e1f210
...
...
@@ -33,11 +33,11 @@ public class PermissionOperateService {
* @param authorList
* @throws Exception
*/
public
void
refreshDocumentPermission
(
String
docId
,
List
<
PermissionInfo
>
readerList
,
List
<
PermissionInfo
>
authorList
)
throws
Exception
{
public
Document
refreshDocumentPermission
(
String
docId
,
List
<
PermissionInfo
>
readerList
,
List
<
PermissionInfo
>
authorList
)
throws
Exception
{
List
<
PermissionInfo
>
permissionList
=
composeDocmentAllPermissions
(
readerList
,
authorList
);
try
{
//将读者以及作者信息持久化到数据库中
refreshDocumentPermission
(
docId
,
permissionList
);
re
turn
re
freshDocumentPermission
(
docId
,
permissionList
);
}
catch
(
Exception
e
)
{
throw
e
;
}
...
...
@@ -141,13 +141,14 @@ public class PermissionOperateService {
* @param permissionList
* @throws Exception
*/
public
void
refreshDocumentPermission
(
String
docId
,
List
<
PermissionInfo
>
permissionList
)
throws
Exception
{
public
Document
refreshDocumentPermission
(
String
docId
,
List
<
PermissionInfo
>
permissionList
)
throws
Exception
{
if
(
StringUtils
.
isEmpty
(
docId
)
){
throw
new
Exception
(
"docId is empty!"
);
}
Document
document
=
null
;
try
(
EntityManagerContainer
emc
=
EntityManagerContainerFactory
.
instance
().
create
()
)
{
emc
.
beginTransaction
(
Document
.
class
);
Document
document
=
emc
.
find
(
docId
,
Document
.
class
);
document
=
emc
.
find
(
docId
,
Document
.
class
);
if
(
document
!=
null
)
{
//清空文档权限信息
...
...
@@ -196,12 +197,12 @@ public class PermissionOperateService {
if
(
ListTools
.
isEmpty
(
document
.
getAuthorPersonList
()
)
&&
ListTools
.
isEmpty
(
document
.
getAuthorUnitList
()
)
&&
ListTools
.
isEmpty
(
document
.
getAuthorGroupList
()
))
{
//编辑全部都为空,则是创建人可编辑
document
.
addTo
Author
PersonList
(
document
.
getCreatorPerson
()
);
document
.
addTo
Read
PersonList
(
document
.
getCreatorPerson
()
);
document
.
addToAuthorPersonList
(
document
.
getCreatorPerson
()
);
}
if
(
ListTools
.
isEmpty
(
document
.
getManagerList
()
)
)
{
//管理全部都为空,则是创建人可以管理
document
.
addTo
Manager
List
(
document
.
getCreatorPerson
()
);
document
.
addTo
ReadPerson
List
(
document
.
getCreatorPerson
()
);
document
.
addToManagerList
(
document
.
getCreatorPerson
()
);
}
...
...
@@ -211,6 +212,8 @@ public class PermissionOperateService {
}
catch
(
Exception
e
)
{
throw
e
;
}
return
document
;
}
// private boolean existsPermission(List<PermissionInfo> permissionList, String objectType, String permissionCode) {
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录