Commit 4a31a5be authored by 郝彦辉's avatar 郝彦辉

添加注释,及日志输出

parent 02711475
......@@ -100,6 +100,7 @@ public class ReportController {
return result;
}
//下载报送的文件
@RequestMapping("/dowloadFile")
public void dowloadFile(String filePath, HttpServletResponse response) throws Exception {
......@@ -160,6 +161,7 @@ public class ReportController {
return result;
}
//txt文件上报
@RequestMapping("/upDataByFile")
public Map<String, Object> upDataByFile(@RequestParam("file") MultipartFile file, String type, String fileType) {
Map<String, Object> result = new HashMap<>();
......@@ -193,6 +195,7 @@ public class ReportController {
return result;
}
//zip文件上报
@RequestMapping("/upDataByZipFile")
public Map<String, Object> upDataByZipFile(FileEntry fileEntry) {
fileEntry.setFilePath(getPath(fileEntry.getFilePath()));
......
......@@ -435,6 +435,7 @@ public class IReportServiceImpl implements ReportService {
});
}
//查询报送状态
@Override
public void quaryReportedStatus(FileEntry fileEntry) throws QgException {
......@@ -450,7 +451,7 @@ public class IReportServiceImpl implements ReportService {
resp = taskJerseyClient.post(headerMap, null, reportConfig.getTaskUri());
} catch (Exception e) {
log.error("查看 fileName: {} ,异常e: {} ", fileEntry.getFileName(), e);
throw new QgException(fileEntry.getFileName() + "报送状态接口异常", e);
throw new QgException(fileEntry.getFileName() + "查看报送状态接口异常", e);
}
if (resp.getStatus() == 200) {
/*
......@@ -503,9 +504,15 @@ public class IReportServiceImpl implements ReportService {
}
}
} else {
log.info("[ERROR] Status: " + resp.getStatus());
log.error("报送状态查询接口失败, Status: {} , fileName: {} ", resp.getStatus(), fileEntry.getFileName());
try{
log.info("报送状态查询接口失败, entity="+resp.getEntity(String.class));
}catch (Exception e){
log.error("报送状态查询接口失败, 读取getEntity异常", e);
}
//log.info("[ERROR] Status: " + resp.getStatus());
// log.info(resp.getEntity(String.class));
throw new QgException("报送状态查询接口失败", "http 状态"+resp.getStatus());
throw new QgException("报送状态查询接口失败", "http 状态="+resp.getStatus()+", fileName="+fileEntry.getFileName());
}
}
......
......@@ -3,32 +3,32 @@
<mapper namespace="com.mapper.data.DataMapper">
<!-- 获取日放款数据 -->
<select id="getLoanDayData" parameterType="map" resultType="map">
set @t1=#{param.startDate};
set @t2=#{param.endDate};
set @t1=#{param.startDate};
set @t2=#{param.endDate};
select
b.name name
,'0' pidType
,b.id_no pid
,'913606000634663936' businessHappenOrgan
,a.loan_application_history_id loanId
,'2' businessType
,'21' businessKind
,DATE_FORMAT(@t1,'%Y%m%d') openDate
,DATE_FORMAT(DATE_SUB(x.deadline,INTERVAL 1 second),'%Y%m%d') dueDate
,a.contract_loan_amount creditMoney
,DATE_FORMAT(@t1,'%Y%m%d') businessHappenDate
,a.contract_loan_amount balance
,0 currentOverdueTotal
,'*' repaymentStatus
select
b.name name
,'0' pidType
,b.id_no pid
,'913606000634663936' businessHappenOrgan
,a.loan_application_history_id loanId
,'2' businessType
,'21' businessKind
,DATE_FORMAT(@t1,'%Y%m%d') openDate
,DATE_FORMAT(DATE_SUB(x.deadline,INTERVAL 1 second),'%Y%m%d') dueDate
,a.contract_loan_amount creditMoney
,DATE_FORMAT(@t1,'%Y%m%d') businessHappenDate
,a.contract_loan_amount balance
,0 currentOverdueTotal
,'*' repaymentStatus
from xyqb_i_loan_application_manifest_history a
left join xyqb_user_i_user_detail b on a.user_id=b.user_id
left join xyqb_i_repayment_plan x on a.loan_application_history_id=x.loan_application_history_id
AND a.contract_term=x.term_no
where a.funding_corp_id in (480,710,630,790,820) and a.transaction_status in (2,5)
and a.loan_paid_at &gt;=@t1
and a.loan_paid_at &lt;@t2;
from xyqb_i_loan_application_manifest_history a
left join xyqb_user_i_user_detail b on a.user_id=b.user_id
left join xyqb_i_repayment_plan x on a.loan_application_history_id=x.loan_application_history_id
AND a.contract_term=x.term_no
where a.funding_corp_id in (480,710,630,790,820) and a.transaction_status in (2,5)
and a.loan_paid_at &gt;=@t1
and a.loan_paid_at &lt;@t2;
</select>
<!-- 获取日还款数据 -->
<select id="getRepayDayData" resultType="map">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment