13 changed files with 1516 additions and 9 deletions
@ -0,0 +1,117 @@ |
|||
package com.ccsens.ht.bean.po; |
|||
|
|||
import java.io.Serializable; |
|||
import java.util.Date; |
|||
|
|||
public class HtReportRelevance implements Serializable { |
|||
private Long id; |
|||
|
|||
private String reportCode; |
|||
|
|||
private Long reportId; |
|||
|
|||
private String impression; |
|||
|
|||
private Integer socre; |
|||
|
|||
private String pdfUrl; |
|||
|
|||
private Date createTime; |
|||
|
|||
private Date updateTime; |
|||
|
|||
private Byte isDel; |
|||
|
|||
private static final long serialVersionUID = 1L; |
|||
|
|||
public Long getId() { |
|||
return id; |
|||
} |
|||
|
|||
public void setId(Long id) { |
|||
this.id = id; |
|||
} |
|||
|
|||
public String getReportCode() { |
|||
return reportCode; |
|||
} |
|||
|
|||
public void setReportCode(String reportCode) { |
|||
this.reportCode = reportCode == null ? null : reportCode.trim(); |
|||
} |
|||
|
|||
public Long getReportId() { |
|||
return reportId; |
|||
} |
|||
|
|||
public void setReportId(Long reportId) { |
|||
this.reportId = reportId; |
|||
} |
|||
|
|||
public String getImpression() { |
|||
return impression; |
|||
} |
|||
|
|||
public void setImpression(String impression) { |
|||
this.impression = impression == null ? null : impression.trim(); |
|||
} |
|||
|
|||
public Integer getSocre() { |
|||
return socre; |
|||
} |
|||
|
|||
public void setSocre(Integer socre) { |
|||
this.socre = socre; |
|||
} |
|||
|
|||
public String getPdfUrl() { |
|||
return pdfUrl; |
|||
} |
|||
|
|||
public void setPdfUrl(String pdfUrl) { |
|||
this.pdfUrl = pdfUrl == null ? null : pdfUrl.trim(); |
|||
} |
|||
|
|||
public Date getCreateTime() { |
|||
return createTime; |
|||
} |
|||
|
|||
public void setCreateTime(Date createTime) { |
|||
this.createTime = createTime; |
|||
} |
|||
|
|||
public Date getUpdateTime() { |
|||
return updateTime; |
|||
} |
|||
|
|||
public void setUpdateTime(Date updateTime) { |
|||
this.updateTime = updateTime; |
|||
} |
|||
|
|||
public Byte getIsDel() { |
|||
return isDel; |
|||
} |
|||
|
|||
public void setIsDel(Byte isDel) { |
|||
this.isDel = isDel; |
|||
} |
|||
|
|||
@Override |
|||
public String toString() { |
|||
StringBuilder sb = new StringBuilder(); |
|||
sb.append(getClass().getSimpleName()); |
|||
sb.append(" ["); |
|||
sb.append("Hash = ").append(hashCode()); |
|||
sb.append(", id=").append(id); |
|||
sb.append(", reportCode=").append(reportCode); |
|||
sb.append(", reportId=").append(reportId); |
|||
sb.append(", impression=").append(impression); |
|||
sb.append(", socre=").append(socre); |
|||
sb.append(", pdfUrl=").append(pdfUrl); |
|||
sb.append(", createTime=").append(createTime); |
|||
sb.append(", updateTime=").append(updateTime); |
|||
sb.append(", isDel=").append(isDel); |
|||
sb.append("]"); |
|||
return sb.toString(); |
|||
} |
|||
} |
@ -0,0 +1,771 @@ |
|||
package com.ccsens.ht.bean.po; |
|||
|
|||
import java.util.ArrayList; |
|||
import java.util.Date; |
|||
import java.util.List; |
|||
|
|||
public class HtReportRelevanceExample { |
|||
protected String orderByClause; |
|||
|
|||
protected boolean distinct; |
|||
|
|||
protected List<Criteria> oredCriteria; |
|||
|
|||
public HtReportRelevanceExample() { |
|||
oredCriteria = new ArrayList<Criteria>(); |
|||
} |
|||
|
|||
public void setOrderByClause(String orderByClause) { |
|||
this.orderByClause = orderByClause; |
|||
} |
|||
|
|||
public String getOrderByClause() { |
|||
return orderByClause; |
|||
} |
|||
|
|||
public void setDistinct(boolean distinct) { |
|||
this.distinct = distinct; |
|||
} |
|||
|
|||
public boolean isDistinct() { |
|||
return distinct; |
|||
} |
|||
|
|||
public List<Criteria> getOredCriteria() { |
|||
return oredCriteria; |
|||
} |
|||
|
|||
public void or(Criteria criteria) { |
|||
oredCriteria.add(criteria); |
|||
} |
|||
|
|||
public Criteria or() { |
|||
Criteria criteria = createCriteriaInternal(); |
|||
oredCriteria.add(criteria); |
|||
return criteria; |
|||
} |
|||
|
|||
public Criteria createCriteria() { |
|||
Criteria criteria = createCriteriaInternal(); |
|||
if (oredCriteria.size() == 0) { |
|||
oredCriteria.add(criteria); |
|||
} |
|||
return criteria; |
|||
} |
|||
|
|||
protected Criteria createCriteriaInternal() { |
|||
Criteria criteria = new Criteria(); |
|||
return criteria; |
|||
} |
|||
|
|||
public void clear() { |
|||
oredCriteria.clear(); |
|||
orderByClause = null; |
|||
distinct = false; |
|||
} |
|||
|
|||
protected abstract static class GeneratedCriteria { |
|||
protected List<Criterion> criteria; |
|||
|
|||
protected GeneratedCriteria() { |
|||
super(); |
|||
criteria = new ArrayList<Criterion>(); |
|||
} |
|||
|
|||
public boolean isValid() { |
|||
return criteria.size() > 0; |
|||
} |
|||
|
|||
public List<Criterion> getAllCriteria() { |
|||
return criteria; |
|||
} |
|||
|
|||
public List<Criterion> getCriteria() { |
|||
return criteria; |
|||
} |
|||
|
|||
protected void addCriterion(String condition) { |
|||
if (condition == null) { |
|||
throw new RuntimeException("Value for condition cannot be null"); |
|||
} |
|||
criteria.add(new Criterion(condition)); |
|||
} |
|||
|
|||
protected void addCriterion(String condition, Object value, String property) { |
|||
if (value == null) { |
|||
throw new RuntimeException("Value for " + property + " cannot be null"); |
|||
} |
|||
criteria.add(new Criterion(condition, value)); |
|||
} |
|||
|
|||
protected void addCriterion(String condition, Object value1, Object value2, String property) { |
|||
if (value1 == null || value2 == null) { |
|||
throw new RuntimeException("Between values for " + property + " cannot be null"); |
|||
} |
|||
criteria.add(new Criterion(condition, value1, value2)); |
|||
} |
|||
|
|||
public Criteria andIdIsNull() { |
|||
addCriterion("id is null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdIsNotNull() { |
|||
addCriterion("id is not null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdEqualTo(Long value) { |
|||
addCriterion("id =", value, "id"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdNotEqualTo(Long value) { |
|||
addCriterion("id <>", value, "id"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdGreaterThan(Long value) { |
|||
addCriterion("id >", value, "id"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdGreaterThanOrEqualTo(Long value) { |
|||
addCriterion("id >=", value, "id"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdLessThan(Long value) { |
|||
addCriterion("id <", value, "id"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdLessThanOrEqualTo(Long value) { |
|||
addCriterion("id <=", value, "id"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdIn(List<Long> values) { |
|||
addCriterion("id in", values, "id"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdNotIn(List<Long> values) { |
|||
addCriterion("id not in", values, "id"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdBetween(Long value1, Long value2) { |
|||
addCriterion("id between", value1, value2, "id"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIdNotBetween(Long value1, Long value2) { |
|||
addCriterion("id not between", value1, value2, "id"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeIsNull() { |
|||
addCriterion("report_code is null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeIsNotNull() { |
|||
addCriterion("report_code is not null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeEqualTo(String value) { |
|||
addCriterion("report_code =", value, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeNotEqualTo(String value) { |
|||
addCriterion("report_code <>", value, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeGreaterThan(String value) { |
|||
addCriterion("report_code >", value, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeGreaterThanOrEqualTo(String value) { |
|||
addCriterion("report_code >=", value, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeLessThan(String value) { |
|||
addCriterion("report_code <", value, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeLessThanOrEqualTo(String value) { |
|||
addCriterion("report_code <=", value, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeLike(String value) { |
|||
addCriterion("report_code like", value, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeNotLike(String value) { |
|||
addCriterion("report_code not like", value, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeIn(List<String> values) { |
|||
addCriterion("report_code in", values, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeNotIn(List<String> values) { |
|||
addCriterion("report_code not in", values, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeBetween(String value1, String value2) { |
|||
addCriterion("report_code between", value1, value2, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportCodeNotBetween(String value1, String value2) { |
|||
addCriterion("report_code not between", value1, value2, "reportCode"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdIsNull() { |
|||
addCriterion("report_id is null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdIsNotNull() { |
|||
addCriterion("report_id is not null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdEqualTo(Long value) { |
|||
addCriterion("report_id =", value, "reportId"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdNotEqualTo(Long value) { |
|||
addCriterion("report_id <>", value, "reportId"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdGreaterThan(Long value) { |
|||
addCriterion("report_id >", value, "reportId"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdGreaterThanOrEqualTo(Long value) { |
|||
addCriterion("report_id >=", value, "reportId"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdLessThan(Long value) { |
|||
addCriterion("report_id <", value, "reportId"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdLessThanOrEqualTo(Long value) { |
|||
addCriterion("report_id <=", value, "reportId"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdIn(List<Long> values) { |
|||
addCriterion("report_id in", values, "reportId"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdNotIn(List<Long> values) { |
|||
addCriterion("report_id not in", values, "reportId"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdBetween(Long value1, Long value2) { |
|||
addCriterion("report_id between", value1, value2, "reportId"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andReportIdNotBetween(Long value1, Long value2) { |
|||
addCriterion("report_id not between", value1, value2, "reportId"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionIsNull() { |
|||
addCriterion("impression is null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionIsNotNull() { |
|||
addCriterion("impression is not null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionEqualTo(String value) { |
|||
addCriterion("impression =", value, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionNotEqualTo(String value) { |
|||
addCriterion("impression <>", value, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionGreaterThan(String value) { |
|||
addCriterion("impression >", value, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionGreaterThanOrEqualTo(String value) { |
|||
addCriterion("impression >=", value, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionLessThan(String value) { |
|||
addCriterion("impression <", value, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionLessThanOrEqualTo(String value) { |
|||
addCriterion("impression <=", value, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionLike(String value) { |
|||
addCriterion("impression like", value, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionNotLike(String value) { |
|||
addCriterion("impression not like", value, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionIn(List<String> values) { |
|||
addCriterion("impression in", values, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionNotIn(List<String> values) { |
|||
addCriterion("impression not in", values, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionBetween(String value1, String value2) { |
|||
addCriterion("impression between", value1, value2, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andImpressionNotBetween(String value1, String value2) { |
|||
addCriterion("impression not between", value1, value2, "impression"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreIsNull() { |
|||
addCriterion("socre is null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreIsNotNull() { |
|||
addCriterion("socre is not null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreEqualTo(Integer value) { |
|||
addCriterion("socre =", value, "socre"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreNotEqualTo(Integer value) { |
|||
addCriterion("socre <>", value, "socre"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreGreaterThan(Integer value) { |
|||
addCriterion("socre >", value, "socre"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreGreaterThanOrEqualTo(Integer value) { |
|||
addCriterion("socre >=", value, "socre"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreLessThan(Integer value) { |
|||
addCriterion("socre <", value, "socre"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreLessThanOrEqualTo(Integer value) { |
|||
addCriterion("socre <=", value, "socre"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreIn(List<Integer> values) { |
|||
addCriterion("socre in", values, "socre"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreNotIn(List<Integer> values) { |
|||
addCriterion("socre not in", values, "socre"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreBetween(Integer value1, Integer value2) { |
|||
addCriterion("socre between", value1, value2, "socre"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andSocreNotBetween(Integer value1, Integer value2) { |
|||
addCriterion("socre not between", value1, value2, "socre"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlIsNull() { |
|||
addCriterion("pdf_url is null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlIsNotNull() { |
|||
addCriterion("pdf_url is not null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlEqualTo(String value) { |
|||
addCriterion("pdf_url =", value, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlNotEqualTo(String value) { |
|||
addCriterion("pdf_url <>", value, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlGreaterThan(String value) { |
|||
addCriterion("pdf_url >", value, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlGreaterThanOrEqualTo(String value) { |
|||
addCriterion("pdf_url >=", value, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlLessThan(String value) { |
|||
addCriterion("pdf_url <", value, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlLessThanOrEqualTo(String value) { |
|||
addCriterion("pdf_url <=", value, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlLike(String value) { |
|||
addCriterion("pdf_url like", value, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlNotLike(String value) { |
|||
addCriterion("pdf_url not like", value, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlIn(List<String> values) { |
|||
addCriterion("pdf_url in", values, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlNotIn(List<String> values) { |
|||
addCriterion("pdf_url not in", values, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlBetween(String value1, String value2) { |
|||
addCriterion("pdf_url between", value1, value2, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andPdfUrlNotBetween(String value1, String value2) { |
|||
addCriterion("pdf_url not between", value1, value2, "pdfUrl"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeIsNull() { |
|||
addCriterion("create_time is null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeIsNotNull() { |
|||
addCriterion("create_time is not null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeEqualTo(Date value) { |
|||
addCriterion("create_time =", value, "createTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeNotEqualTo(Date value) { |
|||
addCriterion("create_time <>", value, "createTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeGreaterThan(Date value) { |
|||
addCriterion("create_time >", value, "createTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) { |
|||
addCriterion("create_time >=", value, "createTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeLessThan(Date value) { |
|||
addCriterion("create_time <", value, "createTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeLessThanOrEqualTo(Date value) { |
|||
addCriterion("create_time <=", value, "createTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeIn(List<Date> values) { |
|||
addCriterion("create_time in", values, "createTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeNotIn(List<Date> values) { |
|||
addCriterion("create_time not in", values, "createTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeBetween(Date value1, Date value2) { |
|||
addCriterion("create_time between", value1, value2, "createTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andCreateTimeNotBetween(Date value1, Date value2) { |
|||
addCriterion("create_time not between", value1, value2, "createTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeIsNull() { |
|||
addCriterion("update_time is null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeIsNotNull() { |
|||
addCriterion("update_time is not null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeEqualTo(Date value) { |
|||
addCriterion("update_time =", value, "updateTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeNotEqualTo(Date value) { |
|||
addCriterion("update_time <>", value, "updateTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeGreaterThan(Date value) { |
|||
addCriterion("update_time >", value, "updateTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) { |
|||
addCriterion("update_time >=", value, "updateTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeLessThan(Date value) { |
|||
addCriterion("update_time <", value, "updateTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeLessThanOrEqualTo(Date value) { |
|||
addCriterion("update_time <=", value, "updateTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeIn(List<Date> values) { |
|||
addCriterion("update_time in", values, "updateTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeNotIn(List<Date> values) { |
|||
addCriterion("update_time not in", values, "updateTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeBetween(Date value1, Date value2) { |
|||
addCriterion("update_time between", value1, value2, "updateTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andUpdateTimeNotBetween(Date value1, Date value2) { |
|||
addCriterion("update_time not between", value1, value2, "updateTime"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelIsNull() { |
|||
addCriterion("is_del is null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelIsNotNull() { |
|||
addCriterion("is_del is not null"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelEqualTo(Byte value) { |
|||
addCriterion("is_del =", value, "isDel"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelNotEqualTo(Byte value) { |
|||
addCriterion("is_del <>", value, "isDel"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelGreaterThan(Byte value) { |
|||
addCriterion("is_del >", value, "isDel"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelGreaterThanOrEqualTo(Byte value) { |
|||
addCriterion("is_del >=", value, "isDel"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelLessThan(Byte value) { |
|||
addCriterion("is_del <", value, "isDel"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelLessThanOrEqualTo(Byte value) { |
|||
addCriterion("is_del <=", value, "isDel"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelIn(List<Byte> values) { |
|||
addCriterion("is_del in", values, "isDel"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelNotIn(List<Byte> values) { |
|||
addCriterion("is_del not in", values, "isDel"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelBetween(Byte value1, Byte value2) { |
|||
addCriterion("is_del between", value1, value2, "isDel"); |
|||
return (Criteria) this; |
|||
} |
|||
|
|||
public Criteria andIsDelNotBetween(Byte value1, Byte value2) { |
|||
addCriterion("is_del not between", value1, value2, "isDel"); |
|||
return (Criteria) this; |
|||
} |
|||
} |
|||
|
|||
public static class Criteria extends GeneratedCriteria { |
|||
|
|||
protected Criteria() { |
|||
super(); |
|||
} |
|||
} |
|||
|
|||
public static class Criterion { |
|||
private String condition; |
|||
|
|||
private Object value; |
|||
|
|||
private Object secondValue; |
|||
|
|||
private boolean noValue; |
|||
|
|||
private boolean singleValue; |
|||
|
|||
private boolean betweenValue; |
|||
|
|||
private boolean listValue; |
|||
|
|||
private String typeHandler; |
|||
|
|||
public String getCondition() { |
|||
return condition; |
|||
} |
|||
|
|||
public Object getValue() { |
|||
return value; |
|||
} |
|||
|
|||
public Object getSecondValue() { |
|||
return secondValue; |
|||
} |
|||
|
|||
public boolean isNoValue() { |
|||
return noValue; |
|||
} |
|||
|
|||
public boolean isSingleValue() { |
|||
return singleValue; |
|||
} |
|||
|
|||
public boolean isBetweenValue() { |
|||
return betweenValue; |
|||
} |
|||
|
|||
public boolean isListValue() { |
|||
return listValue; |
|||
} |
|||
|
|||
public String getTypeHandler() { |
|||
return typeHandler; |
|||
} |
|||
|
|||
protected Criterion(String condition) { |
|||
super(); |
|||
this.condition = condition; |
|||
this.typeHandler = null; |
|||
this.noValue = true; |
|||
} |
|||
|
|||
protected Criterion(String condition, Object value, String typeHandler) { |
|||
super(); |
|||
this.condition = condition; |
|||
this.value = value; |
|||
this.typeHandler = typeHandler; |
|||
if (value instanceof List<?>) { |
|||
this.listValue = true; |
|||
} else { |
|||
this.singleValue = true; |
|||
} |
|||
} |
|||
|
|||
protected Criterion(String condition, Object value) { |
|||
this(condition, value, null); |
|||
} |
|||
|
|||
protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { |
|||
super(); |
|||
this.condition = condition; |
|||
this.value = value; |
|||
this.secondValue = secondValue; |
|||
this.typeHandler = typeHandler; |
|||
this.betweenValue = true; |
|||
} |
|||
|
|||
protected Criterion(String condition, Object value, Object secondValue) { |
|||
this(condition, value, secondValue, null); |
|||
} |
|||
} |
|||
} |
@ -0,0 +1,30 @@ |
|||
package com.ccsens.ht.persist.mapper; |
|||
|
|||
import com.ccsens.ht.bean.po.HtReportRelevance; |
|||
import com.ccsens.ht.bean.po.HtReportRelevanceExample; |
|||
import java.util.List; |
|||
import org.apache.ibatis.annotations.Param; |
|||
|
|||
public interface HtReportRelevanceMapper { |
|||
long countByExample(HtReportRelevanceExample example); |
|||
|
|||
int deleteByExample(HtReportRelevanceExample example); |
|||
|
|||
int deleteByPrimaryKey(Long id); |
|||
|
|||
int insert(HtReportRelevance record); |
|||
|
|||
int insertSelective(HtReportRelevance record); |
|||
|
|||
List<HtReportRelevance> selectByExample(HtReportRelevanceExample example); |
|||
|
|||
HtReportRelevance selectByPrimaryKey(Long id); |
|||
|
|||
int updateByExampleSelective(@Param("record") HtReportRelevance record, @Param("example") HtReportRelevanceExample example); |
|||
|
|||
int updateByExample(@Param("record") HtReportRelevance record, @Param("example") HtReportRelevanceExample example); |
|||
|
|||
int updateByPrimaryKeySelective(HtReportRelevance record); |
|||
|
|||
int updateByPrimaryKey(HtReportRelevance record); |
|||
} |
@ -0,0 +1,240 @@ |
|||
package com.ccsens.ht.service; |
|||
|
|||
import cn.hutool.core.collection.CollectionUtil; |
|||
import cn.hutool.core.lang.Snowflake; |
|||
import cn.hutool.core.util.ObjectUtil; |
|||
import cn.hutool.core.util.StrUtil; |
|||
import com.ccsens.ht.bean.dto.PatientReportDto; |
|||
import com.ccsens.ht.bean.po.HtPatientReport; |
|||
import com.ccsens.ht.bean.po.HtReportRelevance; |
|||
import com.ccsens.ht.bean.po.HtReportRelevanceExample; |
|||
import com.ccsens.ht.bean.vo.PatientReportVo; |
|||
import com.ccsens.ht.persist.dao.HtPatientReportDao; |
|||
import com.ccsens.ht.persist.mapper.HtReportRelevanceMapper; |
|||
import com.ccsens.ht.uitl.Constant; |
|||
import com.ccsens.util.CodeEnum; |
|||
import com.ccsens.util.PdfUtil; |
|||
import com.ccsens.util.PropUtil; |
|||
import com.ccsens.util.exception.BaseException; |
|||
import lombok.extern.slf4j.Slf4j; |
|||
import org.springframework.stereotype.Service; |
|||
import org.springframework.transaction.annotation.Propagation; |
|||
import org.springframework.transaction.annotation.Transactional; |
|||
|
|||
import javax.annotation.Resource; |
|||
import java.util.ArrayList; |
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author 逗 |
|||
*/ |
|||
@Slf4j |
|||
@Service |
|||
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class) |
|||
public class ExportService implements IExportService { |
|||
@Resource |
|||
private HtPatientReportDao htPatientReportDao; |
|||
@Resource |
|||
private HtReportRelevanceMapper reportRelevanceMapper; |
|||
@Resource |
|||
private IPatientReportService patientReportService; |
|||
@Resource |
|||
private Snowflake snowflake; |
|||
|
|||
@Override |
|||
public String exportReport(PatientReportDto.QueryDetail param, Long userId) { |
|||
log.info("根据报告单类型导出报告单:{}, 操作用户:{}", param, userId); |
|||
// TODO 暂时不导出rey试题,将传入参数改为1
|
|||
param.setRey(1); |
|||
//查看是否已生成对应文件路径
|
|||
HtPatientReport report = htPatientReportDao.selectByPrimaryKey(param.getId()); |
|||
if (report == null) { |
|||
throw new BaseException(CodeEnum.REPORT_NOT_FOUND); |
|||
} |
|||
//查询报告单类型关联的信息
|
|||
HtReportRelevance reportRelevance; |
|||
HtReportRelevanceExample relevanceExample = new HtReportRelevanceExample(); |
|||
relevanceExample.createCriteria().andReportIdEqualTo(param.getId()).andReportCodeEqualTo(param.getReport()); |
|||
List<HtReportRelevance> reportRelevanceList = reportRelevanceMapper.selectByExample(relevanceExample); |
|||
if(CollectionUtil.isNotEmpty(reportRelevanceList)){ |
|||
reportRelevance = reportRelevanceList.get(0); |
|||
}else { |
|||
reportRelevance = new HtReportRelevance(); |
|||
reportRelevance.setId(snowflake.nextId()); |
|||
reportRelevance.setReportCode(param.getReport()); |
|||
reportRelevance.setReportId(param.getId()); |
|||
reportRelevanceMapper.insertSelective(reportRelevance); |
|||
} |
|||
//如果以前有生成的信息,直接返回
|
|||
if (StrUtil.isNotBlank(reportRelevance.getPdfUrl())) { |
|||
return report.getUrl(); |
|||
} |
|||
//查看报告单和试题分数信息
|
|||
PatientReportVo.ReprotDetail detail = patientReportService.queryReportDetail(param, userId); |
|||
if (detail == null) { |
|||
throw new BaseException(CodeEnum.REPORT_NOT_FOUND); |
|||
} |
|||
//添加受试者合作评分和初步印象
|
|||
log.info("报告单和试题信息 {}", detail); |
|||
PatientReportVo.ReprotPatient patient = detail.getPatient(); |
|||
patient.setWorkingScore(reportRelevance.getSocre()); |
|||
patient.setInitialImpression(reportRelevance.getImpression()); |
|||
//生成写入pdf数据
|
|||
List<PdfUtil.Row> content = new ArrayList<>(); |
|||
switch (param.getReport()){ |
|||
case Constant.Ht.Report.PARENT_CODE_2: |
|||
case Constant.Ht.Report.PARENT_CODE_3: |
|||
writeParentCode2(content,detail.getScores()); |
|||
//添加初步印象和受试者合作评分
|
|||
addScoreAndImpression(detail, content); |
|||
//添加测评员和报告日期
|
|||
initLast(content, 2); |
|||
break; |
|||
default: |
|||
detail.getScores().forEach(reportScore -> content.addAll(reportScore.toRow())); |
|||
PdfUtil.Row row = new PdfUtil.Row(); |
|||
PdfUtil.Cell initWordCell = addCell(row, "初步印象", 2, 2); |
|||
initWordCell.setHeight(PdfUtil.Cell.defaultHeight * 2); |
|||
PdfUtil.Cell initImplCell = addCell(row, detail.getPatient().getInitialImpression(), 6, 2); |
|||
initImplCell.setHeight(PdfUtil.Cell.defaultHeight * 2); |
|||
initImplCell.setBorderRight(1); |
|||
initImplCell.setCenter(false); |
|||
content.add(row); |
|||
//添加测评员和报告日期
|
|||
initLast(content, 4); |
|||
break; |
|||
} |
|||
|
|||
//表头
|
|||
String[] split = detail.getPatient().getHospital().split(""); |
|||
String title = String.join(" ", split); |
|||
|
|||
//生成pdf并返回路径
|
|||
String path = PropUtil.imgDomain + "/" + PdfUtil.createPdf(PropUtil.path, title, Constant.Ht.Report.PARENT_NAME, new PdfUtil.Margin(), detail.getPatient().toPdfRow(), content); |
|||
//TODO 将路径存入报告单关联信息表
|
|||
// reportRelevance.setPdfUrl(path);
|
|||
// reportRelevanceMapper.updateByPrimaryKeySelective(reportRelevance);
|
|||
log.info("生成文件路径:{}", path); |
|||
return path; |
|||
} |
|||
|
|||
private void addScoreAndImpression(PatientReportVo.ReprotDetail detail, List<PdfUtil.Row> content) { |
|||
PdfUtil.Row workingScore = new PdfUtil.Row(); |
|||
workingScore.addCell(new PdfUtil.Cell("受试者合作评分",1,1)); |
|||
String a = "A 感兴趣、配合关心结果;\n"; |
|||
String b = "B 表现出感兴趣和合作,出于对医生的友好;\n"; |
|||
String c = "C 顺从、不感兴趣;\n"; |
|||
String d = "D 不满、需多次要求配合,拒绝部分检查;\n"; |
|||
String e = "E 不配合或拒绝"; |
|||
String s = ""; |
|||
switch (detail.getPatient().getWorkingScore()){ |
|||
case 0: |
|||
s = "√ " + a + " " + b + " " + c + " " + d + " " + e; |
|||
break; |
|||
case 1: |
|||
s = " " + a + "√ " + b + " " + c + " " + d + " " + e; |
|||
break; |
|||
case 2: |
|||
s = " " + a + " " + b + "√ " + c + " " + d + " " + e; |
|||
break; |
|||
case 3: |
|||
s = " " + a + " " + b + " " + c + "√ " + d + " " + e; |
|||
break; |
|||
case 4: |
|||
s = " " + a + " " + b + " " + c + " " + d + "√ " + e; |
|||
break; |
|||
default: |
|||
s = a + b + c + d + e; |
|||
break; |
|||
} |
|||
// String s = "√ A 感兴趣、配合关心结果;\n" +
|
|||
// " B 表现出感兴趣和合作,出于对医生的友好;\n" +
|
|||
// " C 顺从、不感兴趣;\n" +
|
|||
// " D 不满、需多次要求配合,拒绝部分检查;\n" +
|
|||
// " E 不配合或拒绝";
|
|||
// workingScore.addCell(new PdfUtil.Cell(String.valueOf(detail.getPatient().getWorkingScore()),2,1,1));
|
|||
PdfUtil.Cell cell = new PdfUtil.Cell(s, 3, 1, 1); |
|||
cell.setCenter(false); |
|||
workingScore.addCell(cell); |
|||
content.add(workingScore); |
|||
PdfUtil.Row impression = new PdfUtil.Row(); |
|||
|
|||
|
|||
|
|||
impression.addCell(new PdfUtil.Cell("初步印象",1,1)); |
|||
impression.addCell(new PdfUtil.Cell(String.valueOf(detail.getPatient().getInitialImpression()),3,1,1)); |
|||
content.add(impression); |
|||
} |
|||
|
|||
private void writeParentCode2(List<PdfUtil.Row> content, List<PatientReportVo.ReportScore> scores) { |
|||
PdfUtil.Row title = new PdfUtil.Row(); |
|||
title.addCell(new PdfUtil.Cell("项目")); |
|||
title.addCell(new PdfUtil.Cell()); |
|||
title.addCell(new PdfUtil.Cell("得分")); |
|||
PdfUtil.Cell r = new PdfUtil.Cell(); |
|||
r.setContent("异常参考值/说明"); |
|||
r.setBorderRight(1); |
|||
title.addCell(r); |
|||
content.add(title); |
|||
scores.forEach(reportScore -> { |
|||
if(CollectionUtil.isEmpty(reportScore.getSubReport())){ |
|||
PdfUtil.Row row = new PdfUtil.Row(); |
|||
|
|||
PdfUtil.Cell cellName = new PdfUtil.Cell(); |
|||
cellName.setColSpan(2); |
|||
cellName.setContent(reportScore.getName()); |
|||
row.addCell(cellName); |
|||
PdfUtil.Cell cellScore = new PdfUtil.Cell(); |
|||
cellScore.setContent(ObjectUtil.isNotNull(reportScore.getScore()) ? reportScore.getScore().toString() : ""); |
|||
row.addCell(cellScore); |
|||
PdfUtil.Cell remark = new PdfUtil.Cell(); |
|||
remark.setContent(reportScore.getRemark()); |
|||
remark.setBorderRight(1); |
|||
row.addCell(remark); |
|||
|
|||
content.add(row); |
|||
}else { |
|||
for (int i = 0; i < reportScore.getSubReport().size(); i++) { |
|||
PatientReportVo.ReportScore score = reportScore.getSubReport().get(i); |
|||
PdfUtil.Row row = new PdfUtil.Row(); |
|||
if(i == 0){ |
|||
PdfUtil.Cell cellName = new PdfUtil.Cell(); |
|||
cellName.setRowSpan(reportScore.getSubReport().size()); |
|||
cellName.setContent(reportScore.getName()); |
|||
row.addCell(cellName); |
|||
} |
|||
row.addCell(new PdfUtil.Cell(score.getName())); |
|||
row.addCell(new PdfUtil.Cell(ObjectUtil.isNotNull(score.getScore()) ? score.getScore().toString() : "")); |
|||
PdfUtil.Cell remark = new PdfUtil.Cell(); |
|||
remark.setContent(score.getRemark()); |
|||
remark.setBorderRight(1); |
|||
row.addCell(remark); |
|||
content.add(row); |
|||
} |
|||
} |
|||
}); |
|||
} |
|||
|
|||
|
|||
|
|||
private PdfUtil.Cell addCell(PdfUtil.Row row, String content, int colSpan, int rowSpan, int... border) { |
|||
PdfUtil.Cell cell1 = new PdfUtil.Cell(); |
|||
cell1.setContent(content); |
|||
cell1.setRowSpan(rowSpan); |
|||
cell1.setColSpan(colSpan); |
|||
cell1.setBorder(border == null || border.length == 0 ? 1 : border[0]); |
|||
row.addCell(cell1); |
|||
return cell1; |
|||
} |
|||
|
|||
private void initLast(List<PdfUtil.Row> content, int totalSpan) { |
|||
PdfUtil.Row row2 = new PdfUtil.Row(); |
|||
PdfUtil.Cell doctorCell = addCell(row2, "测评员:", totalSpan, 1, 0); |
|||
doctorCell.setBorderLeft(null); |
|||
doctorCell.setBorderBottom(null); |
|||
PdfUtil.Cell dateCell = addCell(row2, "报告日期:", totalSpan, 1, 0); |
|||
dateCell.setBorderBottom(null); |
|||
dateCell.setBorderLeft(null); |
|||
content.add(row2); |
|||
} |
|||
} |
@ -0,0 +1,16 @@ |
|||
package com.ccsens.ht.service; |
|||
|
|||
import com.ccsens.ht.bean.dto.PatientReportDto; |
|||
|
|||
/** |
|||
* @author 逗 |
|||
*/ |
|||
public interface IExportService { |
|||
/** |
|||
* 根据报告单类型导出pdf |
|||
* @param param 报告单id和类型 |
|||
* @param userId userId |
|||
* @return 返回pdf路径 |
|||
*/ |
|||
String exportReport(PatientReportDto.QueryDetail param, Long userId); |
|||
} |
@ -1,5 +1,5 @@ |
|||
spring: |
|||
profiles: |
|||
active: prod |
|||
include: common, util-prod |
|||
active: dev |
|||
include: common, util-dev |
|||
|
|||
|
@ -0,0 +1,276 @@ |
|||
<?xml version="1.0" encoding="UTF-8"?> |
|||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
|||
<mapper namespace="com.ccsens.ht.persist.mapper.HtReportRelevanceMapper"> |
|||
<resultMap id="BaseResultMap" type="com.ccsens.ht.bean.po.HtReportRelevance"> |
|||
<id column="id" jdbcType="BIGINT" property="id" /> |
|||
<result column="report_code" jdbcType="VARCHAR" property="reportCode" /> |
|||
<result column="report_id" jdbcType="BIGINT" property="reportId" /> |
|||
<result column="impression" jdbcType="VARCHAR" property="impression" /> |
|||
<result column="socre" jdbcType="INTEGER" property="socre" /> |
|||
<result column="pdf_url" jdbcType="VARCHAR" property="pdfUrl" /> |
|||
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" /> |
|||
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" /> |
|||
<result column="is_del" jdbcType="TINYINT" property="isDel" /> |
|||
</resultMap> |
|||
<sql id="Example_Where_Clause"> |
|||
<where> |
|||
<foreach collection="oredCriteria" item="criteria" separator="or"> |
|||
<if test="criteria.valid"> |
|||
<trim prefix="(" prefixOverrides="and" suffix=")"> |
|||
<foreach collection="criteria.criteria" item="criterion"> |
|||
<choose> |
|||
<when test="criterion.noValue"> |
|||
and ${criterion.condition} |
|||
</when> |
|||
<when test="criterion.singleValue"> |
|||
and ${criterion.condition} #{criterion.value} |
|||
</when> |
|||
<when test="criterion.betweenValue"> |
|||
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} |
|||
</when> |
|||
<when test="criterion.listValue"> |
|||
and ${criterion.condition} |
|||
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=","> |
|||
#{listItem} |
|||
</foreach> |
|||
</when> |
|||
</choose> |
|||
</foreach> |
|||
</trim> |
|||
</if> |
|||
</foreach> |
|||
</where> |
|||
</sql> |
|||
<sql id="Update_By_Example_Where_Clause"> |
|||
<where> |
|||
<foreach collection="example.oredCriteria" item="criteria" separator="or"> |
|||
<if test="criteria.valid"> |
|||
<trim prefix="(" prefixOverrides="and" suffix=")"> |
|||
<foreach collection="criteria.criteria" item="criterion"> |
|||
<choose> |
|||
<when test="criterion.noValue"> |
|||
and ${criterion.condition} |
|||
</when> |
|||
<when test="criterion.singleValue"> |
|||
and ${criterion.condition} #{criterion.value} |
|||
</when> |
|||
<when test="criterion.betweenValue"> |
|||
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} |
|||
</when> |
|||
<when test="criterion.listValue"> |
|||
and ${criterion.condition} |
|||
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=","> |
|||
#{listItem} |
|||
</foreach> |
|||
</when> |
|||
</choose> |
|||
</foreach> |
|||
</trim> |
|||
</if> |
|||
</foreach> |
|||
</where> |
|||
</sql> |
|||
<sql id="Base_Column_List"> |
|||
id, report_code, report_id, impression, socre, pdf_url, create_time, update_time, |
|||
is_del |
|||
</sql> |
|||
<select id="selectByExample" parameterType="com.ccsens.ht.bean.po.HtReportRelevanceExample" resultMap="BaseResultMap"> |
|||
select |
|||
<if test="distinct"> |
|||
distinct |
|||
</if> |
|||
<include refid="Base_Column_List" /> |
|||
from t_ht_report_relevance |
|||
<if test="_parameter != null"> |
|||
<include refid="Example_Where_Clause" /> |
|||
</if> |
|||
<if test="orderByClause != null"> |
|||
order by ${orderByClause} |
|||
</if> |
|||
</select> |
|||
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap"> |
|||
select |
|||
<include refid="Base_Column_List" /> |
|||
from t_ht_report_relevance |
|||
where id = #{id,jdbcType=BIGINT} |
|||
</select> |
|||
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long"> |
|||
delete from t_ht_report_relevance |
|||
where id = #{id,jdbcType=BIGINT} |
|||
</delete> |
|||
<delete id="deleteByExample" parameterType="com.ccsens.ht.bean.po.HtReportRelevanceExample"> |
|||
delete from t_ht_report_relevance |
|||
<if test="_parameter != null"> |
|||
<include refid="Example_Where_Clause" /> |
|||
</if> |
|||
</delete> |
|||
<insert id="insert" parameterType="com.ccsens.ht.bean.po.HtReportRelevance"> |
|||
insert into t_ht_report_relevance (id, report_code, report_id, |
|||
impression, socre, pdf_url, |
|||
create_time, update_time, is_del |
|||
) |
|||
values (#{id,jdbcType=BIGINT}, #{reportCode,jdbcType=VARCHAR}, #{reportId,jdbcType=BIGINT}, |
|||
#{impression,jdbcType=VARCHAR}, #{socre,jdbcType=INTEGER}, #{pdfUrl,jdbcType=VARCHAR}, |
|||
#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, #{isDel,jdbcType=TINYINT} |
|||
) |
|||
</insert> |
|||
<insert id="insertSelective" parameterType="com.ccsens.ht.bean.po.HtReportRelevance"> |
|||
insert into t_ht_report_relevance |
|||
<trim prefix="(" suffix=")" suffixOverrides=","> |
|||
<if test="id != null"> |
|||
id, |
|||
</if> |
|||
<if test="reportCode != null"> |
|||
report_code, |
|||
</if> |
|||
<if test="reportId != null"> |
|||
report_id, |
|||
</if> |
|||
<if test="impression != null"> |
|||
impression, |
|||
</if> |
|||
<if test="socre != null"> |
|||
socre, |
|||
</if> |
|||
<if test="pdfUrl != null"> |
|||
pdf_url, |
|||
</if> |
|||
<if test="createTime != null"> |
|||
create_time, |
|||
</if> |
|||
<if test="updateTime != null"> |
|||
update_time, |
|||
</if> |
|||
<if test="isDel != null"> |
|||
is_del, |
|||
</if> |
|||
</trim> |
|||
<trim prefix="values (" suffix=")" suffixOverrides=","> |
|||
<if test="id != null"> |
|||
#{id,jdbcType=BIGINT}, |
|||
</if> |
|||
<if test="reportCode != null"> |
|||
#{reportCode,jdbcType=VARCHAR}, |
|||
</if> |
|||
<if test="reportId != null"> |
|||
#{reportId,jdbcType=BIGINT}, |
|||
</if> |
|||
<if test="impression != null"> |
|||
#{impression,jdbcType=VARCHAR}, |
|||
</if> |
|||
<if test="socre != null"> |
|||
#{socre,jdbcType=INTEGER}, |
|||
</if> |
|||
<if test="pdfUrl != null"> |
|||
#{pdfUrl,jdbcType=VARCHAR}, |
|||
</if> |
|||
<if test="createTime != null"> |
|||
#{createTime,jdbcType=TIMESTAMP}, |
|||
</if> |
|||
<if test="updateTime != null"> |
|||
#{updateTime,jdbcType=TIMESTAMP}, |
|||
</if> |
|||
<if test="isDel != null"> |
|||
#{isDel,jdbcType=TINYINT}, |
|||
</if> |
|||
</trim> |
|||
</insert> |
|||
<select id="countByExample" parameterType="com.ccsens.ht.bean.po.HtReportRelevanceExample" resultType="java.lang.Long"> |
|||
select count(*) from t_ht_report_relevance |
|||
<if test="_parameter != null"> |
|||
<include refid="Example_Where_Clause" /> |
|||
</if> |
|||
</select> |
|||
<update id="updateByExampleSelective" parameterType="map"> |
|||
update t_ht_report_relevance |
|||
<set> |
|||
<if test="record.id != null"> |
|||
id = #{record.id,jdbcType=BIGINT}, |
|||
</if> |
|||
<if test="record.reportCode != null"> |
|||
report_code = #{record.reportCode,jdbcType=VARCHAR}, |
|||
</if> |
|||
<if test="record.reportId != null"> |
|||
report_id = #{record.reportId,jdbcType=BIGINT}, |
|||
</if> |
|||
<if test="record.impression != null"> |
|||
impression = #{record.impression,jdbcType=VARCHAR}, |
|||
</if> |
|||
<if test="record.socre != null"> |
|||
socre = #{record.socre,jdbcType=INTEGER}, |
|||
</if> |
|||
<if test="record.pdfUrl != null"> |
|||
pdf_url = #{record.pdfUrl,jdbcType=VARCHAR}, |
|||
</if> |
|||
<if test="record.createTime != null"> |
|||
create_time = #{record.createTime,jdbcType=TIMESTAMP}, |
|||
</if> |
|||
<if test="record.updateTime != null"> |
|||
update_time = #{record.updateTime,jdbcType=TIMESTAMP}, |
|||
</if> |
|||
<if test="record.isDel != null"> |
|||
is_del = #{record.isDel,jdbcType=TINYINT}, |
|||
</if> |
|||
</set> |
|||
<if test="_parameter != null"> |
|||
<include refid="Update_By_Example_Where_Clause" /> |
|||
</if> |
|||
</update> |
|||
<update id="updateByExample" parameterType="map"> |
|||
update t_ht_report_relevance |
|||
set id = #{record.id,jdbcType=BIGINT}, |
|||
report_code = #{record.reportCode,jdbcType=VARCHAR}, |
|||
report_id = #{record.reportId,jdbcType=BIGINT}, |
|||
impression = #{record.impression,jdbcType=VARCHAR}, |
|||
socre = #{record.socre,jdbcType=INTEGER}, |
|||
pdf_url = #{record.pdfUrl,jdbcType=VARCHAR}, |
|||
create_time = #{record.createTime,jdbcType=TIMESTAMP}, |
|||
update_time = #{record.updateTime,jdbcType=TIMESTAMP}, |
|||
is_del = #{record.isDel,jdbcType=TINYINT} |
|||
<if test="_parameter != null"> |
|||
<include refid="Update_By_Example_Where_Clause" /> |
|||
</if> |
|||
</update> |
|||
<update id="updateByPrimaryKeySelective" parameterType="com.ccsens.ht.bean.po.HtReportRelevance"> |
|||
update t_ht_report_relevance |
|||
<set> |
|||
<if test="reportCode != null"> |
|||
report_code = #{reportCode,jdbcType=VARCHAR}, |
|||
</if> |
|||
<if test="reportId != null"> |
|||
report_id = #{reportId,jdbcType=BIGINT}, |
|||
</if> |
|||
<if test="impression != null"> |
|||
impression = #{impression,jdbcType=VARCHAR}, |
|||
</if> |
|||
<if test="socre != null"> |
|||
socre = #{socre,jdbcType=INTEGER}, |
|||
</if> |
|||
<if test="pdfUrl != null"> |
|||
pdf_url = #{pdfUrl,jdbcType=VARCHAR}, |
|||
</if> |
|||
<if test="createTime != null"> |
|||
create_time = #{createTime,jdbcType=TIMESTAMP}, |
|||
</if> |
|||
<if test="updateTime != null"> |
|||
update_time = #{updateTime,jdbcType=TIMESTAMP}, |
|||
</if> |
|||
<if test="isDel != null"> |
|||
is_del = #{isDel,jdbcType=TINYINT}, |
|||
</if> |
|||
</set> |
|||
where id = #{id,jdbcType=BIGINT} |
|||
</update> |
|||
<update id="updateByPrimaryKey" parameterType="com.ccsens.ht.bean.po.HtReportRelevance"> |
|||
update t_ht_report_relevance |
|||
set report_code = #{reportCode,jdbcType=VARCHAR}, |
|||
report_id = #{reportId,jdbcType=BIGINT}, |
|||
impression = #{impression,jdbcType=VARCHAR}, |
|||
socre = #{socre,jdbcType=INTEGER}, |
|||
pdf_url = #{pdfUrl,jdbcType=VARCHAR}, |
|||
create_time = #{createTime,jdbcType=TIMESTAMP}, |
|||
update_time = #{updateTime,jdbcType=TIMESTAMP}, |
|||
is_del = #{isDel,jdbcType=TINYINT} |
|||
where id = #{id,jdbcType=BIGINT} |
|||
</update> |
|||
</mapper> |
Loading…
Reference in new issue