Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
baihang-report
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
data-spider
baihang-report
Commits
3dccc655
Commit
3dccc655
authored
Dec 23, 2019
by
郝彦辉
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
D3筛选替换reqId
parent
fff446ec
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
ManualToolController.java
...cn/quantgroup/report/controller/ManualToolController.java
+2
-2
ManualToolService.java
...antgroup/report/service/manualTool/ManualToolService.java
+4
-4
No files found.
src/main/java/cn/quantgroup/report/controller/ManualToolController.java
View file @
3dccc655
...
@@ -131,8 +131,8 @@ public class ManualToolController {
...
@@ -131,8 +131,8 @@ public class ManualToolController {
}
}
@RequestMapping
(
"/newD3ReplaceReqId"
)
@RequestMapping
(
"/newD3ReplaceReqId"
)
public
String
newD3ReplaceReqId
(
String
newD3FilePath
,
String
newD3FileNames
,
String
oldD3ReqIdFile
,
String
newD3InFileName
,
String
newD3NotInFileNam
e
){
public
String
newD3ReplaceReqId
(
String
newD3FilePath
,
String
newD3FileNames
,
String
oldD3ReqIdFile
,
String
mapNotEmptyFil
e
){
manualToolService
.
newD3ReplaceReqId
(
newD3FilePath
,
newD3FileNames
,
oldD3ReqIdFile
,
newD3InFileName
,
newD3NotInFileNam
e
);
manualToolService
.
newD3ReplaceReqId
(
newD3FilePath
,
newD3FileNames
,
oldD3ReqIdFile
,
mapNotEmptyFil
e
);
return
"调用结束"
;
return
"调用结束"
;
}
}
...
...
src/main/java/cn/quantgroup/report/service/manualTool/ManualToolService.java
View file @
3dccc655
...
@@ -1812,7 +1812,7 @@ public class ManualToolService implements CommonSuperService {
...
@@ -1812,7 +1812,7 @@ public class ManualToolService implements CommonSuperService {
}
}
public
void
newD3ReplaceReqId
(
String
newD3FilePath
,
String
newD3FileNames
,
String
oldD3ReqIdFile
,
String
newD3InFileName
,
String
newD3NotInFileNam
e
)
{
public
void
newD3ReplaceReqId
(
String
newD3FilePath
,
String
newD3FileNames
,
String
oldD3ReqIdFile
,
String
mapNotEmptyFil
e
)
{
try
{
try
{
List
<
String
>
oldD3ReqIdFileList
=
ReadOrWriteTxt
.
readTxtList
(
oldD3ReqIdFile
);
List
<
String
>
oldD3ReqIdFileList
=
ReadOrWriteTxt
.
readTxtList
(
oldD3ReqIdFile
);
Map
<
String
,
String
>
oldD3_reqIdMap
=
new
HashMap
<>(
oldD3ReqIdFileList
.
size
());
Map
<
String
,
String
>
oldD3_reqIdMap
=
new
HashMap
<>(
oldD3ReqIdFileList
.
size
());
...
@@ -1860,12 +1860,12 @@ public class ManualToolService implements CommonSuperService {
...
@@ -1860,12 +1860,12 @@ public class ManualToolService implements CommonSuperService {
repaymentLoanInfo
.
setReqID
(
oldD3_reqIdMap
.
get
(
key_replace
));
repaymentLoanInfo
.
setReqID
(
oldD3_reqIdMap
.
get
(
key_replace
));
repaymentLoanInfo
.
setOpCode
(
"M"
);
repaymentLoanInfo
.
setOpCode
(
"M"
);
//是要删除,D3_035
//是要删除,D3_035
FileUtils
.
write
(
new
File
(
newD3
InF
ileName
),
JSON
.
toJSONString
(
repaymentLoanInfo
)+
"\r\n"
,
"UTF-8"
,
true
);
FileUtils
.
write
(
new
File
(
newD3
FilePath
+
"in_new_"
+
f
ileName
),
JSON
.
toJSONString
(
repaymentLoanInfo
)+
"\r\n"
,
"UTF-8"
,
true
);
oldD3_reqIdMap
.
remove
(
key_replace
);
oldD3_reqIdMap
.
remove
(
key_replace
);
}
else
{
}
else
{
notHave
++;
notHave
++;
FileUtils
.
write
(
new
File
(
newD3
NotInF
ileName
),
JSON
.
toJSONString
(
repaymentLoanInfo
)+
"\r\n"
,
"UTF-8"
,
true
);
FileUtils
.
write
(
new
File
(
newD3
FilePath
+
"notIn_new_"
+
f
ileName
),
JSON
.
toJSONString
(
repaymentLoanInfo
)+
"\r\n"
,
"UTF-8"
,
true
);
}
}
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
log
.
error
(
fileName
+
":筛选替换 error,"
,
e
);
log
.
error
(
fileName
+
":筛选替换 error,"
,
e
);
...
@@ -1886,7 +1886,7 @@ public class ManualToolService implements CommonSuperService {
...
@@ -1886,7 +1886,7 @@ public class ManualToolService implements CommonSuperService {
for
(
String
key
:
oldD3_reqIdMap
.
keySet
()){
for
(
String
key
:
oldD3_reqIdMap
.
keySet
()){
log
.
info
(
"oldD3_reqIdMap wr:"
+(
wr
++));
log
.
info
(
"oldD3_reqIdMap wr:"
+(
wr
++));
try
{
try
{
FileUtils
.
write
(
new
File
(
newD3FilePath
+
"oldD3_reqIdMap.txt"
),
oldD3_reqIdMap
.
get
(
key
)+
"="
+
oldD3_reqIdMap
+
"\r\n"
,
"UTF-8"
,
true
);
FileUtils
.
write
(
new
File
(
mapNotEmptyFile
),
oldD3_reqIdMap
.
get
(
key
)+
"="
+
oldD3_reqIdMap
+
"\r\n"
,
"UTF-8"
,
true
);
}
catch
(
IOException
e
)
{
}
catch
(
IOException
e
)
{
log
.
error
(
"oldD3_reqIdMap 写入 error "
,
e
);
log
.
error
(
"oldD3_reqIdMap 写入 error "
,
e
);
}
}
...
...
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