Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dcs-doc-expand
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
INET-TWO
server
dcs-doc-expand
Commits
74d17902
Commit
74d17902
authored
Nov 06, 2024
by
wei
🎱
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更新案卷为最大密级,年限,文件数,总文件页数
parent
89e2421b
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
15 deletions
+22
-15
Constants.java
.../java/com/inet/dcs/document/core/constants/Constants.java
+4
-0
ExtTransferDocumentServiceImpl.java
...ent/core/service/impl/ExtTransferDocumentServiceImpl.java
+18
-15
No files found.
inet-doc-expand-core/src/main/java/com/inet/dcs/document/core/constants/Constants.java
View file @
74d17902
...
...
@@ -390,6 +390,10 @@ public class Constants {
* 密级字典
*/
public
static
final
String
SECRET_CODE
=
"SecretCode"
;
/**
* 归档保管年限
*/
public
static
final
String
DOC_STORAGE_PERIOD
=
"DocStoragePeriod"
;
/**
* 载体类型字典
*/
...
...
inet-doc-expand-core/src/main/java/com/inet/dcs/document/core/service/impl/ExtTransferDocumentServiceImpl.java
View file @
74d17902
...
...
@@ -276,9 +276,9 @@ public class ExtTransferDocumentServiceImpl<V extends ExtTransferDocumentVO> imp
String
volumeNumber
=
extFilesVO
.
getVolumeNumber
();
int
pageNumber
=
0
;
//文件页数
String
secretCode
=
""
;
//最大密级
Integer
secretCodeDictSeq
=
0
;
Integer
secretCodeDictSeq
=
-
99
;
//初始化最小值
String
storagePeriod
=
""
;
//最大年限
Integer
storagePeriodDictSeq
=
0
;
Integer
storagePeriodDictSeq
=
-
99
;
//初始化最小值
// 案卷下的文档
SearchQueryCondition
queryDoc
=
SearchQueryCondition
.
builder
()
.
openProp
(
SearchQueryCondition
.
builder
().
name
(
"source"
).
build
())
...
...
@@ -288,16 +288,20 @@ public class ExtTransferDocumentServiceImpl<V extends ExtTransferDocumentVO> imp
List
<
ExtTransferDocLinkVO
>
extTransferDocLinkVOList
=
extTransferDocLinkService
.
findRecursion
(
queryDoc
).
getContent
();
for
(
ExtTransferDocLinkVO
extTransferDocLinkVO
:
extTransferDocLinkVOList
)
{
// 最大密级
String
secretCodeDoc
=
extTransferDocLinkVO
.
getSource
().
getSecretCode
();
List
<
DictDataVO
>
dictDataVOByKey
=
this
.
getDictDataVOByKey
(
Constants
.
SECRET_CODE
,
secretCodeDoc
);
// todo 获取最大密级和年限
if
(
CollectionUtils
.
isNotEmpty
(
dictDataVOByKey
))
{
DictDataVO
dictDataVO
=
dictDataVOByKey
.
get
(
0
);
String
dictKey
=
dictDataVO
.
getDictKey
();
secretCodeDictSeq
=
dictDataVO
.
getDictSeq
();
secretCode
=
this
.
getCompareMax
(
Constants
.
SECRET_CODE
,
secretCode
,
secretCodeDictSeq
);
}
//storagePeriod = this.getCompareMax(Constants.SECRET_CODE, extTransferDocLinkVO.getStoragePeriod());
DictDataVO
secretCodeDocMax
=
this
.
getCompareMax
(
Constants
.
SECRET_CODE
,
secretCodeDoc
,
secretCodeDictSeq
);
if
(
ObjectUtils
.
isNotEmpty
(
secretCodeDocMax
))
{
secretCodeDictSeq
=
secretCodeDocMax
.
getDictSeq
();
secretCode
=
secretCodeDocMax
.
getDictKey
();
}
// 最大年限
String
storagePeriodDoc
=
extTransferDocLinkVO
.
getStoragePeriod
();
DictDataVO
storagePeriodDocMax
=
this
.
getCompareMax
(
Constants
.
DOC_STORAGE_PERIOD
,
storagePeriodDoc
,
storagePeriodDictSeq
);
if
(
ObjectUtils
.
isNotEmpty
(
storagePeriodDocMax
))
{
storagePeriodDictSeq
=
storagePeriodDocMax
.
getDictSeq
();
storagePeriod
=
storagePeriodDocMax
.
getDictKey
();
}
pageNumber
+=
extTransferDocLinkVO
.
getPageNumber
();
}
...
...
@@ -310,16 +314,15 @@ public class ExtTransferDocumentServiceImpl<V extends ExtTransferDocumentVO> imp
}
}
private
String
getCompareMax
(
String
dictCode
,
String
dictKey
,
Integer
max
)
{
private
DictDataVO
getCompareMax
(
String
dictCode
,
String
dictKey
,
Integer
max
)
{
List
<
DictDataVO
>
dictDataVOList
=
this
.
getDictDataVOByKey
(
dictCode
,
dictKey
);
if
(
CollectionUtils
.
isNotEmpty
(
dictDataVOList
))
{
DictDataVO
dictDataVO
=
dictDataVOList
.
get
(
0
);
Integer
dictSeq
=
dictDataVO
.
getDictSeq
();
if
(
dictSeq
>
max
)
{
return
dictDataVO
.
getDictKey
();
if
(
dictDataVO
.
getDictSeq
()
>
max
)
{
return
dictDataVO
;
}
}
return
dictKey
;
return
null
;
}
private
List
<
DictDataVO
>
getDictDataVOByKey
(
String
dictCode
,
String
dictKey
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment