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
461c8341
Commit
461c8341
authored
Dec 29, 2019
by
郝彦辉
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
接口报送bug
parent
f4ccd689
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
98 additions
and
28 deletions
+98
-28
QuantGroupZhuDaiReportToBaiHang.java
...uantgroup/report/job/QuantGroupZhuDaiReportToBaiHang.java
+16
-2
SynLoanInfoHistoryTask.java
...java/cn/quantgroup/report/job/SynLoanInfoHistoryTask.java
+1
-1
BaiHangZhuDaiService.java
...antgroup/report/service/baihang/BaiHangZhuDaiService.java
+35
-24
ManualToolService.java
...antgroup/report/service/manualTool/ManualToolService.java
+46
-1
No files found.
src/main/java/cn/quantgroup/report/job/QuantGroupZhuDaiReportToBaiHang.java
View file @
461c8341
...
...
@@ -46,7 +46,7 @@ public class QuantGroupZhuDaiReportToBaiHang {
private
DingTalk
dingTalk
;
@Async
//@Scheduled(cron = "0 0
5 * * ?")
@Scheduled
(
cron
=
"0 0 0
5 * * ?"
)
public
void
startZhuDaiReport
(){
if
(
increment
()){
redisTemplate
.
expire
(
Constant
.
QG_ZHU_DAI_REPORT_LOCK_KEY
,
10
,
TimeUnit
.
SECONDS
);
...
...
@@ -54,6 +54,7 @@ public class QuantGroupZhuDaiReportToBaiHang {
Stopwatch
stopwatch
=
Stopwatch
.
createStarted
();
boolean
tableIsSyn
=
synLoanInfoHistoryTask
.
syn_historyAndplan_by_id
();
if
(
tableIsSyn
){
try
{
//yyyy-MM-dd
...
...
@@ -63,11 +64,24 @@ public class QuantGroupZhuDaiReportToBaiHang {
log
.
info
(
"量化派-助贷模式报送贷款信息开始, newTime: {} , startnyr: {} , endnyr: {} "
,
LocalDateTime
.
now
(),
startnyr
,
endnyr
);
String
msg_A1
=
baiHangZhuDaiService
.
sendZhuDaiApplyToBaiHang
(
startnyr
,
endnyr
);
//生产 助贷-贷款申请 报送T+1 暂时先不报送C1 因为百行还没有开放查询接口
dingTalk
.
talk
(
"Info"
,
"报送"
+
startnyr
+
"申请A1结束"
,
msg_A1
);
if
(
msg_A1
.
indexOf
(
"[false]"
)!=-
1
){
dingTalk
.
talk_ToUser
(
"报送"
+
startnyr
+
"申请A1有部分失败,请尽快手动处理!"
);
}
String
msg_D2
=
baiHangZhuDaiService
.
sendZhuDaiLoanToBaiHang
(
startnyr
,
endnyr
);
//生产 助贷-放款信息 报送T+1
dingTalk
.
talk
(
"Info"
,
"报送"
+
startnyr
+
"放款D2结束"
,
msg_D2
);
if
(
msg_D2
.
indexOf
(
"[false]"
)!=-
1
){
dingTalk
.
talk_ToUser
(
"报送"
+
startnyr
+
"放款D2有部分失败,请尽快手动处理!"
);
}
String
msg_D3
=
baiHangZhuDaiService
.
sendZhuDaiRepaymentToBaiHang
(
startnyr
,
endnyr
);
//生产 助贷-还款&逾期信息 报送T+1
dingTalk
.
talk
(
"Info"
,
"报送"
+
startnyr
+
"还款D3结束"
,
msg_D3
);
if
(
msg_D3
.
indexOf
(
"[false]"
)!=-
1
){
dingTalk
.
talk_ToUser
(
"报送"
+
startnyr
+
"还款D3有部分失败,请尽快手动处理!"
);
}
log
.
info
(
"量化派-助贷模式报送贷款信息结束, newTime: {}, 耗时: {} , msg: {} "
,
LocalDateTime
.
now
(),
stopwatch
.
stop
().
elapsed
(
TimeUnit
.
MILLISECONDS
),
(
msg_A1
+
msg_D2
+
msg_D3
));
dingTalk
.
talk
(
"Info"
,
"报送贷款信息结束"
,
msg_A1
+
msg_D2
+
msg_D3
);
}
catch
(
Exception
e
){
log
.
error
(
"量化派-助贷模式报送贷款信息异常, newTime: {}, 耗时: {} "
,
LocalDateTime
.
now
(),
stopwatch
.
stop
().
elapsed
(
TimeUnit
.
MILLISECONDS
),
e
);
...
...
src/main/java/cn/quantgroup/report/job/SynLoanInfoHistoryTask.java
View file @
461c8341
...
...
@@ -48,7 +48,7 @@ public class SynLoanInfoHistoryTask {
private
static
AtomicBoolean
SYN_Stop
=
new
AtomicBoolean
(
false
);
@Async
@Scheduled
(
cron
=
"0 0 05 * * ?"
)
//2019.11.15 15:25
/*@Scheduled(cron = "0 0 05 * * ?")*/
//2019.11.15 15:25
public
void
startHistoryDateCopy
(){
if
(
increment
()){
redisTemplate
.
expire
(
Constant
.
XYQB_HISTORY_DAI_REPORT_LOCK_KEY
,
10
,
TimeUnit
.
SECONDS
);
...
...
src/main/java/cn/quantgroup/report/service/baihang/BaiHangZhuDaiService.java
View file @
461c8341
This diff is collapsed.
Click to expand it.
src/main/java/cn/quantgroup/report/service/manualTool/ManualToolService.java
View file @
461c8341
...
...
@@ -2510,6 +2510,49 @@ public class ManualToolService implements CommonSuperService {
}
private
static
void
build_d2_1226
()
{
try
{
List
<
String
>
d2JsonList
=
ReadOrWriteTxt
.
readTxtList
(
"D:\\用户目录\\Downloads\\日增日志\\log_d2_26.txt"
);
log
.
info
(
"files d2JsonList size="
+
d2JsonList
.
size
());
for
(
int
i
=
0
;
i
<
d2JsonList
.
size
();
i
++){
String
jsonStr
=
d2JsonList
.
get
(
i
);
if
(
jsonStr
.
length
()<
30
){
continue
;
}
//LoanInfoZhuDaiVo loanInfo
/*JSONObject jsonObject = JSONObject.parseObject(jsonStr);
jsonObject.put("recordId",jsonObject.getString("reqID"));
jsonObject.remove("reqID");*/
LoanInfoZhuDaiVo
loanInfo
=
JSONObject
.
parseObject
(
jsonStr
,
LoanInfoZhuDaiVo
.
class
);
FinTechAgencyBusinessZhuDai
finTechAgencyBusiness
=
JSONObject
.
parseObject
(
jsonStr
,
FinTechAgencyBusinessZhuDai
.
class
);
loanInfo
.
setFinTechAgencyBusiness
(
finTechAgencyBusiness
);
/*loanInfo.setRecordId(loanInfo.getReqID());
loanInfo.setReqID(null);*/
FileUtils
.
write
(
new
File
(
"D:\\用户目录\\Downloads\\日增日志\\log2_d2_26.txt"
),
JSON
.
toJSONString
(
loanInfo
)+
"\n"
,
"UTF-8"
,
true
);
/*LoanInfoZhuDai loanInfozd_tmp = JSONObject.parseObject(jsonStr, LoanInfoZhuDai.class);
int totalTerm = jsonObject.getInteger("totalTerm");
String targetRepayDateList = jsonObject.getString("targetRepayDateList");
if(targetRepayDateList.split(",").length == totalTerm){
FileUtils.write(new File("D:\\用户目录\\Downloads\\ok_d2.txt"), jsonStr+"\n", "UTF-8", true);
}else{
log.error(jsonObject.getString("loanId") + "," + targetRepayDateList.split(",").length + "," + totalTerm);
FileUtils.write(new File("D:\\用户目录\\Downloads\\err_d2.txt"), jsonStr+"\n", "UTF-8", true);
}*/
}
log
.
info
(
"All D2 LOG:保存放款记录结束"
);
}
catch
(
Exception
e
){
log
.
error
(
"处理放款记录异常!"
,
e
);
}
}
...
...
@@ -2578,7 +2621,9 @@ public class ManualToolService implements CommonSuperService {
//check_d2();
build_reqID_recordId
();
// build_reqID_recordId();
build_d2_1226
();
}
...
...
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