Пример #1
0
  /**
   * This method was generated by MyBatis Generator. This method corresponds to the database table
   * `trade_move_check`
   *
   * @mbggenerated
   */
  public String insertSelective(TradeMoveCheck record) {
    SQL sql = new SQL();
    sql.INSERT_INTO("`trade_move_check`");

    if (record.getId() != null) {
      sql.VALUES("id", "#{id,jdbcType=INTEGER}");
    }

    if (record.getOrderId() != null) {
      sql.VALUES("order_id", "#{orderId,jdbcType=VARCHAR}");
    }

    if (record.getOrderSn() != null) {
      sql.VALUES("order_sn", "#{orderSn,jdbcType=VARCHAR}");
    }

    if (record.getOrderNo() != null) {
      sql.VALUES("order_no", "#{orderNo,jdbcType=VARCHAR}");
    }

    if (record.getIsMoveSuccess() != null) {
      sql.VALUES("is_move_success", "#{isMoveSuccess,jdbcType=INTEGER}");
    }

    if (record.getIsInInfo() != null) {
      sql.VALUES("is_in_info", "#{isInInfo,jdbcType=INTEGER}");
    }

    if (record.getInfoFlag() != null) {
      sql.VALUES("info_flag", "#{infoFlag,jdbcType=INTEGER}");
    }

    if (record.getInfoDesc() != null) {
      sql.VALUES("info_desc", "#{infoDesc,jdbcType=VARCHAR}");
    }

    if (record.getCreateTime() != null) {
      sql.VALUES("create_time", "#{createTime,jdbcType=TIMESTAMP}");
    }

    if (record.getUpdateTime() != null) {
      sql.VALUES("update_time", "#{updateTime,jdbcType=TIMESTAMP}");
    }

    return sql.toString();
  }
Пример #2
0
  /**
   * This method was generated by MyBatis Generator. This method corresponds to the database table
   * `trade_move_check`
   *
   * @mbggenerated
   */
  public String updateByPrimaryKeySelective(TradeMoveCheck record) {
    SQL sql = new SQL();
    sql.UPDATE("`trade_move_check`");

    if (record.getOrderId() != null) {
      sql.SET("order_id = #{orderId,jdbcType=VARCHAR}");
    }

    if (record.getOrderSn() != null) {
      sql.SET("order_sn = #{orderSn,jdbcType=VARCHAR}");
    }

    if (record.getOrderNo() != null) {
      sql.SET("order_no = #{orderNo,jdbcType=VARCHAR}");
    }

    if (record.getIsMoveSuccess() != null) {
      sql.SET("is_move_success = #{isMoveSuccess,jdbcType=INTEGER}");
    }

    if (record.getIsInInfo() != null) {
      sql.SET("is_in_info = #{isInInfo,jdbcType=INTEGER}");
    }

    if (record.getInfoFlag() != null) {
      sql.SET("info_flag = #{infoFlag,jdbcType=INTEGER}");
    }

    if (record.getInfoDesc() != null) {
      sql.SET("info_desc = #{infoDesc,jdbcType=VARCHAR}");
    }

    if (record.getCreateTime() != null) {
      sql.SET("create_time = #{createTime,jdbcType=TIMESTAMP}");
    }

    if (record.getUpdateTime() != null) {
      sql.SET("update_time = #{updateTime,jdbcType=TIMESTAMP}");
    }

    sql.WHERE("id = #{id,jdbcType=INTEGER}");

    return sql.toString();
  }
Пример #3
0
  /**
   * This method was generated by MyBatis Generator. This method corresponds to the database table
   * `trade_move_check`
   *
   * @mbggenerated
   */
  public String updateByExampleSelective(Map<String, Object> parameter) {
    TradeMoveCheck record = (TradeMoveCheck) parameter.get("record");
    TradeMoveCheckExample example = (TradeMoveCheckExample) parameter.get("example");

    SQL sql = new SQL();
    sql.UPDATE("`trade_move_check`");

    if (record.getId() != null) {
      sql.SET("id = #{record.id,jdbcType=INTEGER}");
    }

    if (record.getOrderId() != null) {
      sql.SET("order_id = #{record.orderId,jdbcType=VARCHAR}");
    }

    if (record.getOrderSn() != null) {
      sql.SET("order_sn = #{record.orderSn,jdbcType=VARCHAR}");
    }

    if (record.getOrderNo() != null) {
      sql.SET("order_no = #{record.orderNo,jdbcType=VARCHAR}");
    }

    if (record.getIsMoveSuccess() != null) {
      sql.SET("is_move_success = #{record.isMoveSuccess,jdbcType=INTEGER}");
    }

    if (record.getIsInInfo() != null) {
      sql.SET("is_in_info = #{record.isInInfo,jdbcType=INTEGER}");
    }

    if (record.getInfoFlag() != null) {
      sql.SET("info_flag = #{record.infoFlag,jdbcType=INTEGER}");
    }

    if (record.getInfoDesc() != null) {
      sql.SET("info_desc = #{record.infoDesc,jdbcType=VARCHAR}");
    }

    if (record.getCreateTime() != null) {
      sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}");
    }

    if (record.getUpdateTime() != null) {
      sql.SET("update_time = #{record.updateTime,jdbcType=TIMESTAMP}");
    }

    applyWhere(sql, example, true);
    return sql.toString();
  }