袁野 2 months ago
parent 9437f6a390
commit 874cb4fbc4
  1. 33
      service/src/main/java/com/hfkj/dao/GoodsShoppingCartMapper.java
  2. 14
      service/src/main/java/com/hfkj/dao/GoodsShoppingCartSqlProvider.java
  3. 16
      service/src/main/java/com/hfkj/entity/GoodsShoppingCart.java
  4. 60
      service/src/main/java/com/hfkj/entity/GoodsShoppingCartExample.java

@ -40,20 +40,20 @@ public interface GoodsShoppingCartMapper extends GoodsShoppingCartMapperExt {
@Insert({ @Insert({
"insert into goods_shopping_cart (goods_id, goods_type, ", "insert into goods_shopping_cart (goods_id, goods_type, ",
"user_id, title, img, ", "`source`, user_id, title, ",
"specs_name, specs_id, ", "img, specs_name, ",
"num, price, whether_check, ", "specs_id, num, price, ",
"lose_efficacy, create_time, ", "whether_check, lose_efficacy, ",
"update_time, mer_id, ", "create_time, update_time, ",
"mer_name, `status`, ", "mer_id, mer_name, `status`, ",
"ext_1, ext_2, ext_3)", "ext_1, ext_2, ext_3)",
"values (#{goodsId,jdbcType=BIGINT}, #{goodsType,jdbcType=INTEGER}, ", "values (#{goodsId,jdbcType=BIGINT}, #{goodsType,jdbcType=INTEGER}, ",
"#{userId,jdbcType=BIGINT}, #{title,jdbcType=VARCHAR}, #{img,jdbcType=VARCHAR}, ", "#{source,jdbcType=INTEGER}, #{userId,jdbcType=BIGINT}, #{title,jdbcType=VARCHAR}, ",
"#{specsName,jdbcType=VARCHAR}, #{specsId,jdbcType=BIGINT}, ", "#{img,jdbcType=VARCHAR}, #{specsName,jdbcType=VARCHAR}, ",
"#{num,jdbcType=INTEGER}, #{price,jdbcType=DECIMAL}, #{whetherCheck,jdbcType=BIT}, ", "#{specsId,jdbcType=BIGINT}, #{num,jdbcType=INTEGER}, #{price,jdbcType=DECIMAL}, ",
"#{loseEfficacy,jdbcType=BIT}, #{createTime,jdbcType=TIMESTAMP}, ", "#{whetherCheck,jdbcType=BIT}, #{loseEfficacy,jdbcType=BIT}, ",
"#{updateTime,jdbcType=TIMESTAMP}, #{merId,jdbcType=BIGINT}, ", "#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, ",
"#{merName,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER}, ", "#{merId,jdbcType=BIGINT}, #{merName,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER}, ",
"#{ext1,jdbcType=VARCHAR}, #{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" "#{ext1,jdbcType=VARCHAR}, #{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})"
}) })
@Options(useGeneratedKeys=true,keyProperty="id") @Options(useGeneratedKeys=true,keyProperty="id")
@ -68,6 +68,7 @@ public interface GoodsShoppingCartMapper extends GoodsShoppingCartMapperExt {
@Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true),
@Result(column="goods_id", property="goodsId", jdbcType=JdbcType.BIGINT), @Result(column="goods_id", property="goodsId", jdbcType=JdbcType.BIGINT),
@Result(column="goods_type", property="goodsType", jdbcType=JdbcType.INTEGER), @Result(column="goods_type", property="goodsType", jdbcType=JdbcType.INTEGER),
@Result(column="source", property="source", jdbcType=JdbcType.INTEGER),
@Result(column="user_id", property="userId", jdbcType=JdbcType.BIGINT), @Result(column="user_id", property="userId", jdbcType=JdbcType.BIGINT),
@Result(column="title", property="title", jdbcType=JdbcType.VARCHAR), @Result(column="title", property="title", jdbcType=JdbcType.VARCHAR),
@Result(column="img", property="img", jdbcType=JdbcType.VARCHAR), @Result(column="img", property="img", jdbcType=JdbcType.VARCHAR),
@ -90,9 +91,9 @@ public interface GoodsShoppingCartMapper extends GoodsShoppingCartMapperExt {
@Select({ @Select({
"select", "select",
"id, goods_id, goods_type, user_id, title, img, specs_name, specs_id, num, price, ", "id, goods_id, goods_type, `source`, user_id, title, img, specs_name, specs_id, ",
"whether_check, lose_efficacy, create_time, update_time, mer_id, mer_name, `status`, ", "num, price, whether_check, lose_efficacy, create_time, update_time, mer_id, ",
"ext_1, ext_2, ext_3", "mer_name, `status`, ext_1, ext_2, ext_3",
"from goods_shopping_cart", "from goods_shopping_cart",
"where id = #{id,jdbcType=BIGINT}" "where id = #{id,jdbcType=BIGINT}"
}) })
@ -100,6 +101,7 @@ public interface GoodsShoppingCartMapper extends GoodsShoppingCartMapperExt {
@Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true),
@Result(column="goods_id", property="goodsId", jdbcType=JdbcType.BIGINT), @Result(column="goods_id", property="goodsId", jdbcType=JdbcType.BIGINT),
@Result(column="goods_type", property="goodsType", jdbcType=JdbcType.INTEGER), @Result(column="goods_type", property="goodsType", jdbcType=JdbcType.INTEGER),
@Result(column="source", property="source", jdbcType=JdbcType.INTEGER),
@Result(column="user_id", property="userId", jdbcType=JdbcType.BIGINT), @Result(column="user_id", property="userId", jdbcType=JdbcType.BIGINT),
@Result(column="title", property="title", jdbcType=JdbcType.VARCHAR), @Result(column="title", property="title", jdbcType=JdbcType.VARCHAR),
@Result(column="img", property="img", jdbcType=JdbcType.VARCHAR), @Result(column="img", property="img", jdbcType=JdbcType.VARCHAR),
@ -133,6 +135,7 @@ public interface GoodsShoppingCartMapper extends GoodsShoppingCartMapperExt {
"update goods_shopping_cart", "update goods_shopping_cart",
"set goods_id = #{goodsId,jdbcType=BIGINT},", "set goods_id = #{goodsId,jdbcType=BIGINT},",
"goods_type = #{goodsType,jdbcType=INTEGER},", "goods_type = #{goodsType,jdbcType=INTEGER},",
"`source` = #{source,jdbcType=INTEGER},",
"user_id = #{userId,jdbcType=BIGINT},", "user_id = #{userId,jdbcType=BIGINT},",
"title = #{title,jdbcType=VARCHAR},", "title = #{title,jdbcType=VARCHAR},",
"img = #{img,jdbcType=VARCHAR},", "img = #{img,jdbcType=VARCHAR},",

@ -36,6 +36,10 @@ public class GoodsShoppingCartSqlProvider {
sql.VALUES("goods_type", "#{goodsType,jdbcType=INTEGER}"); sql.VALUES("goods_type", "#{goodsType,jdbcType=INTEGER}");
} }
if (record.getSource() != null) {
sql.VALUES("`source`", "#{source,jdbcType=INTEGER}");
}
if (record.getUserId() != null) { if (record.getUserId() != null) {
sql.VALUES("user_id", "#{userId,jdbcType=BIGINT}"); sql.VALUES("user_id", "#{userId,jdbcType=BIGINT}");
} }
@ -116,6 +120,7 @@ public class GoodsShoppingCartSqlProvider {
} }
sql.SELECT("goods_id"); sql.SELECT("goods_id");
sql.SELECT("goods_type"); sql.SELECT("goods_type");
sql.SELECT("`source`");
sql.SELECT("user_id"); sql.SELECT("user_id");
sql.SELECT("title"); sql.SELECT("title");
sql.SELECT("img"); sql.SELECT("img");
@ -162,6 +167,10 @@ public class GoodsShoppingCartSqlProvider {
sql.SET("goods_type = #{record.goodsType,jdbcType=INTEGER}"); sql.SET("goods_type = #{record.goodsType,jdbcType=INTEGER}");
} }
if (record.getSource() != null) {
sql.SET("`source` = #{record.source,jdbcType=INTEGER}");
}
if (record.getUserId() != null) { if (record.getUserId() != null) {
sql.SET("user_id = #{record.userId,jdbcType=BIGINT}"); sql.SET("user_id = #{record.userId,jdbcType=BIGINT}");
} }
@ -241,6 +250,7 @@ public class GoodsShoppingCartSqlProvider {
sql.SET("id = #{record.id,jdbcType=BIGINT}"); sql.SET("id = #{record.id,jdbcType=BIGINT}");
sql.SET("goods_id = #{record.goodsId,jdbcType=BIGINT}"); sql.SET("goods_id = #{record.goodsId,jdbcType=BIGINT}");
sql.SET("goods_type = #{record.goodsType,jdbcType=INTEGER}"); sql.SET("goods_type = #{record.goodsType,jdbcType=INTEGER}");
sql.SET("`source` = #{record.source,jdbcType=INTEGER}");
sql.SET("user_id = #{record.userId,jdbcType=BIGINT}"); sql.SET("user_id = #{record.userId,jdbcType=BIGINT}");
sql.SET("title = #{record.title,jdbcType=VARCHAR}"); sql.SET("title = #{record.title,jdbcType=VARCHAR}");
sql.SET("img = #{record.img,jdbcType=VARCHAR}"); sql.SET("img = #{record.img,jdbcType=VARCHAR}");
@ -276,6 +286,10 @@ public class GoodsShoppingCartSqlProvider {
sql.SET("goods_type = #{goodsType,jdbcType=INTEGER}"); sql.SET("goods_type = #{goodsType,jdbcType=INTEGER}");
} }
if (record.getSource() != null) {
sql.SET("`source` = #{source,jdbcType=INTEGER}");
}
if (record.getUserId() != null) { if (record.getUserId() != null) {
sql.SET("user_id = #{userId,jdbcType=BIGINT}"); sql.SET("user_id = #{userId,jdbcType=BIGINT}");
} }

@ -29,6 +29,11 @@ public class GoodsShoppingCart implements Serializable {
*/ */
private Integer goodsType; private Integer goodsType;
/**
* 产品来源1.内部虚拟商品 2: 娱尚会员充值 4.贵州中石化 5.重庆中石油 6.比邻星停车券 7.四川中石油 10.中油优途中石油
*/
private Integer source;
/** /**
* 用户编号 * 用户编号
*/ */
@ -140,6 +145,14 @@ public class GoodsShoppingCart implements Serializable {
this.goodsType = goodsType; this.goodsType = goodsType;
} }
public Integer getSource() {
return source;
}
public void setSource(Integer source) {
this.source = source;
}
public Long getUserId() { public Long getUserId() {
return userId; return userId;
} }
@ -291,6 +304,7 @@ public class GoodsShoppingCart implements Serializable {
return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId())) return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
&& (this.getGoodsId() == null ? other.getGoodsId() == null : this.getGoodsId().equals(other.getGoodsId())) && (this.getGoodsId() == null ? other.getGoodsId() == null : this.getGoodsId().equals(other.getGoodsId()))
&& (this.getGoodsType() == null ? other.getGoodsType() == null : this.getGoodsType().equals(other.getGoodsType())) && (this.getGoodsType() == null ? other.getGoodsType() == null : this.getGoodsType().equals(other.getGoodsType()))
&& (this.getSource() == null ? other.getSource() == null : this.getSource().equals(other.getSource()))
&& (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId())) && (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
&& (this.getTitle() == null ? other.getTitle() == null : this.getTitle().equals(other.getTitle())) && (this.getTitle() == null ? other.getTitle() == null : this.getTitle().equals(other.getTitle()))
&& (this.getImg() == null ? other.getImg() == null : this.getImg().equals(other.getImg())) && (this.getImg() == null ? other.getImg() == null : this.getImg().equals(other.getImg()))
@ -317,6 +331,7 @@ public class GoodsShoppingCart implements Serializable {
result = prime * result + ((getId() == null) ? 0 : getId().hashCode()); result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
result = prime * result + ((getGoodsId() == null) ? 0 : getGoodsId().hashCode()); result = prime * result + ((getGoodsId() == null) ? 0 : getGoodsId().hashCode());
result = prime * result + ((getGoodsType() == null) ? 0 : getGoodsType().hashCode()); result = prime * result + ((getGoodsType() == null) ? 0 : getGoodsType().hashCode());
result = prime * result + ((getSource() == null) ? 0 : getSource().hashCode());
result = prime * result + ((getUserId() == null) ? 0 : getUserId().hashCode()); result = prime * result + ((getUserId() == null) ? 0 : getUserId().hashCode());
result = prime * result + ((getTitle() == null) ? 0 : getTitle().hashCode()); result = prime * result + ((getTitle() == null) ? 0 : getTitle().hashCode());
result = prime * result + ((getImg() == null) ? 0 : getImg().hashCode()); result = prime * result + ((getImg() == null) ? 0 : getImg().hashCode());
@ -346,6 +361,7 @@ public class GoodsShoppingCart implements Serializable {
sb.append(", id=").append(id); sb.append(", id=").append(id);
sb.append(", goodsId=").append(goodsId); sb.append(", goodsId=").append(goodsId);
sb.append(", goodsType=").append(goodsType); sb.append(", goodsType=").append(goodsType);
sb.append(", source=").append(source);
sb.append(", userId=").append(userId); sb.append(", userId=").append(userId);
sb.append(", title=").append(title); sb.append(", title=").append(title);
sb.append(", img=").append(img); sb.append(", img=").append(img);

@ -306,6 +306,66 @@ public class GoodsShoppingCartExample {
return (Criteria) this; return (Criteria) this;
} }
public Criteria andSourceIsNull() {
addCriterion("`source` is null");
return (Criteria) this;
}
public Criteria andSourceIsNotNull() {
addCriterion("`source` is not null");
return (Criteria) this;
}
public Criteria andSourceEqualTo(Integer value) {
addCriterion("`source` =", value, "source");
return (Criteria) this;
}
public Criteria andSourceNotEqualTo(Integer value) {
addCriterion("`source` <>", value, "source");
return (Criteria) this;
}
public Criteria andSourceGreaterThan(Integer value) {
addCriterion("`source` >", value, "source");
return (Criteria) this;
}
public Criteria andSourceGreaterThanOrEqualTo(Integer value) {
addCriterion("`source` >=", value, "source");
return (Criteria) this;
}
public Criteria andSourceLessThan(Integer value) {
addCriterion("`source` <", value, "source");
return (Criteria) this;
}
public Criteria andSourceLessThanOrEqualTo(Integer value) {
addCriterion("`source` <=", value, "source");
return (Criteria) this;
}
public Criteria andSourceIn(List<Integer> values) {
addCriterion("`source` in", values, "source");
return (Criteria) this;
}
public Criteria andSourceNotIn(List<Integer> values) {
addCriterion("`source` not in", values, "source");
return (Criteria) this;
}
public Criteria andSourceBetween(Integer value1, Integer value2) {
addCriterion("`source` between", value1, value2, "source");
return (Criteria) this;
}
public Criteria andSourceNotBetween(Integer value1, Integer value2) {
addCriterion("`source` not between", value1, value2, "source");
return (Criteria) this;
}
public Criteria andUserIdIsNull() { public Criteria andUserIdIsNull() {
addCriterion("user_id is null"); addCriterion("user_id is null");
return (Criteria) this; return (Criteria) this;

Loading…
Cancel
Save