袁野 2 months ago
parent d3cb68360f
commit 7ad605cc3e
  1. 31
      service/src/main/java/com/hfkj/dao/BsOrderMapper.java
  2. 14
      service/src/main/java/com/hfkj/dao/BsOrderSqlProvider.java
  3. 16
      service/src/main/java/com/hfkj/entity/BsOrder.java
  4. 60
      service/src/main/java/com/hfkj/entity/BsOrderExample.java

@ -42,21 +42,23 @@ public interface BsOrderMapper extends BsOrderMapperExt {
"insert into bs_order (order_no, user_id, ", "insert into bs_order (order_no, user_id, ",
"user_phone, img, ", "user_phone, img, ",
"goods_name, customParameters, ", "goods_name, customParameters, ",
"goods_count, total_price, ", "goods_count, `type`, ",
"promotionAmount, `status`, ", "total_price, promotionAmount, ",
"create_time, pay_time, ", "`status`, create_time, ",
"cancel_time, refund_time, ", "pay_time, cancel_time, ",
"finish_time, update_time, ", "refund_time, finish_time, ",
"ext_1, ext_2, ext_3)", "update_time, ext_1, ",
"ext_2, ext_3)",
"values (#{orderNo,jdbcType=VARCHAR}, #{userId,jdbcType=BIGINT}, ", "values (#{orderNo,jdbcType=VARCHAR}, #{userId,jdbcType=BIGINT}, ",
"#{userPhone,jdbcType=VARCHAR}, #{img,jdbcType=VARCHAR}, ", "#{userPhone,jdbcType=VARCHAR}, #{img,jdbcType=VARCHAR}, ",
"#{goodsName,jdbcType=VARCHAR}, #{customparameters,jdbcType=VARCHAR}, ", "#{goodsName,jdbcType=VARCHAR}, #{customparameters,jdbcType=VARCHAR}, ",
"#{goodsCount,jdbcType=INTEGER}, #{totalPrice,jdbcType=DECIMAL}, ", "#{goodsCount,jdbcType=INTEGER}, #{type,jdbcType=INTEGER}, ",
"#{promotionamount,jdbcType=DECIMAL}, #{status,jdbcType=INTEGER}, ", "#{totalPrice,jdbcType=DECIMAL}, #{promotionamount,jdbcType=DECIMAL}, ",
"#{createTime,jdbcType=TIMESTAMP}, #{payTime,jdbcType=TIMESTAMP}, ", "#{status,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}, ",
"#{cancelTime,jdbcType=TIMESTAMP}, #{refundTime,jdbcType=TIMESTAMP}, ", "#{payTime,jdbcType=TIMESTAMP}, #{cancelTime,jdbcType=TIMESTAMP}, ",
"#{finishTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, ", "#{refundTime,jdbcType=TIMESTAMP}, #{finishTime,jdbcType=TIMESTAMP}, ",
"#{ext1,jdbcType=VARCHAR}, #{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" "#{updateTime,jdbcType=TIMESTAMP}, #{ext1,jdbcType=VARCHAR}, ",
"#{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})"
}) })
@Options(useGeneratedKeys=true,keyProperty="id") @Options(useGeneratedKeys=true,keyProperty="id")
int insert(BsOrder record); int insert(BsOrder record);
@ -75,6 +77,7 @@ public interface BsOrderMapper extends BsOrderMapperExt {
@Result(column="goods_name", property="goodsName", jdbcType=JdbcType.VARCHAR), @Result(column="goods_name", property="goodsName", jdbcType=JdbcType.VARCHAR),
@Result(column="customParameters", property="customparameters", jdbcType=JdbcType.VARCHAR), @Result(column="customParameters", property="customparameters", jdbcType=JdbcType.VARCHAR),
@Result(column="goods_count", property="goodsCount", jdbcType=JdbcType.INTEGER), @Result(column="goods_count", property="goodsCount", jdbcType=JdbcType.INTEGER),
@Result(column="type", property="type", jdbcType=JdbcType.INTEGER),
@Result(column="total_price", property="totalPrice", jdbcType=JdbcType.DECIMAL), @Result(column="total_price", property="totalPrice", jdbcType=JdbcType.DECIMAL),
@Result(column="promotionAmount", property="promotionamount", jdbcType=JdbcType.DECIMAL), @Result(column="promotionAmount", property="promotionamount", jdbcType=JdbcType.DECIMAL),
@Result(column="status", property="status", jdbcType=JdbcType.INTEGER), @Result(column="status", property="status", jdbcType=JdbcType.INTEGER),
@ -93,7 +96,7 @@ public interface BsOrderMapper extends BsOrderMapperExt {
@Select({ @Select({
"select", "select",
"id, order_no, user_id, user_phone, img, goods_name, customParameters, goods_count, ", "id, order_no, user_id, user_phone, img, goods_name, customParameters, goods_count, ",
"total_price, promotionAmount, `status`, create_time, pay_time, cancel_time, ", "`type`, total_price, promotionAmount, `status`, create_time, pay_time, cancel_time, ",
"refund_time, finish_time, update_time, ext_1, ext_2, ext_3", "refund_time, finish_time, update_time, ext_1, ext_2, ext_3",
"from bs_order", "from bs_order",
"where id = #{id,jdbcType=BIGINT}" "where id = #{id,jdbcType=BIGINT}"
@ -107,6 +110,7 @@ public interface BsOrderMapper extends BsOrderMapperExt {
@Result(column="goods_name", property="goodsName", jdbcType=JdbcType.VARCHAR), @Result(column="goods_name", property="goodsName", jdbcType=JdbcType.VARCHAR),
@Result(column="customParameters", property="customparameters", jdbcType=JdbcType.VARCHAR), @Result(column="customParameters", property="customparameters", jdbcType=JdbcType.VARCHAR),
@Result(column="goods_count", property="goodsCount", jdbcType=JdbcType.INTEGER), @Result(column="goods_count", property="goodsCount", jdbcType=JdbcType.INTEGER),
@Result(column="type", property="type", jdbcType=JdbcType.INTEGER),
@Result(column="total_price", property="totalPrice", jdbcType=JdbcType.DECIMAL), @Result(column="total_price", property="totalPrice", jdbcType=JdbcType.DECIMAL),
@Result(column="promotionAmount", property="promotionamount", jdbcType=JdbcType.DECIMAL), @Result(column="promotionAmount", property="promotionamount", jdbcType=JdbcType.DECIMAL),
@Result(column="status", property="status", jdbcType=JdbcType.INTEGER), @Result(column="status", property="status", jdbcType=JdbcType.INTEGER),
@ -140,6 +144,7 @@ public interface BsOrderMapper extends BsOrderMapperExt {
"goods_name = #{goodsName,jdbcType=VARCHAR},", "goods_name = #{goodsName,jdbcType=VARCHAR},",
"customParameters = #{customparameters,jdbcType=VARCHAR},", "customParameters = #{customparameters,jdbcType=VARCHAR},",
"goods_count = #{goodsCount,jdbcType=INTEGER},", "goods_count = #{goodsCount,jdbcType=INTEGER},",
"`type` = #{type,jdbcType=INTEGER},",
"total_price = #{totalPrice,jdbcType=DECIMAL},", "total_price = #{totalPrice,jdbcType=DECIMAL},",
"promotionAmount = #{promotionamount,jdbcType=DECIMAL},", "promotionAmount = #{promotionamount,jdbcType=DECIMAL},",
"`status` = #{status,jdbcType=INTEGER},", "`status` = #{status,jdbcType=INTEGER},",

@ -56,6 +56,10 @@ public class BsOrderSqlProvider {
sql.VALUES("goods_count", "#{goodsCount,jdbcType=INTEGER}"); sql.VALUES("goods_count", "#{goodsCount,jdbcType=INTEGER}");
} }
if (record.getType() != null) {
sql.VALUES("`type`", "#{type,jdbcType=INTEGER}");
}
if (record.getTotalPrice() != null) { if (record.getTotalPrice() != null) {
sql.VALUES("total_price", "#{totalPrice,jdbcType=DECIMAL}"); sql.VALUES("total_price", "#{totalPrice,jdbcType=DECIMAL}");
} }
@ -121,6 +125,7 @@ public class BsOrderSqlProvider {
sql.SELECT("goods_name"); sql.SELECT("goods_name");
sql.SELECT("customParameters"); sql.SELECT("customParameters");
sql.SELECT("goods_count"); sql.SELECT("goods_count");
sql.SELECT("`type`");
sql.SELECT("total_price"); sql.SELECT("total_price");
sql.SELECT("promotionAmount"); sql.SELECT("promotionAmount");
sql.SELECT("`status`"); sql.SELECT("`status`");
@ -182,6 +187,10 @@ public class BsOrderSqlProvider {
sql.SET("goods_count = #{record.goodsCount,jdbcType=INTEGER}"); sql.SET("goods_count = #{record.goodsCount,jdbcType=INTEGER}");
} }
if (record.getType() != null) {
sql.SET("`type` = #{record.type,jdbcType=INTEGER}");
}
if (record.getTotalPrice() != null) { if (record.getTotalPrice() != null) {
sql.SET("total_price = #{record.totalPrice,jdbcType=DECIMAL}"); sql.SET("total_price = #{record.totalPrice,jdbcType=DECIMAL}");
} }
@ -246,6 +255,7 @@ public class BsOrderSqlProvider {
sql.SET("goods_name = #{record.goodsName,jdbcType=VARCHAR}"); sql.SET("goods_name = #{record.goodsName,jdbcType=VARCHAR}");
sql.SET("customParameters = #{record.customparameters,jdbcType=VARCHAR}"); sql.SET("customParameters = #{record.customparameters,jdbcType=VARCHAR}");
sql.SET("goods_count = #{record.goodsCount,jdbcType=INTEGER}"); sql.SET("goods_count = #{record.goodsCount,jdbcType=INTEGER}");
sql.SET("`type` = #{record.type,jdbcType=INTEGER}");
sql.SET("total_price = #{record.totalPrice,jdbcType=DECIMAL}"); sql.SET("total_price = #{record.totalPrice,jdbcType=DECIMAL}");
sql.SET("promotionAmount = #{record.promotionamount,jdbcType=DECIMAL}"); sql.SET("promotionAmount = #{record.promotionamount,jdbcType=DECIMAL}");
sql.SET("`status` = #{record.status,jdbcType=INTEGER}"); sql.SET("`status` = #{record.status,jdbcType=INTEGER}");
@ -296,6 +306,10 @@ public class BsOrderSqlProvider {
sql.SET("goods_count = #{goodsCount,jdbcType=INTEGER}"); sql.SET("goods_count = #{goodsCount,jdbcType=INTEGER}");
} }
if (record.getType() != null) {
sql.SET("`type` = #{type,jdbcType=INTEGER}");
}
if (record.getTotalPrice() != null) { if (record.getTotalPrice() != null) {
sql.SET("total_price = #{totalPrice,jdbcType=DECIMAL}"); sql.SET("total_price = #{totalPrice,jdbcType=DECIMAL}");
} }

@ -54,6 +54,11 @@ public class BsOrder implements Serializable {
*/ */
private Integer goodsCount; private Integer goodsCount;
/**
* 类型 1:淘宝 2:拼多多
*/
private Integer type;
/** /**
* 交易金额 * 交易金额
*/ */
@ -171,6 +176,14 @@ public class BsOrder implements Serializable {
this.goodsCount = goodsCount; this.goodsCount = goodsCount;
} }
public Integer getType() {
return type;
}
public void setType(Integer type) {
this.type = type;
}
public BigDecimal getTotalPrice() { public BigDecimal getTotalPrice() {
return totalPrice; return totalPrice;
} }
@ -287,6 +300,7 @@ public class BsOrder implements Serializable {
&& (this.getGoodsName() == null ? other.getGoodsName() == null : this.getGoodsName().equals(other.getGoodsName())) && (this.getGoodsName() == null ? other.getGoodsName() == null : this.getGoodsName().equals(other.getGoodsName()))
&& (this.getCustomparameters() == null ? other.getCustomparameters() == null : this.getCustomparameters().equals(other.getCustomparameters())) && (this.getCustomparameters() == null ? other.getCustomparameters() == null : this.getCustomparameters().equals(other.getCustomparameters()))
&& (this.getGoodsCount() == null ? other.getGoodsCount() == null : this.getGoodsCount().equals(other.getGoodsCount())) && (this.getGoodsCount() == null ? other.getGoodsCount() == null : this.getGoodsCount().equals(other.getGoodsCount()))
&& (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()))
&& (this.getTotalPrice() == null ? other.getTotalPrice() == null : this.getTotalPrice().equals(other.getTotalPrice())) && (this.getTotalPrice() == null ? other.getTotalPrice() == null : this.getTotalPrice().equals(other.getTotalPrice()))
&& (this.getPromotionamount() == null ? other.getPromotionamount() == null : this.getPromotionamount().equals(other.getPromotionamount())) && (this.getPromotionamount() == null ? other.getPromotionamount() == null : this.getPromotionamount().equals(other.getPromotionamount()))
&& (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus())) && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
@ -313,6 +327,7 @@ public class BsOrder implements Serializable {
result = prime * result + ((getGoodsName() == null) ? 0 : getGoodsName().hashCode()); result = prime * result + ((getGoodsName() == null) ? 0 : getGoodsName().hashCode());
result = prime * result + ((getCustomparameters() == null) ? 0 : getCustomparameters().hashCode()); result = prime * result + ((getCustomparameters() == null) ? 0 : getCustomparameters().hashCode());
result = prime * result + ((getGoodsCount() == null) ? 0 : getGoodsCount().hashCode()); result = prime * result + ((getGoodsCount() == null) ? 0 : getGoodsCount().hashCode());
result = prime * result + ((getType() == null) ? 0 : getType().hashCode());
result = prime * result + ((getTotalPrice() == null) ? 0 : getTotalPrice().hashCode()); result = prime * result + ((getTotalPrice() == null) ? 0 : getTotalPrice().hashCode());
result = prime * result + ((getPromotionamount() == null) ? 0 : getPromotionamount().hashCode()); result = prime * result + ((getPromotionamount() == null) ? 0 : getPromotionamount().hashCode());
result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode()); result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
@ -342,6 +357,7 @@ public class BsOrder implements Serializable {
sb.append(", goodsName=").append(goodsName); sb.append(", goodsName=").append(goodsName);
sb.append(", customparameters=").append(customparameters); sb.append(", customparameters=").append(customparameters);
sb.append(", goodsCount=").append(goodsCount); sb.append(", goodsCount=").append(goodsCount);
sb.append(", type=").append(type);
sb.append(", totalPrice=").append(totalPrice); sb.append(", totalPrice=").append(totalPrice);
sb.append(", promotionamount=").append(promotionamount); sb.append(", promotionamount=").append(promotionamount);
sb.append(", status=").append(status); sb.append(", status=").append(status);

@ -656,6 +656,66 @@ public class BsOrderExample {
return (Criteria) this; return (Criteria) this;
} }
public Criteria andTypeIsNull() {
addCriterion("`type` is null");
return (Criteria) this;
}
public Criteria andTypeIsNotNull() {
addCriterion("`type` is not null");
return (Criteria) this;
}
public Criteria andTypeEqualTo(Integer value) {
addCriterion("`type` =", value, "type");
return (Criteria) this;
}
public Criteria andTypeNotEqualTo(Integer value) {
addCriterion("`type` <>", value, "type");
return (Criteria) this;
}
public Criteria andTypeGreaterThan(Integer value) {
addCriterion("`type` >", value, "type");
return (Criteria) this;
}
public Criteria andTypeGreaterThanOrEqualTo(Integer value) {
addCriterion("`type` >=", value, "type");
return (Criteria) this;
}
public Criteria andTypeLessThan(Integer value) {
addCriterion("`type` <", value, "type");
return (Criteria) this;
}
public Criteria andTypeLessThanOrEqualTo(Integer value) {
addCriterion("`type` <=", value, "type");
return (Criteria) this;
}
public Criteria andTypeIn(List<Integer> values) {
addCriterion("`type` in", values, "type");
return (Criteria) this;
}
public Criteria andTypeNotIn(List<Integer> values) {
addCriterion("`type` not in", values, "type");
return (Criteria) this;
}
public Criteria andTypeBetween(Integer value1, Integer value2) {
addCriterion("`type` between", value1, value2, "type");
return (Criteria) this;
}
public Criteria andTypeNotBetween(Integer value1, Integer value2) {
addCriterion("`type` not between", value1, value2, "type");
return (Criteria) this;
}
public Criteria andTotalPriceIsNull() { public Criteria andTotalPriceIsNull() {
addCriterion("total_price is null"); addCriterion("total_price is null");
return (Criteria) this; return (Criteria) this;

Loading…
Cancel
Save