Commit 90fe13b3 authored by liuna's avatar liuna

2017/11/20

--增加数据质量核查功能,包含质量规则维护、过滤规则维护和质量规则运营页面。
parent ba070d8f
package com.hp.cmsz.entity;
import java.io.Serializable;
import java.util.Date;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
/**
* accuracy_rule_info_t表对应的实体类
*
* @author Liu Na
*
*/
@Entity
@Table(name = "accuracy_rule_info_t")
public class AccuracyRule implements Serializable {
private Long accuracyRuleId;//准确性规则ID
private Long qualityRuleId;//质量规则ID
private String ruleType;//规则类型
private double scopeMaxValue;//范围最大值
private double scopeMinValue;//范围最小值
private String repeatedCheckGranularity;//重复考核粒度
private Date repeatedCheckStartTime;//重复考核开始时间
private Date repeatedCheckEndTime;//重复考核结束时间
private String ifRepeatedCheckSeries;//重复是否连续
private Long repeatedCheckMaxTime;//重复最大次数
private String ifRepeatedCheckSummation;//数据是否累计
private Date ruleCrtTime;//规则创建时间
private Date ruleUpdateTime;//规则更新时间
private String validFlag;//规则是否有效
@Id
@GeneratedValue(strategy=GenerationType.SEQUENCE, generator="AccuracyRuleSequence")
@SequenceGenerator(name = "AccuracyRuleSequence", sequenceName = "accuracy_rule_info_t_seq", allocationSize=1)
public Long getAccuracyRuleId() {
return accuracyRuleId;
}
public void setAccuracyRuleId(Long accuracyRuleId) {
this.accuracyRuleId = accuracyRuleId;
}
public Long getQualityRuleId() {
return qualityRuleId;
}
public void setQualityRuleId(Long qualityRuleId) {
this.qualityRuleId = qualityRuleId;
}
public String getRuleType() {
return ruleType;
}
public void setRuleType(String ruleType) {
this.ruleType = ruleType;
}
public double getScopeMaxValue() {
return scopeMaxValue;
}
public void setScopeMaxValue(double scopeMaxValue) {
this.scopeMaxValue = scopeMaxValue;
}
public double getScopeMinValue() {
return scopeMinValue;
}
public void setScopeMinValue(double scopeMinValue) {
this.scopeMinValue = scopeMinValue;
}
public String getRepeatedCheckGranularity() {
return repeatedCheckGranularity;
}
public void setRepeatedCheckGranularity(String repeatedCheckGranularity) {
this.repeatedCheckGranularity = repeatedCheckGranularity;
}
public Date getRepeatedCheckStartTime() {
return repeatedCheckStartTime;
}
public void setRepeatedCheckStartTime(Date repeatedCheckStartTime) {
this.repeatedCheckStartTime = repeatedCheckStartTime;
}
public Date getRepeatedCheckEndTime() {
return repeatedCheckEndTime;
}
public void setRepeatedCheckEndTime(Date repeatedCheckEndTime) {
this.repeatedCheckEndTime = repeatedCheckEndTime;
}
public String getIfRepeatedCheckSeries() {
return ifRepeatedCheckSeries;
}
public void setIfRepeatedCheckSeries(String ifRepeatedCheckSeries) {
this.ifRepeatedCheckSeries = ifRepeatedCheckSeries;
}
public Long getRepeatedCheckMaxTime() {
return repeatedCheckMaxTime;
}
public void setRepeatedCheckMaxTime(Long repeatedCheckMaxTime) {
this.repeatedCheckMaxTime = repeatedCheckMaxTime;
}
public String getIfRepeatedCheckSummation() {
return ifRepeatedCheckSummation;
}
public void setIfRepeatedCheckSummation(String ifRepeatedCheckSummation) {
this.ifRepeatedCheckSummation = ifRepeatedCheckSummation;
}
public Date getRuleCrtTime() {
return ruleCrtTime;
}
public void setRuleCrtTime(Date ruleCrtTime) {
this.ruleCrtTime = ruleCrtTime;
}
public Date getRuleUpdateTime() {
return ruleUpdateTime;
}
public void setRuleUpdateTime(Date ruleUpdateTime) {
this.ruleUpdateTime = ruleUpdateTime;
}
public String getValidFlag() {
return validFlag;
}
public void setValidFlag(String validFlag) {
this.validFlag = validFlag;
}
}
package com.hp.cmsz.entity;
import java.io.Serializable;
import java.util.Date;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
/**
* warning_filtering_rule_info_t表对应的实体类
*
* @author Liu Na
*
*/
public class FilterRule implements Serializable{
private Long warningFilteringRuleId;//过滤规则ID
private Long kpiId;//指标ID
private Long provinceId;//省份ID
private Long channelId;//渠道ID
private Long businessId;//业务ID
private Date filterStartTime;//过滤开始时间
private Date filterEndTime;//过滤结束时间
private String filterReason;//过滤原因
private String filterType;//过滤类型
private Date ruleCrtTime;//规则创建时间
private Date ruleUpdateTime;//规则更新时间
private String validFlag;//规则是否有效
@Id
@GeneratedValue(strategy=GenerationType.SEQUENCE, generator="FilterRuleSequence")
@SequenceGenerator(name = "FilterRuleSequence", sequenceName = "warning_filtering_rule_info_t_seq", allocationSize=1)
public Long getWarningFilteringRuleId() {
return warningFilteringRuleId;
}
public void setWarningFilteringRuleId(Long warningFilteringRuleId) {
this.warningFilteringRuleId = warningFilteringRuleId;
}
public Long getKpiId() {
return kpiId;
}
public void setKpiId(Long kpiId) {
this.kpiId = kpiId;
}
public Long getProvinceId() {
return provinceId;
}
public void setProvinceId(Long provinceId) {
this.provinceId = provinceId;
}
public Long getChannelId() {
return channelId;
}
public void setChannelId(Long channelId) {
this.channelId = channelId;
}
public Long getBusinessId() {
return businessId;
}
public void setBusinessId(Long businessId) {
this.businessId = businessId;
}
public Date getFilterStartTime() {
return filterStartTime;
}
public void setFilterStartTime(Date filterStartTime) {
this.filterStartTime = filterStartTime;
}
public Date getFilterEndTime() {
return filterEndTime;
}
public void setFilterEndTime(Date filterEndTime) {
this.filterEndTime = filterEndTime;
}
public String getFilterReason() {
return filterReason;
}
public void setFilterReason(String filterReason) {
this.filterReason = filterReason;
}
public String getFilterType() {
return filterType;
}
public void setFilterType(String filterType) {
this.filterType = filterType;
}
public Date getRuleCrtTime() {
return ruleCrtTime;
}
public void setRuleCrtTime(Date ruleCrtTime) {
this.ruleCrtTime = ruleCrtTime;
}
public Date getRuleUpdateTime() {
return ruleUpdateTime;
}
public void setRuleUpdateTime(Date ruleUpdateTime) {
this.ruleUpdateTime = ruleUpdateTime;
}
public String getValidFlag() {
return validFlag;
}
public void setValidFlag(String validFlag) {
this.validFlag = validFlag;
}
}
package com.hp.cmsz.entity;
import java.io.Serializable;
import java.util.Date;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
/**
* quality_rule_warehouse_info_t表对应的实体类
*
* @author Liu Na
*
*/
public class QualityRule implements Serializable {
private Long qualityRuleId;//质量规则ID
private Long businessId;//业务ID
private Long kpiId;//指标ID
private Long channelId;//渠道ID
private Long provinceId;//省份维表ID
private Long taskId;//任务ID
private Long dataSourceId;//数据来源ID
private String kpiMonitorTime;//指标检测时间
private String kpiMonitorRange;//指标检查范围
private double integrityThresholdValue;//完整性阈值
private Long timelinessThresholdValue;//及时性阈值
private Date ruleCrtTime;//规则创建时间
private Date ruleUpdateTime;//规则更新时间
private String rileValidFlag;//规则是否有效
@Id
@GeneratedValue(strategy=GenerationType.SEQUENCE, generator="QualityRuleSequence")
@SequenceGenerator(name = "QualityRuleSequence", sequenceName = "quality_rule_warehouse_info_t_seq", allocationSize=1)
public Long getQualityRuleId() {
return qualityRuleId;
}
public void setQualityRuleId(Long qualityRuleId) {
this.qualityRuleId = qualityRuleId;
}
public Long getBusinessId() {
return businessId;
}
public void setBusinessId(Long businessId) {
this.businessId = businessId;
}
public Long getKpiId() {
return kpiId;
}
public void setKpiId(Long kpiId) {
this.kpiId = kpiId;
}
public Long getChannelId() {
return channelId;
}
public void setChannelId(Long channelId) {
this.channelId = channelId;
}
public Long getProvinceId() {
return provinceId;
}
public void setProvinceId(Long provinceId) {
this.provinceId = provinceId;
}
public Long getTaskId() {
return taskId;
}
public void setTaskId(Long taskId) {
this.taskId = taskId;
}
public Long getDataSourceId() {
return dataSourceId;
}
public void setDataSourceId(Long dataSourceId) {
this.dataSourceId = dataSourceId;
}
public String getKpiMonitorTime() {
return kpiMonitorTime;
}
public void setKpiMonitorTime(String kpiMonitorTime) {
this.kpiMonitorTime = kpiMonitorTime;
}
public String getKpiMonitorRange() {
return kpiMonitorRange;
}
public void setKpiMonitorRange(String kpiMonitorRange) {
this.kpiMonitorRange = kpiMonitorRange;
}
public double getIntegrityThresholdValue() {
return integrityThresholdValue;
}
public void setIntegrityThresholdValue(double integrityThresholdValue) {
this.integrityThresholdValue = integrityThresholdValue;
}
public Long getTimelinessThresholdValue() {
return timelinessThresholdValue;
}
public void setTimelinessThresholdValue(Long timelinessThresholdValue) {
this.timelinessThresholdValue = timelinessThresholdValue;
}
public Date getRuleCrtTime() {
return ruleCrtTime;
}
public void setRuleCrtTime(Date ruleCrtTime) {
this.ruleCrtTime = ruleCrtTime;
}
public Date getRuleUpdateTime() {
return ruleUpdateTime;
}
public void setRuleUpdateTime(Date ruleUpdateTime) {
this.ruleUpdateTime = ruleUpdateTime;
}
public String getRileValidFlag() {
return rileValidFlag;
}
public void setRileValidFlag(String rileValidFlag) {
this.rileValidFlag = rileValidFlag;
}
}
package com.hp.cmsz.repository;
import java.util.Date;
import java.util.List;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.PagingAndSortingRepository;
import org.springframework.data.repository.query.Param;
import com.hp.cmsz.entity.AccuracyRule;
/**
*
* @author Liu Na
*
*/
public interface AccuracyRuleDao extends JpaSpecificationExecutor<AccuracyRule>,
PagingAndSortingRepository<AccuracyRule, Long>{
//根据准确性规则ID查找质量规则
List<AccuracyRule> findByQualityRuleId(Long qualityRuleId);
//根据准确性规则ID查找质量规则
List<AccuracyRule> findByQualityRuleIdIn(List<Long> qualityRuleId);
//根据准确性规则ID更新质量规则ID
@Modifying
@Query("update AccuracyRule ar set ar.qualityRuleId=:qualityRuleId where ar.accuracyRuleId in (:accuracyRuleIds)")
void updateQualityRuleIdByAccuracyRuleIds(@Param("qualityRuleId")Long qualityRuleId, @Param("accuracyRuleIds")List<Long> accuracyRuleIds);
//根据准确性规则ID更新准确性规则信息
@Modifying
@Query("update AccuracyRule ar set ar.ruleType=:ruleType, ar.scopeMaxValue=:scopeMaxValue, ar.scopeMinValue=:scopeMinValue, ar.repeatedCheckGranularity=:repeatedCheckGranularity, ar.repeatedCheckStartTime=:repeatedCheckStartTime, ar.repeatedCheckEndTime=:repeatedCheckEndTime, ar.ifRepeatedCheckSeries=:ifRepeatedCheckSeries, ar.repeatedCheckMaxTime=:repeatedCheckMaxTime, ar.ifRepeatedCheckSummation=:ifRepeatedCheckSummation where ar.accuracyRuleId =:accuracyRuleId")
void updateAccuracyRuleByAccuracyRuleId(@Param("ruleType")String ruleType,@Param("scopeMaxValue")double scopeMaxValue,@Param("scopeMinValue")double scopeMinValue,@Param("repeatedCheckGranularity")String repeatedCheckGranularity,@Param("repeatedCheckStartTime")Date repeatedCheckStartTime,@Param("repeatedCheckEndTime")Date repeatedCheckEndTime,@Param("ifRepeatedCheckSeries")String ifRepeatedCheckSeries,@Param("repeatedCheckMaxTime")Long repeatedCheckMaxTime,@Param("ifRepeatedCheckSummation")String ifRepeatedCheckSummation);
//根据准确性规则ID删除一条准确性规则信息
@Modifying
@Query("delete from AccuracyRule ar where ar.accuracyRuleId=:accuracyRuleId")
void deleteAccuracyRuleByAccuracyRuleId(@Param("accuracyRuleId")Long accuracyRuleId);
//根据质量规则ID删除准确性规则信息
@Modifying
@Query("delete from AccuracyRule ar where ar.qualityRuleId=:qualityRuleId")
void deleteAccuracyRuleByOneQualityRuleId(@Param("qualityRuleId")Long qualityRuleId);
//根据多个数据模型ID删除参数信息
@Modifying
@Query("delete from AccuracyRule ar where ar.qualityRuleId in (:qualityRuleId)")
void deleteAccuracyRuleByQualityRuleId(@Param("qualityRuleId")List<Long> qualityRuleId);
}
package com.hp.cmsz.repository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.repository.PagingAndSortingRepository;
import com.hp.cmsz.entity.FilterRule;
/**
*
* @author Liu Na
*
*/
public interface FilterRuleDao extends JpaSpecificationExecutor<FilterRule>,
PagingAndSortingRepository<FilterRule, Long>{
}
package com.hp.cmsz.repository;
import java.util.Date;
import java.util.List;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.PagingAndSortingRepository;
import org.springframework.data.repository.query.Param;
import com.hp.cmsz.entity.QualityRule;
/**
*
* @author Liu Na
*
*/
public interface QualityRuleDao extends JpaSpecificationExecutor<QualityRule>,
PagingAndSortingRepository<QualityRule, Long>{
List<QualityRule> findAll();
//根据质量规则ID查找质量规则
QualityRule findByQualityRuleId(Long qualityRuleId);
//根据质量规则ID查找质量规则
List<QualityRule> findByQualityRuleIdIn(List<Long> qualityRuleId);
//根据质量规则ID删除质量规则
@Modifying
@Query("delete from QualityRule qr where qr.qualityRuleId in (:qualityRuleId)")
void deleteQualityRuleByQualityRuleId(@Param("qualityRuleId")List<Long> qualityRuleId);
//根据质量规则ID修改质量规则
@Modifying
@Query("update from QualityRule qr set qr.businessId=:businessId, qr.kpiId=:kpiId, qr.channelId=:channelId, qr.provinceId=:provinceId, qr.dataSourceId=:dataSourceId, qr.kpiMonitorTime=:kpiMonitorTime, qr.kpiMonitorRange=:kpiMonitorRange,dm.integrityThresholdValue=:integrityThresholdValue, qr.timelinessThresholdValue=:timelinessThresholdValue, qr.ruleCrtTime=:ruleCrtTime, qr.ruleUpdateTime=:ruleUpdateTime where qr.qualityRuleId=:qualityRuleId")
void updateQualityRuleByQualityRuleId(@Param("businessId")Long businessId,@Param("kpiId")Long kpiId,@Param("channelId")Long channelId,@Param("provinceId")Long provinceId,@Param("dataSourceId")Long dataSourceId,@Param("kpiMonitorTime")String kpiMonitorTime,@Param("kpiMonitorRange")String kpiMonitorRange,@Param("integrityThresholdValue")double integrityThresholdValue,@Param("timelinessThresholdValue")Long timelinessThresholdValue,@Param("ruleCrtTime")Date ruleCrtTime,@Param("ruleUpdateTime")Date ruleUpdateTime,@Param("qualityRuleId")Long qualityRuleId);
//根据质量规则ID得到数据条数
@Query("select count(*) from QualityRule qualityRule where qualityRule.qualityRuleId=:qualityRuleId")
Long getNumOfQualityRuleByQualityRuleId(@Param("qualityRuleId")String qualityRuleId);
//根据省份、渠道、业务、指标查询质量规则
List<QualityRule> findByProvinceIdInAndBusinessIdInAndKpiIdInAndChannelIdInOrderByQualityRuleIdDesc(List<Long> provinceId, List<Long> businessId, List<Long> kpiId, List<Long> channelId);
}
package com.hp.cmsz.service.analysissupport;
import java.util.Date;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.hp.cmsz.repository.AccuracyRuleDao;
/**
*
* @author Liu Na
*
*/
@Service
@Transactional
public class AccuracyRuleService {
@Autowired
private AccuracyRuleDao accuracyRuleDao;
//根据准确性规则ID更新质量规则ID
@Transactional(readOnly=false)
public void updateAccuracyRuleByAccuracyRuleIds(Long qualityRuleId,List<Long> accuracyRuleIds){
accuracyRuleDao.updateQualityRuleIdByAccuracyRuleIds(qualityRuleId, accuracyRuleIds);;
}
//根据准确性规则ID更新准确性规则
@Transactional(readOnly=false)
public void updateAccuracyRuleByAccuracyRuleId(String ruleType,double scopeMaxValue,double scopeMinValue,String repeatedCheckGranularity,Date repeatedCheckStartTime,Date repeatedCheckEndTime,String ifRepeatedCheckSeries,Long repeatedCheckMaxTime,String ifRepeatedCheckSummation){
accuracyRuleDao.updateAccuracyRuleByAccuracyRuleId(ruleType, scopeMaxValue, scopeMinValue, repeatedCheckGranularity, repeatedCheckStartTime, repeatedCheckEndTime, ifRepeatedCheckSeries, repeatedCheckMaxTime, ifRepeatedCheckSummation);;
}
//根据准确性规则ID删除一条准确性规则信息
@Transactional(readOnly=false)
public void deleteAccuracyRuleByAccuracyRuleId(Long accuracyRuleId){
accuracyRuleDao.deleteAccuracyRuleByAccuracyRuleId(accuracyRuleId);
}
//根据数据模型ID删除一条参数信息
@Transactional(readOnly=false)
public void deleteAccuracyRuleByOneQualityRuleId(Long qualityRuleId){
accuracyRuleDao.deleteAccuracyRuleByOneQualityRuleId(qualityRuleId);
}
//根据数据模型IDS删除多条参数信息
@Transactional(readOnly=false)
public void deleteAccuracyRuleByQualityRuleId(List<Long> qualityRuleId){
accuracyRuleDao.deleteAccuracyRuleByQualityRuleId(qualityRuleId);
}
}
package com.hp.cmsz.service.analysissupport;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
/**
*
* @author Liu Na
*
*/
@Service
@Transactional
public class FilterRuleService {
}
package com.hp.cmsz.service.analysissupport;
import java.util.Date;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.hp.cmsz.repository.QualityRuleDao;
/**
*
* @author Liu Na
*
*/
@Service
@Transactional
public class QualityRuleService {
@Autowired
private QualityRuleDao qualityRuleDao;
//根据质量规则ID删除质量规则
@Transactional(readOnly=false)
public void deleteByQualityRuleId(List<Long> qualityRuleId){
qualityRuleDao.deleteQualityRuleByQualityRuleId(qualityRuleId);
}
//根据质量规则ID修改质量规则
@Transactional(readOnly=false)
public void updateByQualityRuleId(Long businessId, Long kpiId, Long channelId, Long provinceId, Long dataSourceId, String kpiMonitorTime,String kpiMonitorRange,double integrityThresholdValue,Long timelinessThresholdValue ,Date ruleCrtTime,Date ruleUpdateTime,Long qualityRuleId){
qualityRuleDao.updateQualityRuleByQualityRuleId(businessId, kpiId, channelId, provinceId, dataSourceId, kpiMonitorTime, kpiMonitorRange, integrityThresholdValue, timelinessThresholdValue, ruleCrtTime, ruleUpdateTime, qualityRuleId);
}
}
...@@ -174,6 +174,14 @@ public class PageURLController { ...@@ -174,6 +174,14 @@ public class PageURLController {
public static String ModelMonitor ="ModelManage/ModelMonitor"; public static String ModelMonitor ="ModelManage/ModelMonitor";
//运营支撑下的数据质量核查
public static String RuleResult = "AnalysisSupport/QualityRuleResult";
public static String RuleMaintain = "AnalysisSupport/QualityRuleMaintain";
public static String RuleConfiguration = "AnalysisSupport/QualityRuleConfiguration";
public static String FilterResult = "AnalysisSupport/FilterRuleResult";
public static String FilterMaintain = "AnalysisSupport/FilterRuleMaintain";
public static String FilterConfiguration = "AnalysisSupport/FilterRuleConfiguration";
//基础管理 //基础管理
//AuthorityManage映射到WEB-INF/views下的AuthorityManage/AuthorityManage.jsp页面 //AuthorityManage映射到WEB-INF/views下的AuthorityManage/AuthorityManage.jsp页面
public static String AuthorityManage="AuthorityManage/AuthorityManage"; public static String AuthorityManage="AuthorityManage/AuthorityManage";
......
package com.hp.cmsz.web.analysissupport;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import com.hp.cmsz.web.PageURLController;
/**
* 质量规则维护的修改过滤规则控制类
*
* @author Liu Na
*
*/
@Controller
@RequestMapping(value="AnalysisSupport/FilterRuleConfiguration")
public class FilterRuleConfigurationController {
@RequestMapping()
public String updateFilterRuleForm() {
return PageURLController.FilterConfiguration;
}
}
package com.hp.cmsz.web.analysissupport;
import java.util.Map;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import com.hp.cmsz.web.PageURLController;
/**
* 质量规则维护的新增过滤规则控制类
*
* @author Liu Na
*
*/
@Controller
@RequestMapping(value="AnalysisSupport/FilterRuleMaintain")
public class FilterRuleMaintainController {
@RequestMapping(value = "")
public String filterMaintainHome(Map model){
return PageURLController.FilterMaintain;
}
}
package com.hp.cmsz.web.analysissupport;
import java.util.Map;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import com.hp.cmsz.web.PageURLController;
/**
* 数据质量核查中的过滤规则查询结果控制类
*
* @author Liu Na
*
*/
@Controller
@RequestMapping(value="AnalysisSupport/FilterRuleResult")
public class FilterRuleResultController {
@RequestMapping(value = "")
public String ruleResultHome(
@RequestParam(value = "rulePageNum", defaultValue="1") String rulePageNum,
Map model){
return PageURLController.FilterResult;
}
}
package com.hp.cmsz.web.analysissupport;
import java.text.ParseException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import com.hp.cmsz.web.PageURLController;
/**
* 质量规则维护的修改规则控制类
*
* @author Liu Na
*
*/
@Controller
@RequestMapping(value="AnalysisSupport/QualityRuleConfiguration")
public class QualityRuleConfigurationController {
@RequestMapping()
public String updateQualityRuleForm() {
return PageURLController.RuleConfiguration;
}
}
package com.hp.cmsz.web.analysissupport;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.Map;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
import com.hp.cmsz.entity.Channel;
import com.hp.cmsz.entity.DataModel;
import com.hp.cmsz.entity.DataSource;
import com.hp.cmsz.entity.DataType;
import com.hp.cmsz.entity.Kpi;
import com.hp.cmsz.entity.ModelParameter;
import com.hp.cmsz.entity.Province;
import com.hp.cmsz.repository.AccuracyRuleDao;
import com.hp.cmsz.repository.BusinessDao;
import com.hp.cmsz.repository.ChannelDao;
import com.hp.cmsz.repository.DataSourceDao;
import com.hp.cmsz.repository.DataTypeDao;
import com.hp.cmsz.repository.KpiDao;
import com.hp.cmsz.repository.ProvinceDao;
import com.hp.cmsz.repository.QualityRuleDao;
import com.hp.cmsz.service.BusinessService;
import com.hp.cmsz.service.CmszOperationLogService;
import com.hp.cmsz.service.analysissupport.QualityRuleService;
import com.hp.cmsz.web.PageURLController;
/**
* 质量规则维护的新增规则控制类
*
* @author Liu Na
*
*/
@Controller
@RequestMapping(value="AnalysisSupport/QualityRuleMaintain")
public class QualityRuleMaintainController {
@Autowired
private ProvinceDao provinceDao;
@Autowired
private ChannelDao channelDao;
@Autowired
private BusinessService businessService;
@Autowired
private KpiDao kpiDao;
@Autowired
private DataTypeDao dataTypeDao;
@Autowired
private DataSourceDao dataSourceDao;
// @Autowired
// private QualityRuleDao qualityRuleDao;
//
// @Autowired
// private QualityRuleService qualityRuleService;
//
// @Autowired
// private AccuracyRuleDao accuracyRuleDao;
//
// @Autowired
// private CmszOperationLogService cmszOperationLogService;
@RequestMapping(value = "")
public String ruleMaintainHome(Map model){
//查询出所有的省份
List<Province> provinceList=(List<Province>)provinceDao.findProvince();
//查询出所有的渠道信息
List<Channel> channelList=(List<Channel>)channelDao.findChannel();
//查询出所有的指标
List<Kpi> kpiList=(List<Kpi>)kpiDao.findAll();
//查询出所有的业务
List<String> businessList=businessService.getAllBusinessIdAndBusinessName();
//查询出所有的数据类型
List<DataType> dataTypeList= (List<DataType>)dataTypeDao.findAll();
//查询出所有的数据来源
List<DataSource> dataSourceList=(List<DataSource>)dataSourceDao.findAll();
model.put("provinceList", provinceList);
model.put("channelList", channelList);
model.put("kpiList", kpiList);
model.put("businessList", businessList);
model.put("dataTypeList", dataTypeList);
model.put("dataSourceList", dataSourceList);
return PageURLController.RuleMaintain;
}
// private List<Long> qualityRuleIdList = new ArrayList<Long>();
// //新增准确性规则
// @RequestMapping(value = "/createAccuracyRule*", method = RequestMethod.GET)
// @ResponseBody
// public void createAccuracyRule(
// @RequestParam(value="paramName") String paramName,
// @RequestParam(value="paramValue") String paramValue,
// @RequestParam(value="paramType") String paramType,
// @RequestParam(value="paramName") String paramName,
// @RequestParam(value="paramValue") String paramValue,
// @RequestParam(value="paramType") String paramType,
// @RequestParam(value="paramName") String paramName,
// @RequestParam(value="paramValue") String paramValue,
// @RequestParam(value="paramType") String paramType,
// HttpServletResponse response,HttpServletRequest request) {
//
// ModelParameter modelParameter = new ModelParameter();
// if(!paramName.trim().equals("")){modelParameter.setParameterName(paramName);}
// if(!paramValue.trim().equals("")){modelParameter.setParameterValue(paramValue);}
// if(!paramType.trim().equals("")){modelParameter.setParameterDataType(paramType);}
//
// modelParameterDao.save(modelParameter);
//
// Long dataModelId = modelParameter.getParameterId();
// dataModelIdList.add(dataModelId);
// }
// //新增质量模型
// @RequestMapping(value = "/saveModelDataForm", method = RequestMethod.POST)
// public String saveModelDataForm(HttpServletResponse response,HttpServletRequest request) throws ParseException{
// String dataModelName = "";
// String modelDesc = "";
// String ruleDefinition = "";
// String evaluationMethod = "";
// String evaluationStandard = "";
// String modelType = "";
// String deployedServer = "";
// String modelStatus = "";
// //String cycleMinutes = "";
// String modelExeScriptName = "";
// String kpiTypeId = "";
// String businessEndTime = "";
// String businessStartTime = "";
// Date publishTime = new Date();
// Date updateTime = new Date();
// DataModel dataModel = new DataModel();
// SimpleDateFormat sd = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
// SimpleDateFormat batchFormat = new SimpleDateFormat("yyyyMMdd000001");
// dataModel.setBatchNo(Long.parseLong(batchFormat.format(sd.parse(businessStartTime))));
// dataModel.setDataModelName(dataModelName);
// if(!modelDesc.trim().equals("")){dataModel.setModelDesc(modelDesc);}
// if(!ruleDefinition.trim().equals("")){dataModel.setRuleDefinition(ruleDefinition);}
// if(!evaluationMethod.trim().equals("")){dataModel.setEvaluationMethod(evaluationMethod);}
// if(!evaluationStandard.trim().equals("")){dataModel.setEvaluationStandard(evaluationStandard);}
// if(!modelType.trim().equals("")){dataModel.setDataModelTypeId(Long.parseLong(modelType));}
// if(!deployedServer.trim().equals("")){dataModel.setServerId(Long.parseLong(deployedServer));}
// if(!modelStatus.trim().equals("")){dataModel.setModelStatus(Long.parseLong(modelStatus));}
// if(!kpiTypeId.trim().equals("")){dataModel.setKpiTypeId(Long.parseLong(kpiTypeId));}
// /*if(!cycleMinutes.trim().equals("")){dataModel.setCycleMinutes(Long.parseLong(cycleMinutes));}*/
// dataModel.setModelPublishTime(publishTime);
// dataModel.setModelUpdateTime(updateTime);
// dataModel.setBusinessStartTime(sd.parse(businessStartTime));
// dataModel.setBusinessEndTime(sd.parse(businessEndTime));
// qualityRuleDao.save(qualityRule);
// cmszOperationLogService.createLog("增加","新建质量模型","quality_rule_warehouse_info_t. QUALITY_RULE_ID="+ qualityRule.getQualityRuleId().toString());
// Long dataModelId = dataModel.getDataModelId();
// return "redirect:AnalysisSupport/QualityRuleResult";
// }
}
package com.hp.cmsz.web.analysissupport;
import java.io.IOException;
import java.io.PrintWriter;
import java.io.UnsupportedEncodingException;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
import com.google.gson.Gson;
import com.hp.cmsz.entity.AccuracyRule;
import com.hp.cmsz.entity.Channel;
import com.hp.cmsz.entity.Kpi;
import com.hp.cmsz.entity.Province;
import com.hp.cmsz.entity.QualityRule;
import com.hp.cmsz.repository.AccuracyRuleDao;
import com.hp.cmsz.repository.ChannelDao;
import com.hp.cmsz.repository.KpiDao;
import com.hp.cmsz.repository.ProvinceDao;
import com.hp.cmsz.repository.QualityRuleDao;
import com.hp.cmsz.service.BusinessService;
import com.hp.cmsz.service.CmszOperationLogService;
import com.hp.cmsz.service.analysissupport.AccuracyRuleService;
import com.hp.cmsz.service.analysissupport.QualityRuleService;
import com.hp.cmsz.web.PageURLController;
/**
* 数据质量核查中的质量规则查询结果控制类
*
* @author Liu Na
*
*/
@Controller
@RequestMapping(value="AnalysisSupport/QualityRuleResult")
public class QualityRuleResultController {
// @Autowired
// private ProvinceDao provinceDao;
//
// @Autowired
// private ChannelDao channelDao;
//
// @Autowired
// private BusinessService businessService;
//
// @Autowired
// private KpiDao kpiDao;
//
// @Autowired
// private QualityRuleDao qualityRuleDao;
//
// @Autowired
// private QualityRuleService qualityRuleService;
//
// @Autowired
// private AccuracyRuleService accuracyRuleService;
//
// @Autowired
// private AccuracyRuleDao accuracyRuleDao;
//
// @Autowired
// private CmszOperationLogService cmszOperationLogService;
//
// private String staticProvinceId = "";
// private String staticChannelId = "";
// private String staticKpiId = "";
// private String staticBusinessId = "";
// List<QualityRule> staticQualityRuleList = new ArrayList<QualityRule>();
@RequestMapping(value = "")
public String ruleResultHome(
@RequestParam(value = "rulePageNum", defaultValue="1") String rulePageNum,
Map model){
// //查询出所有的省份
// List<Province> provinceList=(List<Province>)provinceDao.findProvince();
// //查询出所有的渠道信息
// List<Channel> channelList=(List<Channel>)channelDao.findChannel();
// //查询出所有的指标
// List<Kpi> kpiList=(List<Kpi>)kpiDao.findAll();
// //查询出所有的业务
// List<String> businessList=businessService.getAllBusinessIdAndBusinessName();
// //查询出所有的质量规则
// List<QualityRule> qualityRuleList=(List<QualityRule>)qualityRuleDao.findAll();
//
// Gson gson = new Gson();
// model.put("provinceList", gson.toJson(provinceList));
// model.put("channelList", gson.toJson(channelList));
// model.put("kpiList", gson.toJson(kpiList));
// model.put("businessList", gson.toJson(businessList));
// model.put("qualityRuleList", gson.toJson(qualityRuleList));
// model.put("rulePageNum", rulePageNum);
// cmszOperationLogService.createLog("查询","质量规则","质量规则首页");
return PageURLController.RuleResult;
}
// //根据筛选项更新表格
// @RequestMapping(value = "/ruleTableChange*",method = RequestMethod.GET)
// @ResponseBody
// public void modelTableChange(
// @RequestParam(value = "provinceId", defaultValue="") String provinceId,
// @RequestParam(value = "channelId", defaultValue="") String channelId,
// @RequestParam(value = "kpiId", defaultValue="") String kpiId,
// @RequestParam(value = "businessId", defaultValue="") String businessId,
// HttpServletResponse response) throws UnsupportedEncodingException{
// staticProvinceId = provinceId;
// staticChannelId = channelId;
// staticKpiId = kpiId;
// staticBusinessId = businessId;
// List<QualityRule> qualityRuleList = new ArrayList<QualityRule>();
//
// List<Long> provinceIdList = new ArrayList<Long>();
// for(int i=0;i<provinceId.split(",").length;i++){
// provinceIdList.add(Long.parseLong(provinceId.split(",")[i]));
// }
// List<Long> channelIdList = new ArrayList<Long>();
// for(int i=0;i<channelId.split(",").length;i++){
// channelIdList.add(Long.parseLong(channelId.split(",")[i]));
// }
// List<Long> kpiIdList = new ArrayList<Long>();
// for(int i=0;i<kpiId.split(",").length;i++){
// kpiIdList.add(Long.parseLong(kpiId.split(",")[i]));
// }
// List<Long> businessIdList = new ArrayList<Long>();
// for(int i=0;i<businessId.split(",").length;i++){
// businessIdList.add(Long.parseLong(businessId.split(",")[i]));
// }
//
// if(provinceId.equals("") && channelId.equals("") && businessId.equals("") && kpiId.equals("")){
// qualityRuleList = qualityRuleDao.findAll();
// } else {
// qualityRuleList = qualityRuleDao.findByProvinceIdInAndBusinessIdInAndKpiIdInAndChannelIdInOrderByQualityRuleIdDesc(provinceIdList, businessIdList, kpiIdList, channelIdList);
// }
//
// cmszOperationLogService.createLog("查询","质量规则","由筛选项得到质量规则");
// staticQualityRuleList = qualityRuleList;
//
// Gson gson = new Gson();
// response.setContentType("text/Xml;charset=gbk");
// PrintWriter out = null;
// try {
// out = response.getWriter();
// out.println(gson.toJson(qualityRuleList));
// } catch (IOException e) {
// // TODO Auto-generated catch block
// e.printStackTrace();
// }
//
// }
//
// //删掉质量规则
// @RequestMapping(value = "/deleteOneRule*",method = RequestMethod.GET)
// @ResponseBody
// public void deleteRule(
// @RequestParam(value = "qualityRuleId") String qualityRuleId,
// HttpServletResponse response){
// List<Long> qualityRuleIdList = new ArrayList<Long>();
// String[] qualityRuleIdStr = qualityRuleId.split(",");
// for(int i=0; i<qualityRuleIdStr.length; i++){
// qualityRuleIdList.add(Long.parseLong(qualityRuleIdStr[i]));
// }
//
// qualityRuleService.deleteByQualityRuleId(qualityRuleIdList);
// accuracyRuleService.deleteAccuracyRuleByQualityRuleId(qualityRuleIdList);
// cmszOperationLogService.createLog("删除","更新质量规则","quality_rule_warehouse_info_t. QUALITY_RULE_ID="+qualityRuleId);
// //刷新模型表格
// List<QualityRule> qualityRuleList = new ArrayList<QualityRule>();
// qualityRuleList = qualityRuleDao.findAll();
// staticQualityRuleList = qualityRuleList;
//
// Gson gson = new Gson();
// response.setContentType("text/Xml;charset=gbk");
// PrintWriter out = null;
//
// try {
// out = response.getWriter();
// out.println(gson.toJson(qualityRuleList));
// } catch (IOException e) {
// // TODO Auto-generated catch block
// e.printStackTrace();
// }
// }
//
// //查看准确性规则内容
// @RequestMapping(value = "/findAccuracy*",method = RequestMethod.GET)
// @ResponseBody
// public void findAccuracy(
// @RequestParam(value = "qualityRuleId") String qualityRuleId,
// HttpServletResponse response){
// List<AccuracyRule> accuracyRuleList = accuracyRuleDao.findByQualityRuleId(Long.parseLong(qualityRuleId));
// cmszOperationLogService.createLog("查询","准确性规则","查询准确性规则");
// Gson gson = new Gson();
// response.setContentType("text/Xml;charset=gbk");
// PrintWriter out = null;
//
// try {
// out = response.getWriter();
// out.println(gson.toJson(accuracyRuleList));
// } catch (IOException e) {
// // TODO Auto-generated catch block
// e.printStackTrace();
// }
// }
}
...@@ -169,7 +169,7 @@ ...@@ -169,7 +169,7 @@
</li> </li>
</shiro:hasPermission> </shiro:hasPermission>
<shiro:hasPermission name="运营支撑:配置项分析 or 运营支撑:集成商分析 or 运营支撑:竞品分析 or 运营支撑:业务热点分析 or 运营支撑:投诉文本分析 "> <shiro:hasPermission name="运营支撑:配置项分析 or 运营支撑:集成商分析 or 运营支撑:竞品分析 or 运营支撑:业务热点分析 or 运营支撑:投诉文本分析 or 运营支撑:数据质量核查 ">
<li class="titleLine"></li> <li class="titleLine"></li>
<li class="dropdown"> <li class="dropdown">
<a class="dropdonw-toggle" data-toggle="dropdown" role="button" href="#"><span class="menu-icon"><img alt="" src="${ctx}/static/images/4.png" /></span>运营支撑</a> <a class="dropdonw-toggle" data-toggle="dropdown" role="button" href="#"><span class="menu-icon"><img alt="" src="${ctx}/static/images/4.png" /></span>运营支撑</a>
...@@ -221,6 +221,16 @@ ...@@ -221,6 +221,16 @@
</ul> </ul>
</li> </li>
</shiro:hasPermission> </shiro:hasPermission>
<shiro:hasPermission name="运营支撑:数据质量核查">
<li class="dropdown-submenu">
<a href="#">数据质量核查</a>
<ul class="dropdown-menu">
<li><a href="${ctx}/AnalysisSupport/QualityRuleResult">质量规则维护</a></li>
<li><a href="${ctx}/AnalysisSupport/FilterRuleResult">过滤规则维护</a></li>
<li><a href="${ctx}/AnalysisSupport/">质量规则运营</a></li>
</ul>
</li>
</shiro:hasPermission>
</ul> </ul>
</li> </li>
</shiro:hasPermission> </shiro:hasPermission>
...@@ -246,7 +256,8 @@ ...@@ -246,7 +256,8 @@
</shiro:hasPermission> </shiro:hasPermission>
</ul> </ul>
</li> </li>
</shiro:hasPermission> </shiro:hasPermission>
<shiro:hasPermission name="基础管理:配置管理 or 基础管理:系统自监控 or 基础管理:系统数据备份和恢复 or 基础管理:元数据管理 or 基础管理:告警规则管理 or 基础管理:任务管理 "> <shiro:hasPermission name="基础管理:配置管理 or 基础管理:系统自监控 or 基础管理:系统数据备份和恢复 or 基础管理:元数据管理 or 基础管理:告警规则管理 or 基础管理:任务管理 ">
<li class="titleLine"></li> <li class="titleLine"></li>
......
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
</body>
</html>
\ No newline at end of file
<%@ page language="java" pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="tags" tagdir="/WEB-INF/tags"%>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>质量规则维护</title>
<style>
.table-null .table{
margin-bottom: 0px;
}
.table-null .table > tbody > tr > td, .table-null .table > thead > tr > th{
text-align: center;
width: 25%;
}
.table-null td:first-child{
text-align: right;
width: 36%;
}
.table-null tr td:last-child .form-control,.table-null tr td:last-child table{
width: 400px;
}
.file-box{ position:relative;}
.file{ position:absolute; top:0; height:30px; filter:alpha(opacity:0);opacity:0;width:470px;cursor: pointer; }
/* .file-box{ position:relative;width:340px}
.txt{ height:22px; border:1px solid #cdcdcd; width:180px;}
.btn{ background-color:#FFF; border:1px solid #CDCDCD;height:24px; width:70px;}
.file{ position:absolute; top:0; right:80px; height:24px; filter:alpha(opacity:0);opacity: 0;width:260px } */
</style>
</head>
<body>
<div class="container">
<ol class="breadcrumb">
<li><a href="${ctx}/index">首页</a></li>
<li>数据质量核查</li>
<li class="active">过滤规则维护</li>
</ol>
</div>
<div id="main-container main-tab-container">
<div id="content" class="container">
<div class="section">
<div class="tab-content">
<div class="tab-pane fade in active" id="home">
<div class="row">
<div class="col-xs-12">
<div class="table-header">过滤规则上传</div>
<form action="#" class="form-horizontal" id="filterMaintainForm" method="post" enctype="multipart/form-data">
<table id="filterMaintainTable" class="table-null">
<tr><td>省份(<font color="red">必填</font>):</td>
<td><tags:ProvinceTag /></td>
</tr>
<tr><td>渠道(<font color="red">必填</font>):</td>
<td><tags:ChannelTag /></td>
</tr>
<tr><td>业务(<font color="red">必填</font>):</td>
<td><tags:BusinessTag /></td>
</tr>
<tr><td>数据来源(<font color="red">必填</font>):</td>
<td><tags:DataSourceTag /></td>
</tr>
<!--<tr><td>影响开始时间(<font color="red">必填</font>):</td><td><input type="text" class="form-control" id="ruleCrtTime" name="ruleCrtTime" onfocus="WdatePicker({minDate:'#F{$dp.$D(\'ruleCrtTime\')}'})" /></td></tr>
<tr><td>影响结束时间(<font color="red">必填</font>):</td><td><input id="ruleUpdateTime" name="ruleUpdateTime" class="form-control" type="text" onFocus="WdatePicker({maxDate:'#F{$dp.$D(\'ruleUpdateTime\')}'})"> </td></tr> -->
<tr><td>生效开始时间(<font color="red">必填</font>):</td><td><input type="text" class="form-control" id="filterStartTime" name="filterStartTime" onfocus="WdatePicker({minDate:'#F{$dp.$D(\'filterStartTime\')}'})" /></td></tr>
<tr><td>生效结束时间(<font color="red">必填</font>):</td><td><input id="filterEndTime" name="filterEndTime" class="form-control" type="text" onFocus="WdatePicker({maxDate:'#F{$dp.$D(\'filterEndTime\')}'})"> </td></tr>
<tr><td>是否重复(<font color="red">必填</font>):</td><td><input type="radio" class="ifRepeate" name="ifRepeate" value="1" />
<input type="radio" class="ifRepeate" name="ifRepeate" value="0" /></td></tr>
<tr class="period"><td>过滤周期(<font color="red">必填</font>):</td><td><input type="text" class="form-control" name="scopeMaxValue" id="scopeMaxValue" /></td></tr>
<tr><td>过滤原因(<font color="red">必填</font>):</td><td><input type='text' name='filterReason' id='filterReason' class="form-control" style="display: inline;"/></td></tr>
<tr><td></td><td><button type="button" id="ruleSubmit" class="btn btn-primary">确定</button>
<button type="reset" class="btn btn-warning" id="ruleBack">返回</button>
</td></tr>
</table>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script type="text/javascript">
$(".period").hide();
$(".ifRepeate").change(function (){
var selectValue = $("input:radio[name='ifRepeate']:checked").val();
console.log(selectValue);
if (selectValue == 0){
$(".period").hide();
}
if (selectValue == 1){
$(".period").show();
}
})
</script>
\ No newline at end of file
<%@ page language="java" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="tags" tagdir="/WEB-INF/tags"%>
<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags" %>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>过滤规则维护</title>
</head>
<body>
<div>
<div class="container">
<ol class="breadcrumb">
<li><a href="${ctx}/index">首页</a></li>
<li>数据质量核查</li>
<li class="active">过滤规则维护</li>
</ol>
</div>
</div>
<div id="main-container main-tab-container">
<div id="content" class="container">
<div class="tab-bar-bt">
<ul class="nav nav-tabs">
<li><a href="${ctx}/AnalysisSupport/QualityRuleResult">质量规则维护</a></li>
<li class="active"><a href="#home" data-toggle="tab">过滤规则维护</a></li>
<li><a href="${ctx}/">质量规则运营</a></li>
</ul>
</div>
<div class="section">
<div class="tab-content">
<div class="tab-pane fade in active" id="home">
<div class="row me-row">
<div id="slidePushMenus2" class="cbp-spmenu-push">
<div class="slideMenu" id="cbp-spmenu-s2" style="">
<div class="form">
<tags:ProvinceTag />
<tags:ChannelTag />
<tags:BusinessTag />
<button id="submit" class="btn btn-primary" onclick="modelResultSubmit()">提交</button>
<button id="disable" class="btn btn-warning" onclick="modelResultReset()">重置</button>
</div>
</div>
<div class="main col-xs-12">
<div id="mainm2" class="mainm" ></div>
<div class="content clearfix">
<div class="block clearfix">
<button id="showLeftPush2" class="menu-trigger btn btn-default" onclick="toggleMenu('slidePushMenus2')">
<span class="glyphicon glyphicon-list"></span>
</button>
<div class="slide-menu-tags">
</div>
</div>
<div class="col-xs-12">
<div class="table-header">
过滤规则查询结果
<shiro:hasAnyRoles name="admin,dataAnalysis,businessAnalysis">
<div id="time_div" style="top: -6px;float: right;height: 0px;position: relative;">
<button class="btn-sm btn btn-primary btn-sm btn-group btn-group-cog" id="deleteFilter" disabled>删除规则</button>
<button class="btn-sm btn btn-primary btn-sm btn-group btn-group-cog" id="updateFilter" disabled>修改规则</button>
<button class="btn-sm btn btn-primary btn-sm btn-group btn-group-cog" id="createFilter">新建规则</button>
</div>
</shiro:hasAnyRoles>
</div>
<table id="filterResultTable" class="table table-hover table-striped">
</table>
<input type="hidden" id="filterRuleView" name="filterRuleView" value='${filterRuleViewList}' />
</div>
</div>
</div>
</div>
</div>
<form action="#" method="get" id="listForm"></form>
</div>
</div>
</div>
</div>
</div>
<script type="text/javascript" src="${ctx}/static/js/filterResultDetailTable.js"></script>
<script type="text/javascript">
filterResultDetailTable();
$("#createFilter").click(function(){
$.dialog({
title: "提醒",
content:"确定新建过滤规则?",
ok: function(){location.href="${ctx}/AnalysisSupport/FilterRuleMaintain";},
okValue:"确定",
cancel: function(){},
cancelValue:"取消",
lock:true
});
});
$("#updateFilter").click(function(){
var pageNum = $("#goPageNo").val();
$.dialog({
title: "提醒",
content:"确定修改过滤规则?",
ok: function(){location.href="${ctx}/AnalysisSupport/FilterConfiguration?qualityRuleId="+qualityRuleId;},
okValue:"确定",
cancel: function(){},
cancelValue:"取消",
lock:true
});
});
$("#deleteFilter").click(function(){
var pageNum = $("#goPageNo").val();
$.dialog({
title: "提醒",
content:"确定删除过滤规则?",
ok: function(){location.href="${ctx}/AnalysisSupport/FilterDelete?qualityRuleId="+qualityRuleId;},
okValue:"确定",
cancel: function(){},
cancelValue:"取消",
lock:true
});
});
</script>
</body>
</html>
\ No newline at end of file
<%@ page language="java" pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="tags" tagdir="/WEB-INF/tags"%>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>质量规则维护</title>
<style>
.table-null .table{
margin-bottom: 0px;
}
.table-null .table > tbody > tr > td, .table-null .table > thead > tr > th{
text-align: center;
width: 25%;
}
.table-null td:first-child{
text-align: right;
width: 36%;
}
.table-null tr td:last-child .form-control,.table-null tr td:last-child table{
width: 400px;
}
.file-box{ position:relative;}
.file{ position:absolute; top:0; height:30px; filter:alpha(opacity:0);opacity:0;width:470px;cursor: pointer; }
/* .file-box{ position:relative;width:340px}
.txt{ height:22px; border:1px solid #cdcdcd; width:180px;}
.btn{ background-color:#FFF; border:1px solid #CDCDCD;height:24px; width:70px;}
.file{ position:absolute; top:0; right:80px; height:24px; filter:alpha(opacity:0);opacity: 0;width:260px } */
</style>
</head>
<body>
<div class="container">
<ol class="breadcrumb">
<li><a href="${ctx}/index">首页</a></li>
<li>数据质量核查</li>
<li class="active">质量规则维护</li>
</ol>
</div>
<div id="main-container main-tab-container">
<div id="content" class="container">
<div class="section">
<div class="tab-content">
<div class="tab-pane fade in active" id="home">
<div class="row">
<div class="col-xs-12">
<div class="table-header">质量规则更新</div>
<form action="#" class="form-horizontal" id="ruleMaintainForm" method="post" enctype="multipart/form-data">
<table id="ruleMaintainTable" class="table-null">
<tr><td>省份(<font color="red">必填</font>):</td>
<td><tags:ProvinceTag /></td>
</tr>
<tr><td>渠道(<font color="red">必填</font>):</td>
<td><tags:ChannelTag /></td>
</tr>
<tr><td>业务(<font color="red">必填</font>):</td>
<td><tags:BusinessTag /></td>
</tr>
<tr><td>数据来源(<font color="red">必填</font>):</td>
<td><tags:DataSourceTag /></td>
</tr>
<tr><td>数据采集频率(<font color="red">必填</font>):</td>
<td><select class="form-control" name="" id="" style="display: inline;">
<option value="0">30分钟</option>
<option value="1">1小时</option>
<option value="2">1天</option>
<option value="3">1月</option>
</select></td></tr>
<tr><td>指标检测时间(<font color="red">必填</font>):</td>
<td>
<div>
<input type="text" class="form-control" name="kpiMonitorTime" id="kpiMonitorTime" style="display: inline;" />
<select class="form-control" name="" id="" style="display: inline;">
<option value="0">分钟</option>
<option value="1">小时</option>
<option value="2"></option>
<option value="3"></option>
</select>
</div></td>
</tr>
<tr><td>指标检测范围(<font color="red">必填</font>):</td>
<td>
<div>
<input type="text" class="form-control" name="kpiMonitorRange" id="kpiMonitorRange" style="display: inline;" />
<select class="form-control" name="" id="" style="display: inline;">
<option value="0">分钟</option>
<option value="1">小时</option>
<option value="2"></option>
<option value="3"></option>
</select>
</div></td>
</tr>
<tr><td>完整性阈值(<font color="red">必填</font>):</td><td><input type='text' name='integrityThresholdValue' id='integrityThresholdValue' class="form-control" style="display: inline;"/></td></tr>
<tr><td>及时性阈值(<font color="red">必填</font>):</td><td><input type='text' name='timelinessThresholdValue' id='timelinessThresholdValue' class="form-control" style="display: inline;"/></td></tr>
<tr><td>规则创建时间(<font color="red">必填</font>):</td><td><input type="text" class="form-control" id="ruleCrtTime" name="ruleCrtTime" onfocus="WdatePicker({minDate:'#F{$dp.$D(\'ruleCrtTime\')}'})" /></td></tr>
<tr><td>规则更新时间(<font color="red">必填</font>):</td><td><input id="ruleUpdateTime" name="ruleUpdateTime" class="form-control" type="text" onFocus="WdatePicker({maxDate:'#F{$dp.$D(\'ruleUpdateTime\')}'})"> </td></tr>
<tr><td>准确性规则:</td>
<td><select class="form-control" name="accuracyRule" id="accuracyRule" >
<option value="0"></option>
<option value="1">范围类</option>
<option value="2">重复类</option>
</select></td></tr>
<tr class="range"><td>范围最大值:</td><td><input type="text" class="form-control" name="scopeMaxValue" id="scopeMaxValue" /></td></tr>
<tr class="range"><td>范围最小值:</td><td><input type="text" class="form-control" name="scopeMinValue" id="scopeMinValue" /></td></tr>
<tr class="repeate"><td>重复考核粒度:</td><td><input type='text' name='repeatedCheckGranularity' id='repeatedCheckGranularity' class="form-control" style="display: inline;"/></td></tr>
<tr class="repeate"><td>重复考核开始时间:</td><td><input type="text" class="form-control" id="repeatedCheckStartTime" name="repeatedCheckStartTime" onfocus="WdatePicker({minDate:'#F{$dp.$D(\'repeatedCheckStartTime\')}'})" /></td></tr>
<tr class="repeate"><td>重复考核结束时间:</td><td><input id="repeatedCheckEndTime" name="repeatedCheckEndTime" class="form-control" type="text" onFocus="WdatePicker({maxDate:'#F{$dp.$D(\'repeatedCheckEndTime\')}'})"></td></tr>
<tr class="repeate"><td>重复是否连续:</td><td><input type='text' name='ifRepeatedCheckSeries' id='ifRepeatedCheckSeries' class="form-control" style="display: inline;"/></td></tr>
<tr class="repeate"><td>重复最大次数:</td><td><input type='text' name='repeatedCheckMaxTime' id='repeatedCheckMaxTime' class="form-control" style="display: inline;"/></td></tr>
<tr class="repeate"><td>数据是否累计:</td><td><input type='text' name='ifRepeatedCheckSummation' id='ifRepeatedCheckSummation' class="form-control" style="display: inline;"/></td></tr>
<tr><td></td><td><button type="button" id="ruleSubmit" class="btn btn-primary">确定</button>
<button type="reset" class="btn btn-default" id="ruleReset">清空</button>
<button type="reset" class="btn btn-warning" id="ruleBack">返回</button>
</td></tr>
</table>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script type="text/javascript">
$(".range").hide();
$(".repeate").hide();
$("#accuracyRule").change(function (){
var selectValue = $("#accuracyRule").val();
console.log(selectValue);
if (selectValue == 0){
$(".range").hide();
$(".repeate").hide();
}
if (selectValue == 1){
$(".repeate").hide();
$(".range").show();
}
if (selectValue == 2){
$(".range").hide();
$(".repeate").show();
}
})
</script>
</body>
</html>
\ No newline at end of file
<%@ page language="java" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="tags" tagdir="/WEB-INF/tags"%>
<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags" %>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>质量规则维护</title>
</head>
<body>
<div>
<div class="container">
<ol class="breadcrumb">
<li><a href="${ctx}/index">首页</a></li>
<li>数据质量核查</li>
<li class="active">质量规则维护</li>
</ol>
</div>
</div>
<div id="main-container main-tab-container">
<div id="content" class="container">
<div class="tab-bar-bt">
<ul class="nav nav-tabs">
<li class="active"><a href="#home" data-toggle="tab">质量规则维护</a></li>
<li><a href="${ctx}/AnalysisSupport/FilterRuleResult">过滤规则维护</a></li>
<li><a href="${ctx}/">质量规则运营</a></li>
</ul>
</div>
<div class="section">
<div class="tab-content">
<div class="tab-pane fade in active" id="home">
<div class="row me-row">
<div id="slidePushMenus2" class="cbp-spmenu-push">
<div class="slideMenu" id="cbp-spmenu-s2" style="">
<div class="form">
<tags:ProvinceTag />
<tags:ChannelTag />
<tags:BusinessTag />
<button id="submit" class="btn btn-primary" onclick="modelResultSubmit()">提交</button>
<button id="disable" class="btn btn-warning" onclick="modelResultReset()">重置</button>
</div>
</div>
<div class="main col-xs-12">
<div id="mainm2" class="mainm" ></div>
<div class="content clearfix">
<div class="block clearfix">
<button id="showLeftPush2" class="menu-trigger btn btn-default" onclick="toggleMenu('slidePushMenus2')">
<span class="glyphicon glyphicon-list"></span>
</button>
<div class="slide-menu-tags">
</div>
</div>
<div class="col-xs-12">
<div class="table-header">
质量规则查询结果
<shiro:hasAnyRoles name="admin,dataAnalysis,businessAnalysis">
<div id="time_div" style="top: -6px;float: right;height: 0px;position: relative;">
<button class="btn-sm btn btn-primary btn-sm btn-group btn-group-cog" id="deleteRule" disabled>删除规则</button>
<button class="btn-sm btn btn-primary btn-sm btn-group btn-group-cog" id="updateRule" disabled>修改规则</button>
<button class="btn-sm btn btn-primary btn-sm btn-group btn-group-cog" id="createRule">新建规则</button>
</div>
</shiro:hasAnyRoles>
</div>
<table id="ruleResultTable" class="table table-hover table-striped">
</table>
<input type="hidden" id="qualityRuleView" name="qualityRuleView" value='${qualityRuleViewList}' />
</div>
</div>
</div>
</div>
</div>
<form action="#" method="get" id="listForm"></form>
</div>
</div>
</div>
</div>
</div>
<script type="text/javascript" src="${ctx}/static/js/ruleResultDetailTable.js"></script>
<script type="text/javascript">
ruleResultDetailTable();
$("#createRule").click(function(){
$.dialog({
title: "提醒",
content:"确定新建质量规则?",
ok: function(){location.href="${ctx}/AnalysisSupport/QualityRuleMaintain";},
okValue:"确定",
cancel: function(){},
cancelValue:"取消",
lock:true
});
});
$("#updateRule").click(function(){
var pageNum = $("#goPageNo").val();
$.dialog({
title: "提醒",
content:"确定修改质量规则?",
ok: function(){location.href="${ctx}/AnalysisSupport/RuleConfiguration?qualityRuleId="+qualityRuleId;},
okValue:"确定",
cancel: function(){},
cancelValue:"取消",
lock:true
});
});
$("#deleteRule").click(function(){
var pageNum = $("#goPageNo").val();
$.dialog({
title: "提醒",
content:"确定删除质量规则?",
ok: function(){location.href="${ctx}/AnalysisSupport/RuleDelete?qualityRuleId="+qualityRuleId;},
okValue:"确定",
cancel: function(){},
cancelValue:"取消",
lock:true
});
});
</script>
</body>
</html>
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
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