Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
ghsby
o2oa
提交
af3d66f7
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,发现更多精彩内容 >>
提交
af3d66f7
编写于
12月 03, 2021
作者:
O
o2sword
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
人员组织查询缓存修改
上级
0e2595bd
变更
10
显示空白变更内容
内联
并排
Showing
10 changed file
with
47 addition
and
40 deletion
+47
-40
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/factory/GroupFactory.java
...x/organization/assemble/control/factory/GroupFactory.java
+6
-4
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/factory/IdentityFactory.java
...rganization/assemble/control/factory/IdentityFactory.java
+6
-4
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/factory/PersonFactory.java
.../organization/assemble/control/factory/PersonFactory.java
+6
-4
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/factory/UnitDutyFactory.java
...rganization/assemble/control/factory/UnitDutyFactory.java
+7
-5
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/factory/UnitFactory.java
.../x/organization/assemble/control/factory/UnitFactory.java
+7
-5
o2server/x_organization_assemble_express/src/main/java/com/x/organization/assemble/express/factory/IdentityFactory.java
...rganization/assemble/express/factory/IdentityFactory.java
+2
-2
o2server/x_organization_assemble_express/src/main/java/com/x/organization/assemble/express/factory/PersonFactory.java
.../organization/assemble/express/factory/PersonFactory.java
+3
-3
o2server/x_organization_assemble_express/src/main/java/com/x/organization/assemble/express/factory/UnitDutyFactory.java
...rganization/assemble/express/factory/UnitDutyFactory.java
+6
-3
o2server/x_organization_assemble_express/src/main/java/com/x/organization/assemble/express/factory/UnitFactory.java
.../x/organization/assemble/express/factory/UnitFactory.java
+3
-3
o2server/x_organization_assemble_express/src/main/java/com/x/organization/assemble/express/jaxrs/person/ActionListWithUnitSubDirectObject.java
...press/jaxrs/person/ActionListWithUnitSubDirectObject.java
+1
-7
未找到文件。
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/factory/GroupFactory.java
浏览文件 @
af3d66f7
...
...
@@ -41,21 +41,23 @@ public class GroupFactory extends AbstractFactory {
}
Group
o
=
null
;
CacheKey
cacheKey
=
new
CacheKey
(
flag
);
CacheKey
cacheKey
=
new
CacheKey
(
Group
.
class
.
getName
(),
flag
);
Optional
<?>
optional
=
CacheManager
.
get
(
cache
,
cacheKey
);
if
(
optional
.
isPresent
())
{
o
=
(
Group
)
optional
.
get
();
}
else
{
o
=
this
.
pickObject
(
flag
);
if
(
null
!=
o
)
{
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
}
}
return
o
;
}
public
List
<
Group
>
pick
(
List
<
String
>
flags
)
throws
Exception
{
List
<
Group
>
list
=
new
ArrayList
<>();
for
(
String
str
:
flags
)
{
CacheKey
cacheKey
=
new
CacheKey
(
str
);
CacheKey
cacheKey
=
new
CacheKey
(
Group
.
class
.
getName
(),
str
);
Optional
<?>
optional
=
CacheManager
.
get
(
cache
,
cacheKey
);
if
(
optional
.
isPresent
())
{
list
.
add
((
Group
)
optional
.
get
());
...
...
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/factory/IdentityFactory.java
浏览文件 @
af3d66f7
...
...
@@ -37,14 +37,16 @@ public class IdentityFactory extends AbstractFactory {
return
null
;
}
Identity
o
=
null
;
CacheKey
cacheKey
=
new
CacheKey
(
flag
);
CacheKey
cacheKey
=
new
CacheKey
(
Identity
.
class
.
getName
(),
flag
);
Optional
<?>
optional
=
CacheManager
.
get
(
cache
,
cacheKey
);
if
(
optional
.
isPresent
())
{
o
=
(
Identity
)
optional
.
get
();
}
else
{
o
=
this
.
pickObject
(
flag
);
if
(
null
!=
o
)
{
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
}
}
return
o
;
}
...
...
@@ -82,14 +84,14 @@ public class IdentityFactory extends AbstractFactory {
public
List
<
Identity
>
pick
(
List
<
String
>
flags
)
throws
Exception
{
List
<
Identity
>
list
=
new
ArrayList
<>();
for
(
String
str
:
flags
)
{
CacheKey
cacheKey
=
new
CacheKey
(
str
);
CacheKey
cacheKey
=
new
CacheKey
(
Identity
.
class
.
getName
(),
str
);
Optional
<?>
optional
=
CacheManager
.
get
(
cache
,
cacheKey
);
if
(
optional
.
isPresent
())
{
list
.
add
((
Identity
)
optional
.
get
());
}
else
{
Identity
o
=
this
.
pickObject
(
str
);
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
if
(
null
!=
o
)
{
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
list
.
add
(
o
);
}
}
...
...
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/factory/PersonFactory.java
浏览文件 @
af3d66f7
...
...
@@ -36,14 +36,16 @@ public class PersonFactory extends AbstractFactory {
return
null
;
}
Person
o
=
null
;
CacheKey
cacheKey
=
new
CacheKey
(
flag
);
CacheKey
cacheKey
=
new
CacheKey
(
Person
.
class
.
getName
(),
flag
);
Optional
<?>
optional
=
CacheManager
.
get
(
cache
,
cacheKey
);
if
(
optional
.
isPresent
())
{
o
=
(
Person
)
optional
.
get
();
}
else
{
o
=
this
.
pickObject
(
flag
);
if
(
null
!=
o
)
{
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
}
}
return
o
;
}
...
...
@@ -81,14 +83,14 @@ public class PersonFactory extends AbstractFactory {
public
List
<
Person
>
pick
(
List
<
String
>
flags
)
throws
Exception
{
List
<
Person
>
list
=
new
ArrayList
<>();
for
(
String
str
:
flags
)
{
CacheKey
cacheKey
=
new
CacheKey
(
str
);
CacheKey
cacheKey
=
new
CacheKey
(
Person
.
class
.
getName
(),
str
);
Optional
<?>
optional
=
CacheManager
.
get
(
cache
,
cacheKey
);
if
(
optional
.
isPresent
())
{
list
.
add
((
Person
)
optional
.
get
());
}
else
{
Person
o
=
this
.
pickObject
(
str
);
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
if
(
null
!=
o
)
{
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
list
.
add
(
o
);
}
}
...
...
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/factory/UnitDutyFactory.java
浏览文件 @
af3d66f7
...
...
@@ -36,14 +36,16 @@ public class UnitDutyFactory extends AbstractFactory {
return
null
;
}
UnitDuty
o
=
null
;
CacheKey
cacheKey
=
new
CacheKey
(
flag
);
CacheKey
cacheKey
=
new
CacheKey
(
UnitDuty
.
class
.
getName
(),
flag
);
Optional
<?>
optional
=
CacheManager
.
get
(
cache
,
cacheKey
);
if
(
optional
.
isPresent
())
{
o
=
(
UnitDuty
)
optional
.
get
();
}
else
{
o
=
this
.
pickObject
(
flag
);
if
(
null
!=
o
)
{
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
}
}
return
o
;
}
...
...
@@ -81,14 +83,14 @@ public class UnitDutyFactory extends AbstractFactory {
public
List
<
UnitDuty
>
pick
(
List
<
String
>
flags
)
throws
Exception
{
List
<
UnitDuty
>
list
=
new
ArrayList
<>();
for
(
String
str
:
flags
)
{
CacheKey
cacheKey
=
new
CacheKey
(
str
);
CacheKey
cacheKey
=
new
CacheKey
(
UnitDuty
.
class
.
getName
(),
str
);
Optional
<?>
optional
=
CacheManager
.
get
(
cache
,
cacheKey
);
if
(
optional
.
isPresent
())
{
list
.
add
((
UnitDuty
)
optional
.
get
());
}
else
{
UnitDuty
o
=
this
.
pickObject
(
str
);
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
if
(
null
!=
o
)
{
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
list
.
add
(
o
);
}
}
...
...
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/factory/UnitFactory.java
浏览文件 @
af3d66f7
...
...
@@ -42,14 +42,16 @@ public class UnitFactory extends AbstractFactory {
return
null
;
}
Unit
o
=
null
;
CacheKey
cacheKey
=
new
CacheKey
(
flag
);
CacheKey
cacheKey
=
new
CacheKey
(
Unit
.
class
.
getName
(),
flag
);
Optional
<?>
optional
=
CacheManager
.
get
(
cache
,
cacheKey
);
if
(
optional
.
isPresent
())
{
o
=
(
Unit
)
optional
.
get
();
}
else
{
o
=
this
.
pickObject
(
flag
);
if
(
null
!=
o
)
{
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
}
}
return
o
;
}
...
...
@@ -104,14 +106,14 @@ public class UnitFactory extends AbstractFactory {
public
List
<
Unit
>
pick
(
List
<
String
>
flags
)
throws
Exception
{
List
<
Unit
>
list
=
new
ArrayList
<>();
for
(
String
str
:
flags
)
{
CacheKey
cacheKey
=
new
CacheKey
(
str
);
CacheKey
cacheKey
=
new
CacheKey
(
Unit
.
class
.
getName
(),
str
);
Optional
<?>
optional
=
CacheManager
.
get
(
cache
,
cacheKey
);
if
(
optional
.
isPresent
())
{
list
.
add
((
Unit
)
optional
.
get
());
}
else
{
Unit
o
=
this
.
pickObject
(
str
);
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
if
(
null
!=
o
)
{
CacheManager
.
put
(
cache
,
cacheKey
,
o
);
list
.
add
(
o
);
}
}
...
...
o2server/x_organization_assemble_express/src/main/java/com/x/organization/assemble/express/factory/IdentityFactory.java
浏览文件 @
af3d66f7
...
...
@@ -42,7 +42,7 @@ public class IdentityFactory extends AbstractFactory {
return
null
;
}
Identity
o
=
null
;
CacheKey
cacheKey
=
new
CacheKey
(
flag
);
CacheKey
cacheKey
=
new
CacheKey
(
Identity
.
class
.
getName
(),
flag
);
Optional
<?>
optional
=
CacheManager
.
get
(
cacheCategory
,
cacheKey
);
if
(
optional
.
isPresent
())
{
o
=
(
Identity
)
optional
.
get
();
...
...
@@ -89,7 +89,7 @@ public class IdentityFactory extends AbstractFactory {
public
List
<
Identity
>
pick
(
List
<
String
>
flags
)
throws
Exception
{
List
<
Identity
>
list
=
new
ArrayList
<>();
for
(
String
str
:
flags
)
{
CacheKey
cacheKey
=
new
CacheKey
(
str
);
CacheKey
cacheKey
=
new
CacheKey
(
Identity
.
class
.
getName
(),
str
);
Optional
<?>
optional
=
CacheManager
.
get
(
cacheCategory
,
cacheKey
);
if
(
optional
.
isPresent
())
{
list
.
add
((
Identity
)
optional
.
get
());
...
...
o2server/x_organization_assemble_express/src/main/java/com/x/organization/assemble/express/factory/PersonFactory.java
浏览文件 @
af3d66f7
...
...
@@ -40,7 +40,7 @@ public class PersonFactory extends AbstractFactory {
return
null
;
}
Person
o
=
null
;
CacheKey
cacheKey
=
new
CacheKey
(
flag
);
CacheKey
cacheKey
=
new
CacheKey
(
Person
.
class
.
getName
(),
flag
);
Optional
<?>
optional
=
CacheManager
.
get
(
cacheCategory
,
cacheKey
);
if
(
optional
.
isPresent
())
{
o
=
(
Person
)
optional
.
get
();
...
...
@@ -90,7 +90,7 @@ public class PersonFactory extends AbstractFactory {
public
List
<
Person
>
pick
(
List
<
String
>
flags
)
throws
Exception
{
List
<
Person
>
list
=
new
ArrayList
<>();
for
(
String
str
:
ListTools
.
trim
(
flags
,
true
,
false
))
{
CacheKey
cacheKey
=
new
CacheKey
(
str
);
CacheKey
cacheKey
=
new
CacheKey
(
Person
.
class
.
getName
(),
str
);
Optional
<?>
optional
=
CacheManager
.
get
(
cacheCategory
,
cacheKey
);
if
(
optional
.
isPresent
())
{
list
.
add
((
Person
)
optional
.
get
());
...
...
o2server/x_organization_assemble_express/src/main/java/com/x/organization/assemble/express/factory/UnitDutyFactory.java
浏览文件 @
af3d66f7
...
...
@@ -23,6 +23,9 @@ import com.x.organization.assemble.express.Business;
import
com.x.organization.core.entity.UnitDuty
;
import
com.x.organization.core.entity.UnitDuty_
;
/**
* @author sword
*/
public
class
UnitDutyFactory
extends
AbstractFactory
{
private
CacheCategory
cacheCategory
=
new
CacheCategory
(
UnitDuty
.
class
);
...
...
@@ -36,7 +39,7 @@ public class UnitDutyFactory extends AbstractFactory {
return
null
;
}
UnitDuty
o
=
null
;
CacheKey
cacheKey
=
new
CacheKey
(
flag
);
CacheKey
cacheKey
=
new
CacheKey
(
UnitDuty
.
class
.
getSimpleName
(),
flag
);
Optional
<?>
optional
=
CacheManager
.
get
(
cacheCategory
,
cacheKey
);
if
(
optional
.
isPresent
())
{
o
=
(
UnitDuty
)
optional
.
get
();
...
...
@@ -83,7 +86,7 @@ public class UnitDutyFactory extends AbstractFactory {
public
List
<
UnitDuty
>
pick
(
List
<
String
>
flags
)
throws
Exception
{
List
<
UnitDuty
>
list
=
new
ArrayList
<>();
for
(
String
str
:
flags
)
{
CacheKey
cacheKey
=
new
CacheKey
(
str
);
CacheKey
cacheKey
=
new
CacheKey
(
UnitDuty
.
class
.
getSimpleName
(),
str
);
Optional
<?>
optional
=
CacheManager
.
get
(
cacheCategory
,
cacheKey
);
if
(
optional
.
isPresent
())
{
list
.
add
((
UnitDuty
)
optional
.
get
());
...
...
o2server/x_organization_assemble_express/src/main/java/com/x/organization/assemble/express/factory/UnitFactory.java
浏览文件 @
af3d66f7
...
...
@@ -42,7 +42,7 @@ public class UnitFactory extends AbstractFactory {
return
null
;
}
Unit
o
=
null
;
CacheKey
cacheKey
=
new
CacheKey
(
flag
);
CacheKey
cacheKey
=
new
CacheKey
(
Unit
.
class
.
getName
(),
flag
);
Optional
<?>
optional
=
CacheManager
.
get
(
cacheCategory
,
cacheKey
);
if
(
optional
.
isPresent
())
{
o
=
(
Unit
)
optional
.
get
();
...
...
@@ -106,7 +106,7 @@ public class UnitFactory extends AbstractFactory {
public
List
<
Unit
>
pick
(
List
<
String
>
flags
)
throws
Exception
{
List
<
Unit
>
list
=
new
ArrayList
<>();
for
(
String
str
:
flags
)
{
CacheKey
cacheKey
=
new
CacheKey
(
str
);
CacheKey
cacheKey
=
new
CacheKey
(
Unit
.
class
.
getName
(),
str
);
Optional
<?>
optional
=
CacheManager
.
get
(
cacheCategory
,
cacheKey
);
if
(
optional
.
isPresent
())
{
list
.
add
((
Unit
)
optional
.
get
());
...
...
o2server/x_organization_assemble_express/src/main/java/com/x/organization/assemble/express/jaxrs/person/ActionListWithUnitSubDirectObject.java
浏览文件 @
af3d66f7
...
...
@@ -68,13 +68,7 @@ class ActionListWithUnitSubDirectObject extends BaseAction {
private
List
<
Wo
>
list
(
Business
business
,
Wi
wi
)
throws
Exception
{
List
<
Wo
>
wos
=
new
ArrayList
<>();
List
<
Unit
>
os
=
business
.
unit
().
pick
(
wi
.
getUnitList
());
List
<
String
>
unitIds
=
new
ArrayList
<>();
for
(
Unit
o
:
os
)
{
if
(!
unitIds
.
contains
(
o
.
getId
()))
{
unitIds
.
add
(
o
.
getId
());
}
}
unitIds
=
ListTools
.
trim
(
unitIds
,
true
,
true
);
List
<
String
>
unitIds
=
ListTools
.
extractField
(
os
,
Unit
.
id_FIELDNAME
,
String
.
class
,
true
,
true
);
List
<
Identity
>
list
=
new
ArrayList
<>();
if
(
ListTools
.
isNotEmpty
(
unitIds
))
{
list
=
business
.
entityManagerContainer
().
fetchIn
(
Identity
.
class
,
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录