袁野 2 weeks ago
parent 41843a2e53
commit 0a924233ba
  1. 25
      service/src/main/java/com/hfkj/dao/CmsContentMapper.java
  2. 14
      service/src/main/java/com/hfkj/dao/CmsContentSqlProvider.java
  3. 15
      service/src/main/java/com/hfkj/entity/CmsContent.java
  4. 60
      service/src/main/java/com/hfkj/entity/CmsContentExample.java

@ -41,16 +41,18 @@ public interface CmsContentMapper extends CmsContentMapperExt {
@Insert({ @Insert({
"insert into cms_content (platform_code, code, ", "insert into cms_content (platform_code, code, ",
"`name`, img, jump_type, ", "`name`, img, jump_type, ",
"show_type, jump_url, ", "show_type, show_data_id, ",
"appid, create_time, ", "jump_url, appid, ",
"update_time, `status`, ", "create_time, update_time, ",
"ext_1, ext_2, ext_3)", "`status`, ext_1, ext_2, ",
"ext_3)",
"values (#{platformCode,jdbcType=VARCHAR}, #{code,jdbcType=VARCHAR}, ", "values (#{platformCode,jdbcType=VARCHAR}, #{code,jdbcType=VARCHAR}, ",
"#{name,jdbcType=VARCHAR}, #{img,jdbcType=VARCHAR}, #{jumpType,jdbcType=INTEGER}, ", "#{name,jdbcType=VARCHAR}, #{img,jdbcType=VARCHAR}, #{jumpType,jdbcType=INTEGER}, ",
"#{showType,jdbcType=INTEGER}, #{jumpUrl,jdbcType=VARCHAR}, ", "#{showType,jdbcType=INTEGER}, #{showDataId,jdbcType=INTEGER}, ",
"#{appid,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, ", "#{jumpUrl,jdbcType=VARCHAR}, #{appid,jdbcType=VARCHAR}, ",
"#{updateTime,jdbcType=TIMESTAMP}, #{status,jdbcType=INTEGER}, ", "#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, ",
"#{ext1,jdbcType=VARCHAR}, #{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" "#{status,jdbcType=INTEGER}, #{ext1,jdbcType=VARCHAR}, #{ext2,jdbcType=VARCHAR}, ",
"#{ext3,jdbcType=VARCHAR})"
}) })
@Options(useGeneratedKeys=true,keyProperty="id") @Options(useGeneratedKeys=true,keyProperty="id")
int insert(CmsContent record); int insert(CmsContent record);
@ -68,6 +70,7 @@ public interface CmsContentMapper extends CmsContentMapperExt {
@Result(column="img", property="img", jdbcType=JdbcType.VARCHAR), @Result(column="img", property="img", jdbcType=JdbcType.VARCHAR),
@Result(column="jump_type", property="jumpType", jdbcType=JdbcType.INTEGER), @Result(column="jump_type", property="jumpType", jdbcType=JdbcType.INTEGER),
@Result(column="show_type", property="showType", jdbcType=JdbcType.INTEGER), @Result(column="show_type", property="showType", jdbcType=JdbcType.INTEGER),
@Result(column="show_data_id", property="showDataId", jdbcType=JdbcType.INTEGER),
@Result(column="jump_url", property="jumpUrl", jdbcType=JdbcType.VARCHAR), @Result(column="jump_url", property="jumpUrl", jdbcType=JdbcType.VARCHAR),
@Result(column="appid", property="appid", jdbcType=JdbcType.VARCHAR), @Result(column="appid", property="appid", jdbcType=JdbcType.VARCHAR),
@Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP),
@ -81,8 +84,8 @@ public interface CmsContentMapper extends CmsContentMapperExt {
@Select({ @Select({
"select", "select",
"id, platform_code, code, `name`, img, jump_type, show_type, jump_url, appid, ", "id, platform_code, code, `name`, img, jump_type, show_type, show_data_id, jump_url, ",
"create_time, update_time, `status`, ext_1, ext_2, ext_3", "appid, create_time, update_time, `status`, ext_1, ext_2, ext_3",
"from cms_content", "from cms_content",
"where id = #{id,jdbcType=BIGINT}" "where id = #{id,jdbcType=BIGINT}"
}) })
@ -94,6 +97,7 @@ public interface CmsContentMapper extends CmsContentMapperExt {
@Result(column="img", property="img", jdbcType=JdbcType.VARCHAR), @Result(column="img", property="img", jdbcType=JdbcType.VARCHAR),
@Result(column="jump_type", property="jumpType", jdbcType=JdbcType.INTEGER), @Result(column="jump_type", property="jumpType", jdbcType=JdbcType.INTEGER),
@Result(column="show_type", property="showType", jdbcType=JdbcType.INTEGER), @Result(column="show_type", property="showType", jdbcType=JdbcType.INTEGER),
@Result(column="show_data_id", property="showDataId", jdbcType=JdbcType.INTEGER),
@Result(column="jump_url", property="jumpUrl", jdbcType=JdbcType.VARCHAR), @Result(column="jump_url", property="jumpUrl", jdbcType=JdbcType.VARCHAR),
@Result(column="appid", property="appid", jdbcType=JdbcType.VARCHAR), @Result(column="appid", property="appid", jdbcType=JdbcType.VARCHAR),
@Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP),
@ -122,6 +126,7 @@ public interface CmsContentMapper extends CmsContentMapperExt {
"img = #{img,jdbcType=VARCHAR},", "img = #{img,jdbcType=VARCHAR},",
"jump_type = #{jumpType,jdbcType=INTEGER},", "jump_type = #{jumpType,jdbcType=INTEGER},",
"show_type = #{showType,jdbcType=INTEGER},", "show_type = #{showType,jdbcType=INTEGER},",
"show_data_id = #{showDataId,jdbcType=INTEGER},",
"jump_url = #{jumpUrl,jdbcType=VARCHAR},", "jump_url = #{jumpUrl,jdbcType=VARCHAR},",
"appid = #{appid,jdbcType=VARCHAR},", "appid = #{appid,jdbcType=VARCHAR},",
"create_time = #{createTime,jdbcType=TIMESTAMP},", "create_time = #{createTime,jdbcType=TIMESTAMP},",

@ -52,6 +52,10 @@ public class CmsContentSqlProvider {
sql.VALUES("show_type", "#{showType,jdbcType=INTEGER}"); sql.VALUES("show_type", "#{showType,jdbcType=INTEGER}");
} }
if (record.getShowDataId() != null) {
sql.VALUES("show_data_id", "#{showDataId,jdbcType=INTEGER}");
}
if (record.getJumpUrl() != null) { if (record.getJumpUrl() != null) {
sql.VALUES("jump_url", "#{jumpUrl,jdbcType=VARCHAR}"); sql.VALUES("jump_url", "#{jumpUrl,jdbcType=VARCHAR}");
} }
@ -100,6 +104,7 @@ public class CmsContentSqlProvider {
sql.SELECT("img"); sql.SELECT("img");
sql.SELECT("jump_type"); sql.SELECT("jump_type");
sql.SELECT("show_type"); sql.SELECT("show_type");
sql.SELECT("show_data_id");
sql.SELECT("jump_url"); sql.SELECT("jump_url");
sql.SELECT("appid"); sql.SELECT("appid");
sql.SELECT("create_time"); sql.SELECT("create_time");
@ -153,6 +158,10 @@ public class CmsContentSqlProvider {
sql.SET("show_type = #{record.showType,jdbcType=INTEGER}"); sql.SET("show_type = #{record.showType,jdbcType=INTEGER}");
} }
if (record.getShowDataId() != null) {
sql.SET("show_data_id = #{record.showDataId,jdbcType=INTEGER}");
}
if (record.getJumpUrl() != null) { if (record.getJumpUrl() != null) {
sql.SET("jump_url = #{record.jumpUrl,jdbcType=VARCHAR}"); sql.SET("jump_url = #{record.jumpUrl,jdbcType=VARCHAR}");
} }
@ -200,6 +209,7 @@ public class CmsContentSqlProvider {
sql.SET("img = #{record.img,jdbcType=VARCHAR}"); sql.SET("img = #{record.img,jdbcType=VARCHAR}");
sql.SET("jump_type = #{record.jumpType,jdbcType=INTEGER}"); sql.SET("jump_type = #{record.jumpType,jdbcType=INTEGER}");
sql.SET("show_type = #{record.showType,jdbcType=INTEGER}"); sql.SET("show_type = #{record.showType,jdbcType=INTEGER}");
sql.SET("show_data_id = #{record.showDataId,jdbcType=INTEGER}");
sql.SET("jump_url = #{record.jumpUrl,jdbcType=VARCHAR}"); sql.SET("jump_url = #{record.jumpUrl,jdbcType=VARCHAR}");
sql.SET("appid = #{record.appid,jdbcType=VARCHAR}"); sql.SET("appid = #{record.appid,jdbcType=VARCHAR}");
sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}"); sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}");
@ -242,6 +252,10 @@ public class CmsContentSqlProvider {
sql.SET("show_type = #{showType,jdbcType=INTEGER}"); sql.SET("show_type = #{showType,jdbcType=INTEGER}");
} }
if (record.getShowDataId() != null) {
sql.SET("show_data_id = #{showDataId,jdbcType=INTEGER}");
}
if (record.getJumpUrl() != null) { if (record.getJumpUrl() != null) {
sql.SET("jump_url = #{jumpUrl,jdbcType=VARCHAR}"); sql.SET("jump_url = #{jumpUrl,jdbcType=VARCHAR}");
} }

@ -44,10 +44,15 @@ public class CmsContent implements Serializable {
private Integer jumpType; private Integer jumpType;
/** /**
* 展示类型1数据展示 * 展示类型1双数据 2:四数据 3:横版多数据
*/ */
private Integer showType; private Integer showType;
/**
* 数据编码
*/
private Integer showDataId;
/** /**
* 跳转地址 * 跳转地址
*/ */
@ -137,6 +142,14 @@ public class CmsContent implements Serializable {
this.showType = showType; this.showType = showType;
} }
public Integer getShowDataId() {
return showDataId;
}
public void setShowDataId(Integer showDataId) {
this.showDataId = showDataId;
}
public String getJumpUrl() { public String getJumpUrl() {
return jumpUrl; return jumpUrl;
} }

@ -585,6 +585,66 @@ public class CmsContentExample {
return (Criteria) this; return (Criteria) this;
} }
public Criteria andShowDataIdIsNull() {
addCriterion("show_data_id is null");
return (Criteria) this;
}
public Criteria andShowDataIdIsNotNull() {
addCriterion("show_data_id is not null");
return (Criteria) this;
}
public Criteria andShowDataIdEqualTo(Integer value) {
addCriterion("show_data_id =", value, "showDataId");
return (Criteria) this;
}
public Criteria andShowDataIdNotEqualTo(Integer value) {
addCriterion("show_data_id <>", value, "showDataId");
return (Criteria) this;
}
public Criteria andShowDataIdGreaterThan(Integer value) {
addCriterion("show_data_id >", value, "showDataId");
return (Criteria) this;
}
public Criteria andShowDataIdGreaterThanOrEqualTo(Integer value) {
addCriterion("show_data_id >=", value, "showDataId");
return (Criteria) this;
}
public Criteria andShowDataIdLessThan(Integer value) {
addCriterion("show_data_id <", value, "showDataId");
return (Criteria) this;
}
public Criteria andShowDataIdLessThanOrEqualTo(Integer value) {
addCriterion("show_data_id <=", value, "showDataId");
return (Criteria) this;
}
public Criteria andShowDataIdIn(List<Integer> values) {
addCriterion("show_data_id in", values, "showDataId");
return (Criteria) this;
}
public Criteria andShowDataIdNotIn(List<Integer> values) {
addCriterion("show_data_id not in", values, "showDataId");
return (Criteria) this;
}
public Criteria andShowDataIdBetween(Integer value1, Integer value2) {
addCriterion("show_data_id between", value1, value2, "showDataId");
return (Criteria) this;
}
public Criteria andShowDataIdNotBetween(Integer value1, Integer value2) {
addCriterion("show_data_id not between", value1, value2, "showDataId");
return (Criteria) this;
}
public Criteria andJumpUrlIsNull() { public Criteria andJumpUrlIsNull() {
addCriterion("jump_url is null"); addCriterion("jump_url is null");
return (Criteria) this; return (Criteria) this;

Loading…
Cancel
Save