Commit 8f0fbc42 authored by liuna's avatar liuna

2017年12月4日 智能分析平台提交内容

--质量报告页面点击详情更换视图
parent 196ed4fc
This diff is collapsed.
package com.hp.cmsz.repository;
import com.hp.cmsz.entity.QualityRuleInfo;
import com.hp.cmsz.entity.QualityRuleReport;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.domain.Specification;
......@@ -29,5 +30,5 @@ public interface QualityRuleInfoDao extends JpaSpecificationExecutor<QualityRule
//List<QualityRuleInfo> findByProvinceIdAndKpiIdAndWarningTypeIsNotAndBusinessTimeBetween(Long provinceId, Long kpiId,String type, Timestamp startTime, Timestamp endTime);
List<QualityRuleInfo> findByProvinceIdAndKpiIdAndBusinessTimeBetweenOrderByBusinessTimeDescProvinceIdDescWarningNumAsc(Long provinceId, Long kpiId, Timestamp startTime, Timestamp endTime);
List<QualityRuleReport> findByProvinceIdAndKpiIdAndBusinessTimeBetweenOrderByBusinessTimeDescProvinceIdDescWarningNumAsc(Long provinceId, Long kpiId, Timestamp startTime, Timestamp endTime);
}
package com.hp.cmsz.service.analysissupport;
import com.hp.cmsz.entity.QualityRuleInfo;
import com.hp.cmsz.entity.QualityRuleReport;
import com.hp.cmsz.entity.Time;
import com.hp.cmsz.repository.QualityRuleInfoDao;
import org.apache.commons.lang3.StringUtils;
......@@ -48,7 +49,7 @@ public class QualityRuleInfoService {
// return qualityRuleInfoDao.findByProvinceIdAndKpiIdAndWarningTypeIsNotAndBusinessTimeBetween(provinceId,kpiId,"正常",startTime,endTime);
// }
public List<QualityRuleInfo> findBy(Long provinceId, Long kpiId, Timestamp startTime, Timestamp endTime){
public List<QualityRuleReport> findBy(Long provinceId, Long kpiId, Timestamp startTime, Timestamp endTime){
return qualityRuleInfoDao.findByProvinceIdAndKpiIdAndBusinessTimeBetweenOrderByBusinessTimeDescProvinceIdDescWarningNumAsc(provinceId,kpiId,startTime,endTime);
}
/**
......
......@@ -169,15 +169,15 @@ public class QualityRuleReportController {
Long kpi = Long.parseLong(kpiId);
Timestamp startTime = Timestamp.valueOf(reportSumStartTime);
Timestamp endTime =Timestamp.valueOf(reportSumEndTime);
List<QualityRuleInfo> qualityRuleInfo = (List<QualityRuleInfo>) qualityRuleInfoService.findBy(province,kpi,startTime,endTime);
cmszOperationLogService.createLog("查询","数据质量规则运营","查询数据质量规则运营明细");
List<QualityRuleReport> qualityRuleReportList = qualityRuleInfoService.findBy(province,kpi,startTime,endTime);
cmszOperationLogService.createLog("查询","数据质量规则运营","查询数据质量运营明细");
Gson gson = new Gson();
response.setContentType("text/Xml;charset=gbk");
PrintWriter out = null;
try {
out = response.getWriter();
out.println(gson.toJson(qualityRuleInfo));
out.println(gson.toJson(qualityRuleReportList));
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
......
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