|
@ -90,7 +90,10 @@ public class FollowUpJob implements Job {
|
|
|
quartzJobLog.setJobId(wlyyJobConfig.getId());
|
|
|
quartzJobLog.setJobName(wlyyJobConfig.getJobName());
|
|
|
|
|
|
String sql = " select * from wlyy_followup a where a.status=1 and a.followup_plan_date>='" + daybefore + Constant.quota_date_last + "' and a.followup_plan_date< '" + yesterday + Constant.quota_date_last + "' ";
|
|
|
String sql = " select * from wlyy_followup a where " +
|
|
|
" a.status=1 and " +
|
|
|
" a.followup_plan_date>='" + daybefore + Constant.quota_date_last + "' and " +
|
|
|
" a.followup_plan_date< '" + yesterday + Constant.quota_date_last + "' ";
|
|
|
//找出今天的随访信息
|
|
|
List<Map<String, Object>> plans = jdbcTemplate.queryForList(sql);
|
|
|
FilterModel etlModels = followUpDataFilter.filter(plans, sql, yesterday);
|
|
@ -109,21 +112,6 @@ public class FollowUpJob implements Job {
|
|
|
}
|
|
|
|
|
|
|
|
|
private String saveContent(List<Map<String, Object>> plans, Long qkCount, Long orgCount, Long townCount, Long cityCount, boolean isAll, StringBuffer errorContent, Long errorCount, String sql) {
|
|
|
StringBuffer string = new StringBuffer("统计" + yesterday + " 的随访完成 ,数据库查询到随访数目:" + plans.size());
|
|
|
string.append(",sql语句:" + sql);
|
|
|
string.append(",过滤的脏数据数目:" + errorCount);
|
|
|
string.append(",统计到市的数据总数:" + cityCount);
|
|
|
string.append(",统计到区的数据总数:" + townCount);
|
|
|
string.append(",统计到机构的数据总数:" + orgCount);
|
|
|
string.append(",统计到团队的数据总数:" + qkCount);
|
|
|
string.append(",是否统计成功:" + isAll);
|
|
|
if (!isAll) {
|
|
|
string.append(",失败原因:" + errorContent);
|
|
|
}
|
|
|
return string.toString();
|
|
|
}
|
|
|
|
|
|
public Date getYesterday() {
|
|
|
|
|
|
return DateUtil.strToDateShort(yesterday);
|