|
|
@ -2298,7 +2298,7 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
|
|
|
if (null != execute) { |
|
|
|
vo.setSid(execute.getMainSid()); |
|
|
|
vo.setRecordSid(execute.getSid()); |
|
|
|
// vo.setRecordSid(execute.getSid());
|
|
|
|
//准备执行材料
|
|
|
|
ReadyInfo readyInfo = new ReadyInfo(); |
|
|
|
BeanUtil.copyProperties(execute, readyInfo); |
|
|
@ -2415,8 +2415,8 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
|
|
|
String sid = dto.getSid(); |
|
|
|
ReadyInfo readyInfo = dto.getReadyInfo(); |
|
|
|
if (StringUtils.isNotBlank(dto.getRecordSid())) { |
|
|
|
LoanCaseProgressExecute execute = loanCaseProgressExecuteService.fetchBySid(dto.getRecordSid()); |
|
|
|
LoanCaseProgressExecute execute = baseMapper.getExecuteDetailsBySid(sid); |
|
|
|
if (execute != null) { |
|
|
|
BeanUtil.copyProperties(readyInfo, execute); |
|
|
|
if (StringUtils.isBlank(execute.getCaseTache())) { |
|
|
|
execute.setCaseTacheNo("1"); |
|
|
@ -2467,11 +2467,11 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
} |
|
|
|
} |
|
|
|
} else { |
|
|
|
LoanCaseProgressExecute execute = new LoanCaseProgressExecute(); |
|
|
|
BeanUtil.copyProperties(readyInfo, execute); |
|
|
|
execute.setMainSid(sid); |
|
|
|
execute.setCaseTacheNo("1"); |
|
|
|
execute.setCaseTache("准备执行材料"); |
|
|
|
LoanCaseProgressExecute executeEntity = new LoanCaseProgressExecute(); |
|
|
|
BeanUtil.copyProperties(readyInfo, executeEntity); |
|
|
|
executeEntity.setMainSid(sid); |
|
|
|
executeEntity.setCaseTacheNo("1"); |
|
|
|
executeEntity.setCaseTache("准备执行材料"); |
|
|
|
//保存附件
|
|
|
|
List<UrlQuery> filss = readyInfo.getFile(); |
|
|
|
filss.removeAll(Collections.singleton(null)); |
|
|
@ -2480,10 +2480,10 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
filesList.removeAll(Collections.singleton(null)); |
|
|
|
if (!filesList.isEmpty()) { |
|
|
|
String files = String.join(",", filesList).replaceAll(fileUploadComponent.getUrlPrefix(), ""); |
|
|
|
execute.setPrepareFiles(files); |
|
|
|
executeEntity.setPrepareFiles(files); |
|
|
|
} |
|
|
|
} |
|
|
|
loanCaseProgressExecuteService.insert(execute); |
|
|
|
loanCaseProgressExecuteService.insert(executeEntity); |
|
|
|
LoanCaseProgress progress = fetchBySid(sid); |
|
|
|
if (null != progress) { |
|
|
|
String caseStage = progress.getCaseStageNo(); |
|
|
@ -2527,26 +2527,26 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
|
|
|
YiZhiXingInfo yiZhiXingInfo = dto.getYiZhiXingInfo(); |
|
|
|
List<ExecuteMeasureVo> executeMeasure = yiZhiXingInfo.getExecuteMeasure(); |
|
|
|
if (StringUtils.isNotBlank(dto.getRecordSid())) { |
|
|
|
LoanCaseProgressExecute execute = loanCaseProgressExecuteService.fetchBySid(dto.getRecordSid()); |
|
|
|
BeanUtil.copyProperties(yiZhiXingInfo, execute); |
|
|
|
if (StringUtils.isBlank(execute.getCaseTache())) { |
|
|
|
execute.setCaseTacheNo("2"); |
|
|
|
execute.setCaseTache("已执行立案"); |
|
|
|
LoanCaseProgressExecute updateEntity = baseMapper.getExecuteDetailsBySid(sid); |
|
|
|
if (updateEntity != null) { |
|
|
|
BeanUtil.copyProperties(yiZhiXingInfo, updateEntity); |
|
|
|
if (StringUtils.isBlank(updateEntity.getCaseTache())) { |
|
|
|
updateEntity.setCaseTacheNo("2"); |
|
|
|
updateEntity.setCaseTache("已执行立案"); |
|
|
|
} else { |
|
|
|
String caseTacheNo = execute.getCaseTacheNo(); |
|
|
|
String caseTacheNo = updateEntity.getCaseTacheNo(); |
|
|
|
int i = Integer.parseInt(caseTacheNo); |
|
|
|
if (i < 2) { |
|
|
|
execute.setCaseTacheNo("2"); |
|
|
|
execute.setCaseTache("已执行立案"); |
|
|
|
updateEntity.setCaseTacheNo("2"); |
|
|
|
updateEntity.setCaseTache("已执行立案"); |
|
|
|
} |
|
|
|
} |
|
|
|
loanCaseProgressExecuteService.updateById(execute); |
|
|
|
loanCaseProgressExecuteMeasureService.delByMainSid(dto.getRecordSid()); |
|
|
|
loanCaseProgressExecuteService.updateById(updateEntity); |
|
|
|
loanCaseProgressExecuteMeasureService.delByMainSid(updateEntity.getSid()); |
|
|
|
if (!executeMeasure.isEmpty()) { |
|
|
|
for (ExecuteMeasureVo measureVo : executeMeasure) { |
|
|
|
LoanCaseProgressExecuteMeasure measure = new LoanCaseProgressExecuteMeasure(); |
|
|
|
measure.setMainSid(execute.getSid()); |
|
|
|
measure.setMainSid(updateEntity.getSid()); |
|
|
|
BeanUtil.copyProperties(measureVo, measure); |
|
|
|
//保存附件
|
|
|
|
List<UrlQuery> filss = measureVo.getFile(); |
|
|
@ -2691,9 +2691,9 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
ResultBean rb = ResultBean.fireFail(); |
|
|
|
String sid = dto.getSid(); |
|
|
|
PromiseInfo promiseInfo = dto.getPromiseInfo(); |
|
|
|
if (StringUtils.isNotBlank(dto.getRecordSid())) { |
|
|
|
LoanCaseProgressExecute execute = loanCaseProgressExecuteService.fetchBySid(dto.getRecordSid()); |
|
|
|
BeanUtil.copyProperties(promiseInfo, execute); |
|
|
|
LoanCaseProgressExecute updateEntity = baseMapper.getExecuteDetailsBySid(sid); |
|
|
|
if (null != updateEntity) { |
|
|
|
BeanUtil.copyProperties(promiseInfo, updateEntity); |
|
|
|
//保存附件
|
|
|
|
List<UrlQuery> filss = promiseInfo.getFile(); |
|
|
|
filss.removeAll(Collections.singleton(null)); |
|
|
@ -2702,10 +2702,10 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
filesList.removeAll(Collections.singleton(null)); |
|
|
|
if (!filesList.isEmpty()) { |
|
|
|
String files = String.join(",", filesList).replaceAll(fileUploadComponent.getUrlPrefix(), ""); |
|
|
|
execute.setPromiseFiles(files); |
|
|
|
updateEntity.setPromiseFiles(files); |
|
|
|
} |
|
|
|
} |
|
|
|
loanCaseProgressExecuteService.updateById(execute); |
|
|
|
loanCaseProgressExecuteService.updateById(updateEntity); |
|
|
|
} else { |
|
|
|
LoanCaseProgressExecute execute = new LoanCaseProgressExecute(); |
|
|
|
BeanUtil.copyProperties(promiseInfo, execute); |
|
|
@ -2731,9 +2731,9 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
ResultBean rb = ResultBean.fireFail(); |
|
|
|
String sid = dto.getSid(); |
|
|
|
CloseInfo closeInfo = dto.getCloseInfo(); |
|
|
|
if (StringUtils.isNotBlank(dto.getRecordSid())) { |
|
|
|
LoanCaseProgressExecute execute = loanCaseProgressExecuteService.fetchBySid(dto.getRecordSid()); |
|
|
|
BeanUtil.copyProperties(closeInfo, execute); |
|
|
|
LoanCaseProgressExecute updateEntity = baseMapper.getExecuteDetailsBySid(sid); |
|
|
|
if (null != updateEntity) { |
|
|
|
BeanUtil.copyProperties(closeInfo, updateEntity); |
|
|
|
//保存附件
|
|
|
|
List<UrlQuery> filss = closeInfo.getFile(); |
|
|
|
filss.removeAll(Collections.singleton(null)); |
|
|
@ -2742,10 +2742,10 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
filesList.removeAll(Collections.singleton(null)); |
|
|
|
if (!filesList.isEmpty()) { |
|
|
|
String files = String.join(",", filesList).replaceAll(fileUploadComponent.getUrlPrefix(), ""); |
|
|
|
execute.setCloseFiles(files); |
|
|
|
updateEntity.setCloseFiles(files); |
|
|
|
} |
|
|
|
} |
|
|
|
loanCaseProgressExecuteService.updateById(execute); |
|
|
|
loanCaseProgressExecuteService.updateById(updateEntity); |
|
|
|
} else { |
|
|
|
LoanCaseProgressExecute execute = new LoanCaseProgressExecute(); |
|
|
|
BeanUtil.copyProperties(closeInfo, execute); |
|
|
@ -2770,13 +2770,11 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
@Transactional(rollbackFor = Exception.class) |
|
|
|
public ResultBean saveEndCaseInfo(ExecuteVo dto) { |
|
|
|
ResultBean rb = ResultBean.fireFail(); |
|
|
|
if (StringUtils.isNotBlank(dto.getRecordSid())) { |
|
|
|
LoanCaseProgressExecute updateEntity = baseMapper.getExecuteDetailsBySid(dto.getSid()); |
|
|
|
if (null != updateEntity) { |
|
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
|
|
|
String sid = dto.getSid(); |
|
|
|
String recordSid = dto.getRecordSid(); |
|
|
|
EndCaseInfo endCaseInfo = dto.getEndCaseInfo(); |
|
|
|
LoanCaseProgressExecute execute = loanCaseProgressExecuteService.fetchBySid(recordSid); |
|
|
|
BeanUtil.copyProperties(endCaseInfo, execute); |
|
|
|
BeanUtil.copyProperties(endCaseInfo, updateEntity); |
|
|
|
//保存附件
|
|
|
|
List<UrlQuery> filss = endCaseInfo.getFile(); |
|
|
|
filss.removeAll(Collections.singleton(null)); |
|
|
@ -2785,17 +2783,17 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
filesList.removeAll(Collections.singleton(null)); |
|
|
|
if (!filesList.isEmpty()) { |
|
|
|
String files = String.join(",", filesList).replaceAll(fileUploadComponent.getUrlPrefix(), ""); |
|
|
|
execute.setEndFiles(files); |
|
|
|
updateEntity.setEndFiles(files); |
|
|
|
} |
|
|
|
} |
|
|
|
execute.setTerminate(1); |
|
|
|
loanCaseProgressExecuteService.updateById(execute); |
|
|
|
updateEntity.setTerminate(1); |
|
|
|
loanCaseProgressExecuteService.updateById(updateEntity); |
|
|
|
LoanCaseProgressExecute newExecute = new LoanCaseProgressExecute(); |
|
|
|
newExecute.setMainSid(sid); |
|
|
|
newExecute.setMainSid(dto.getSid()); |
|
|
|
newExecute.setCaseTache("准备执行材料"); |
|
|
|
newExecute.setCaseTacheNo("1"); |
|
|
|
loanCaseProgressExecuteService.insert(newExecute); |
|
|
|
LoanCaseProgress progress = fetchBySid(sid); |
|
|
|
LoanCaseProgress progress = fetchBySid(dto.getSid()); |
|
|
|
if (null != progress) { |
|
|
|
String caseStage = progress.getCaseStageNo(); |
|
|
|
int i = Integer.parseInt(caseStage); |
|
|
@ -2989,4 +2987,22 @@ public class LoanCaseProgressService extends MybatisBaseService<LoanCaseProgress |
|
|
|
} |
|
|
|
return rb.success(); |
|
|
|
} |
|
|
|
|
|
|
|
public ResultBean<List<ExecuteVoList>> getExecuteList(String sid) { |
|
|
|
ResultBean rb = ResultBean.fireFail(); |
|
|
|
List<ExecuteVoList> voLists = baseMapper.getExecuteList(sid); |
|
|
|
return rb.success().setData(voLists); |
|
|
|
} |
|
|
|
|
|
|
|
public ResultBean<ExecuteVo> getHistoryExecuteDetail(String recordSid) { |
|
|
|
ResultBean rb = ResultBean.fireFail(); |
|
|
|
LoanCaseProgressExecute loanCaseProgressExecute = loanCaseProgressExecuteService.fetchBySid(recordSid); |
|
|
|
if (null != loanCaseProgressExecute) { |
|
|
|
ExecuteVo executeVo = returnExecuteVo(loanCaseProgressExecute); |
|
|
|
return rb.success().setData(executeVo); |
|
|
|
} else { |
|
|
|
ExecuteVo vo = new ExecuteVo(); |
|
|
|
return rb.success().setData(vo); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|