1. 分期
This commit is contained in:
parent
8980190dd5
commit
6799bbdafc
|
|
@ -28,6 +28,10 @@
|
||||||
</exclusion>
|
</exclusion>
|
||||||
</exclusions>
|
</exclusions>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.chushang</groupId>
|
||||||
|
<artifactId>loan-feign</artifactId>
|
||||||
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.google.zxing</groupId>
|
<groupId>com.google.zxing</groupId>
|
||||||
<artifactId>core</artifactId>
|
<artifactId>core</artifactId>
|
||||||
|
|
|
||||||
|
|
@ -23,36 +23,23 @@ public class LoanController {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private ILoanService iLoanService;
|
private ILoanService iLoanService;
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 提交表单数据
|
|
||||||
*/
|
|
||||||
@PostMapping("/qcode")
|
@PostMapping("/qcode")
|
||||||
public AjaxResult submitFormData(@RequestBody @Validated LoanFormQuery formData) throws Exception{
|
public AjaxResult submitFormData(@RequestBody @Validated LoanFormQuery formData) throws Exception{
|
||||||
return AjaxResult.success(iLoanService.qcCode(formData));
|
return AjaxResult.success(iLoanService.qcCode(formData));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* 查询表单
|
|
||||||
*/
|
|
||||||
@GetMapping("/find")
|
@GetMapping("/find")
|
||||||
@RequiresPermissions("loan:loan:find")
|
@RequiresPermissions("loan:loan:find")
|
||||||
public AjaxResult queryLoan(LoanEntity query) {
|
public AjaxResult queryLoan(LoanEntity query) {
|
||||||
return AjaxResult.success(iLoanService.queryLoan(query));
|
return AjaxResult.success(iLoanService.queryLoan(query));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询表单
|
* 查询统计多少人审核通过以及放款金额
|
||||||
*/
|
*/
|
||||||
@GetMapping("/data")
|
@GetMapping("/data")
|
||||||
@RequiresPermissions("loan:loan:data")
|
@RequiresPermissions("loan:loan:data")
|
||||||
public AjaxResult data( LoanEntity query) {
|
public AjaxResult data( LoanEntity query) {
|
||||||
return AjaxResult.success(iLoanService.queryData(query));
|
return AjaxResult.success(iLoanService.queryData(query));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 审批
|
* 审批
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -112,11 +112,10 @@ public class LoanServiceImpl extends ServiceImpl<LoanMapper, LoanEntity> impleme
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@DataScope(deptAlias = "u", userAlias = "u")
|
@DataScope(deptAlias = "l")
|
||||||
public PageResult queryData(LoanEntity query) {
|
public PageResult queryData(LoanEntity query) {
|
||||||
|
|
||||||
CommonParam commonParam = CommonParam.buildPageRequest();
|
CommonParam commonParam = CommonParam.buildPageRequest();
|
||||||
com.baomidou.mybatisplus.extension.plugins.pagination.Page<LoanEntity> page = new com.baomidou.mybatisplus.extension.plugins.pagination.Page<>(commonParam.getPage(),commonParam.getLimit());
|
Page<LoanEntity> page = new Page<>(commonParam.getPage(),commonParam.getLimit());
|
||||||
List<LoanData> loanVOSList = baseMapper.queryDataList(query,page);
|
List<LoanData> loanVOSList = baseMapper.queryDataList(query,page);
|
||||||
List<LoanVO> resultList = new ArrayList<>();
|
List<LoanVO> resultList = new ArrayList<>();
|
||||||
for (LoanData loanData:loanVOSList){
|
for (LoanData loanData:loanVOSList){
|
||||||
|
|
|
||||||
|
|
@ -11,35 +11,30 @@
|
||||||
COUNT(if(status = 2, id, null)) as totalOpenFlux,
|
COUNT(if(status = 2, id, null)) as totalOpenFlux,
|
||||||
SUM(if(status = 2, loan_amount, null)) as totalLoanAmount,
|
SUM(if(status = 2, loan_amount, null)) as totalLoanAmount,
|
||||||
sum(application_amount) as totalTransactionAmount
|
sum(application_amount) as totalTransactionAmount
|
||||||
from loan
|
from loan l
|
||||||
where del_state = false
|
where l.del_state = false
|
||||||
<if test="query.channelName != '' and query.channelName != null">
|
<if test="query.channelName != '' and query.channelName != null">
|
||||||
AND channel_name like concat('%',#{query.channelName},'%')
|
AND l.channel_name like concat('%',#{query.channelName},'%')
|
||||||
</if>
|
</if>
|
||||||
<if test="query.formNumber != '' and query.formNumber != null ">
|
<if test="query.formNumber != '' and query.formNumber != null ">
|
||||||
AND form_number = #{query.formNumber}
|
AND l.form_number = #{query.formNumber}
|
||||||
</if>
|
</if>
|
||||||
<if test="query.authorPhone != '' and query.authorPhone != null">
|
<if test="query.authorPhone != '' and query.authorPhone != null">
|
||||||
AND author_phone = #{query.authorPhone}
|
AND l.author_phone = #{query.authorPhone}
|
||||||
</if>
|
</if>
|
||||||
<if test="query.authorName != '' and query.authorName != null ">
|
<if test="query.authorName != '' and query.authorName != null ">
|
||||||
AND author_name like concat('%',#{query.authorName},'%')
|
AND l.author_name like concat('%',#{query.authorName},'%')
|
||||||
</if>
|
|
||||||
<if test="query.deptId != null">
|
|
||||||
AND dept_id = #{query.deptId}
|
|
||||||
</if>
|
</if>
|
||||||
<if test="query.status != null">
|
<if test="query.status != null">
|
||||||
AND status = #{query.status}
|
AND l.status = #{query.status}
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
<if test="query.submissionTimes != null and query.submissionTimes.size() > 1 ">
|
<if test="query.submissionTimes != null and query.submissionTimes.size() > 1 ">
|
||||||
AND submission_time between #{query.submissionTimes[0]} and #{query.submissionTimes[1]}
|
AND l.submission_time between #{query.submissionTimes[0]} and #{query.submissionTimes[1]}
|
||||||
</if>
|
</if>
|
||||||
|
${query.sqlParam.dataScope}
|
||||||
|
|
||||||
group by user_id,channel_name,author_name,author_phone
|
group by user_id,channel_name,author_name,author_phone
|
||||||
|
|
||||||
|
|
||||||
${query.sqlParam.dataScope}
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue