anderx лет назад: 7
Родитель
Сommit
b75b7b5eed

+ 1 - 1
GeneratorConfig.xml

@@ -9,6 +9,6 @@
     <javaModelGenerator targetPackage="com.goafanti.common.model" targetProject="aft" />
     <sqlMapGenerator targetPackage="com.goafanti.common.mapper" targetProject="aft" />
     <javaClientGenerator targetPackage="com.goafanti.common.dao" targetProject="aft" type="XMLMAPPER" />
-    <table schema="aft" tableName="t_dun_log"/> 
+    <table schema="aft" tableName="t_order_refund"/> 
   </context>
 </generatorConfiguration>

+ 96 - 0
src/main/java/com/goafanti/common/dao/TOrderRefundMapper.java

@@ -0,0 +1,96 @@
+package com.goafanti.common.dao;
+
+import com.goafanti.common.model.TOrderRefund;
+import com.goafanti.common.model.TOrderRefundExample;
+import com.goafanti.common.model.TOrderRefundWithBLOBs;
+import java.util.List;
+import org.apache.ibatis.annotations.Param;
+
+public interface TOrderRefundMapper {
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	long countByExample(TOrderRefundExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	int deleteByExample(TOrderRefundExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	int deleteByPrimaryKey(Integer id);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	int insert(TOrderRefundWithBLOBs record);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	int insertSelective(TOrderRefundWithBLOBs record);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	List<TOrderRefundWithBLOBs> selectByExampleWithBLOBs(TOrderRefundExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	List<TOrderRefund> selectByExample(TOrderRefundExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	TOrderRefundWithBLOBs selectByPrimaryKey(Integer id);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	int updateByExampleSelective(@Param("record") TOrderRefundWithBLOBs record,
+			@Param("example") TOrderRefundExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	int updateByExampleWithBLOBs(@Param("record") TOrderRefundWithBLOBs record,
+			@Param("example") TOrderRefundExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	int updateByExample(@Param("record") TOrderRefund record, @Param("example") TOrderRefundExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	int updateByPrimaryKeySelective(TOrderRefundWithBLOBs record);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	int updateByPrimaryKeyWithBLOBs(TOrderRefundWithBLOBs record);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	int updateByPrimaryKey(TOrderRefund record);
+}

+ 453 - 0
src/main/java/com/goafanti/common/mapper/TOrderRefundMapper.xml

@@ -0,0 +1,453 @@
+<?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.goafanti.common.dao.TOrderRefundMapper">
+  <resultMap id="BaseResultMap" type="com.goafanti.common.model.TOrderRefund">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    <id column="id" jdbcType="INTEGER" property="id" />
+    <result column="order_no" jdbcType="VARCHAR" property="orderNo" />
+    <result column="refund_status" jdbcType="INTEGER" property="refundStatus" />
+    <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
+    <result column="initiate" jdbcType="VARCHAR" property="initiate" />
+    <result column="accept" jdbcType="VARCHAR" property="accept" />
+    <result column="reason" jdbcType="VARCHAR" property="reason" />
+    <result column="result" jdbcType="VARCHAR" property="result" />
+  </resultMap>
+  <resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.goafanti.common.model.TOrderRefundWithBLOBs">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    <result column="reason_attachment_url" jdbcType="LONGVARCHAR" property="reasonAttachmentUrl" />
+    <result column="contract_url" jdbcType="LONGVARCHAR" property="contractUrl" />
+    <result column="application_url" jdbcType="LONGVARCHAR" property="applicationUrl" />
+  </resultMap>
+  <sql id="Example_Where_Clause">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    <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">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    <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">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    id, order_no, refund_status, create_time, initiate, accept, reason, result
+  </sql>
+  <sql id="Blob_Column_List">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    reason_attachment_url, contract_url, application_url
+  </sql>
+  <select id="selectByExampleWithBLOBs" parameterType="com.goafanti.common.model.TOrderRefundExample" resultMap="ResultMapWithBLOBs">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    ,
+    <include refid="Blob_Column_List" />
+    from t_order_refund
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+  </select>
+  <select id="selectByExample" parameterType="com.goafanti.common.model.TOrderRefundExample" resultMap="BaseResultMap">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from t_order_refund
+    <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.Integer" resultMap="ResultMapWithBLOBs">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    select 
+    <include refid="Base_Column_List" />
+    ,
+    <include refid="Blob_Column_List" />
+    from t_order_refund
+    where id = #{id,jdbcType=INTEGER}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    delete from t_order_refund
+    where id = #{id,jdbcType=INTEGER}
+  </delete>
+  <delete id="deleteByExample" parameterType="com.goafanti.common.model.TOrderRefundExample">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    delete from t_order_refund
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.goafanti.common.model.TOrderRefundWithBLOBs">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    insert into t_order_refund (id, order_no, refund_status, 
+      create_time, initiate, accept, 
+      reason, result, reason_attachment_url, 
+      contract_url, application_url)
+    values (#{id,jdbcType=INTEGER}, #{orderNo,jdbcType=VARCHAR}, #{refundStatus,jdbcType=INTEGER}, 
+      #{createTime,jdbcType=TIMESTAMP}, #{initiate,jdbcType=VARCHAR}, #{accept,jdbcType=VARCHAR}, 
+      #{reason,jdbcType=VARCHAR}, #{result,jdbcType=VARCHAR}, #{reasonAttachmentUrl,jdbcType=LONGVARCHAR}, 
+      #{contractUrl,jdbcType=LONGVARCHAR}, #{applicationUrl,jdbcType=LONGVARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.goafanti.common.model.TOrderRefundWithBLOBs">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    insert into t_order_refund
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        id,
+      </if>
+      <if test="orderNo != null">
+        order_no,
+      </if>
+      <if test="refundStatus != null">
+        refund_status,
+      </if>
+      <if test="createTime != null">
+        create_time,
+      </if>
+      <if test="initiate != null">
+        initiate,
+      </if>
+      <if test="accept != null">
+        accept,
+      </if>
+      <if test="reason != null">
+        reason,
+      </if>
+      <if test="result != null">
+        result,
+      </if>
+      <if test="reasonAttachmentUrl != null">
+        reason_attachment_url,
+      </if>
+      <if test="contractUrl != null">
+        contract_url,
+      </if>
+      <if test="applicationUrl != null">
+        application_url,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=INTEGER},
+      </if>
+      <if test="orderNo != null">
+        #{orderNo,jdbcType=VARCHAR},
+      </if>
+      <if test="refundStatus != null">
+        #{refundStatus,jdbcType=INTEGER},
+      </if>
+      <if test="createTime != null">
+        #{createTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="initiate != null">
+        #{initiate,jdbcType=VARCHAR},
+      </if>
+      <if test="accept != null">
+        #{accept,jdbcType=VARCHAR},
+      </if>
+      <if test="reason != null">
+        #{reason,jdbcType=VARCHAR},
+      </if>
+      <if test="result != null">
+        #{result,jdbcType=VARCHAR},
+      </if>
+      <if test="reasonAttachmentUrl != null">
+        #{reasonAttachmentUrl,jdbcType=LONGVARCHAR},
+      </if>
+      <if test="contractUrl != null">
+        #{contractUrl,jdbcType=LONGVARCHAR},
+      </if>
+      <if test="applicationUrl != null">
+        #{applicationUrl,jdbcType=LONGVARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.goafanti.common.model.TOrderRefundExample" resultType="java.lang.Long">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    select count(*) from t_order_refund
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </select>
+  <update id="updateByExampleSelective" parameterType="map">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    update t_order_refund
+    <set>
+      <if test="record.id != null">
+        id = #{record.id,jdbcType=INTEGER},
+      </if>
+      <if test="record.orderNo != null">
+        order_no = #{record.orderNo,jdbcType=VARCHAR},
+      </if>
+      <if test="record.refundStatus != null">
+        refund_status = #{record.refundStatus,jdbcType=INTEGER},
+      </if>
+      <if test="record.createTime != null">
+        create_time = #{record.createTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="record.initiate != null">
+        initiate = #{record.initiate,jdbcType=VARCHAR},
+      </if>
+      <if test="record.accept != null">
+        accept = #{record.accept,jdbcType=VARCHAR},
+      </if>
+      <if test="record.reason != null">
+        reason = #{record.reason,jdbcType=VARCHAR},
+      </if>
+      <if test="record.result != null">
+        result = #{record.result,jdbcType=VARCHAR},
+      </if>
+      <if test="record.reasonAttachmentUrl != null">
+        reason_attachment_url = #{record.reasonAttachmentUrl,jdbcType=LONGVARCHAR},
+      </if>
+      <if test="record.contractUrl != null">
+        contract_url = #{record.contractUrl,jdbcType=LONGVARCHAR},
+      </if>
+      <if test="record.applicationUrl != null">
+        application_url = #{record.applicationUrl,jdbcType=LONGVARCHAR},
+      </if>
+    </set>
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExampleWithBLOBs" parameterType="map">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    update t_order_refund
+    set id = #{record.id,jdbcType=INTEGER},
+      order_no = #{record.orderNo,jdbcType=VARCHAR},
+      refund_status = #{record.refundStatus,jdbcType=INTEGER},
+      create_time = #{record.createTime,jdbcType=TIMESTAMP},
+      initiate = #{record.initiate,jdbcType=VARCHAR},
+      accept = #{record.accept,jdbcType=VARCHAR},
+      reason = #{record.reason,jdbcType=VARCHAR},
+      result = #{record.result,jdbcType=VARCHAR},
+      reason_attachment_url = #{record.reasonAttachmentUrl,jdbcType=LONGVARCHAR},
+      contract_url = #{record.contractUrl,jdbcType=LONGVARCHAR},
+      application_url = #{record.applicationUrl,jdbcType=LONGVARCHAR}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExample" parameterType="map">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    update t_order_refund
+    set id = #{record.id,jdbcType=INTEGER},
+      order_no = #{record.orderNo,jdbcType=VARCHAR},
+      refund_status = #{record.refundStatus,jdbcType=INTEGER},
+      create_time = #{record.createTime,jdbcType=TIMESTAMP},
+      initiate = #{record.initiate,jdbcType=VARCHAR},
+      accept = #{record.accept,jdbcType=VARCHAR},
+      reason = #{record.reason,jdbcType=VARCHAR},
+      result = #{record.result,jdbcType=VARCHAR}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.TOrderRefundWithBLOBs">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    update t_order_refund
+    <set>
+      <if test="orderNo != null">
+        order_no = #{orderNo,jdbcType=VARCHAR},
+      </if>
+      <if test="refundStatus != null">
+        refund_status = #{refundStatus,jdbcType=INTEGER},
+      </if>
+      <if test="createTime != null">
+        create_time = #{createTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="initiate != null">
+        initiate = #{initiate,jdbcType=VARCHAR},
+      </if>
+      <if test="accept != null">
+        accept = #{accept,jdbcType=VARCHAR},
+      </if>
+      <if test="reason != null">
+        reason = #{reason,jdbcType=VARCHAR},
+      </if>
+      <if test="result != null">
+        result = #{result,jdbcType=VARCHAR},
+      </if>
+      <if test="reasonAttachmentUrl != null">
+        reason_attachment_url = #{reasonAttachmentUrl,jdbcType=LONGVARCHAR},
+      </if>
+      <if test="contractUrl != null">
+        contract_url = #{contractUrl,jdbcType=LONGVARCHAR},
+      </if>
+      <if test="applicationUrl != null">
+        application_url = #{applicationUrl,jdbcType=LONGVARCHAR},
+      </if>
+    </set>
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+  <update id="updateByPrimaryKeyWithBLOBs" parameterType="com.goafanti.common.model.TOrderRefundWithBLOBs">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    update t_order_refund
+    set order_no = #{orderNo,jdbcType=VARCHAR},
+      refund_status = #{refundStatus,jdbcType=INTEGER},
+      create_time = #{createTime,jdbcType=TIMESTAMP},
+      initiate = #{initiate,jdbcType=VARCHAR},
+      accept = #{accept,jdbcType=VARCHAR},
+      reason = #{reason,jdbcType=VARCHAR},
+      result = #{result,jdbcType=VARCHAR},
+      reason_attachment_url = #{reasonAttachmentUrl,jdbcType=LONGVARCHAR},
+      contract_url = #{contractUrl,jdbcType=LONGVARCHAR},
+      application_url = #{applicationUrl,jdbcType=LONGVARCHAR}
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="com.goafanti.common.model.TOrderRefund">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Tue Nov 20 15:20:39 CST 2018.
+    -->
+    update t_order_refund
+    set order_no = #{orderNo,jdbcType=VARCHAR},
+      refund_status = #{refundStatus,jdbcType=INTEGER},
+      create_time = #{createTime,jdbcType=TIMESTAMP},
+      initiate = #{initiate,jdbcType=VARCHAR},
+      accept = #{accept,jdbcType=VARCHAR},
+      reason = #{reason,jdbcType=VARCHAR},
+      result = #{result,jdbcType=VARCHAR}
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+</mapper>

+ 194 - 0
src/main/java/com/goafanti/common/model/TOrderRefund.java

@@ -0,0 +1,194 @@
+package com.goafanti.common.model;
+
+import java.util.Date;
+
+public class TOrderRefund {
+
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.id
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private Integer id;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.order_no
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private String orderNo;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.refund_status
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private Integer refundStatus;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.create_time
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private Date createTime;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.initiate
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private String initiate;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.accept
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private String accept;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.reason
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private String reason;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.result
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private String result;
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.id
+	 * @return  the value of t_order_refund.id
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	
+	public Integer getId() {
+		return id;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.id
+	 * @param id  the value for t_order_refund.id
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setId(Integer id) {
+		this.id = id;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.order_no
+	 * @return  the value of t_order_refund.order_no
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public String getOrderNo() {
+		return orderNo;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.order_no
+	 * @param orderNo  the value for t_order_refund.order_no
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setOrderNo(String orderNo) {
+		this.orderNo = orderNo;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.refund_status
+	 * @return  the value of t_order_refund.refund_status
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public Integer getRefundStatus() {
+		return refundStatus;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.refund_status
+	 * @param refundStatus  the value for t_order_refund.refund_status
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setRefundStatus(Integer refundStatus) {
+		this.refundStatus = refundStatus;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.create_time
+	 * @return  the value of t_order_refund.create_time
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public Date getCreateTime() {
+		return createTime;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.create_time
+	 * @param createTime  the value for t_order_refund.create_time
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setCreateTime(Date createTime) {
+		this.createTime = createTime;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.initiate
+	 * @return  the value of t_order_refund.initiate
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public String getInitiate() {
+		return initiate;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.initiate
+	 * @param initiate  the value for t_order_refund.initiate
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setInitiate(String initiate) {
+		this.initiate = initiate;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.accept
+	 * @return  the value of t_order_refund.accept
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public String getAccept() {
+		return accept;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.accept
+	 * @param accept  the value for t_order_refund.accept
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setAccept(String accept) {
+		this.accept = accept;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.reason
+	 * @return  the value of t_order_refund.reason
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public String getReason() {
+		return reason;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.reason
+	 * @param reason  the value for t_order_refund.reason
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setReason(String reason) {
+		this.reason = reason;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.result
+	 * @return  the value of t_order_refund.result
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public String getResult() {
+		return result;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.result
+	 * @param result  the value for t_order_refund.result
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setResult(String result) {
+		this.result = result;
+	}
+
+	
+}

+ 792 - 0
src/main/java/com/goafanti/common/model/TOrderRefundExample.java

@@ -0,0 +1,792 @@
+package com.goafanti.common.model;
+
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+public class TOrderRefundExample {
+    /**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	protected String orderByClause;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	protected boolean distinct;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	protected List<Criteria> oredCriteria;
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public TOrderRefundExample() {
+		oredCriteria = new ArrayList<Criteria>();
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setOrderByClause(String orderByClause) {
+		this.orderByClause = orderByClause;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public String getOrderByClause() {
+		return orderByClause;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setDistinct(boolean distinct) {
+		this.distinct = distinct;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public boolean isDistinct() {
+		return distinct;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public List<Criteria> getOredCriteria() {
+		return oredCriteria;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void or(Criteria criteria) {
+		oredCriteria.add(criteria);
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public Criteria or() {
+		Criteria criteria = createCriteriaInternal();
+		oredCriteria.add(criteria);
+		return criteria;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public Criteria createCriteria() {
+		Criteria criteria = createCriteriaInternal();
+		if (oredCriteria.size() == 0) {
+			oredCriteria.add(criteria);
+		}
+		return criteria;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	protected Criteria createCriteriaInternal() {
+		Criteria criteria = new Criteria();
+		return criteria;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void clear() {
+		oredCriteria.clear();
+		orderByClause = null;
+		distinct = false;
+	}
+
+	/**
+	 * This class was generated by MyBatis Generator. This class corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	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(Integer value) {
+			addCriterion("id =", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdNotEqualTo(Integer value) {
+			addCriterion("id <>", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdGreaterThan(Integer value) {
+			addCriterion("id >", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdGreaterThanOrEqualTo(Integer value) {
+			addCriterion("id >=", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdLessThan(Integer value) {
+			addCriterion("id <", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdLessThanOrEqualTo(Integer value) {
+			addCriterion("id <=", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdIn(List<Integer> values) {
+			addCriterion("id in", values, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdNotIn(List<Integer> values) {
+			addCriterion("id not in", values, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdBetween(Integer value1, Integer value2) {
+			addCriterion("id between", value1, value2, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdNotBetween(Integer value1, Integer value2) {
+			addCriterion("id not between", value1, value2, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoIsNull() {
+			addCriterion("order_no is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoIsNotNull() {
+			addCriterion("order_no is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoEqualTo(String value) {
+			addCriterion("order_no =", value, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoNotEqualTo(String value) {
+			addCriterion("order_no <>", value, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoGreaterThan(String value) {
+			addCriterion("order_no >", value, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoGreaterThanOrEqualTo(String value) {
+			addCriterion("order_no >=", value, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoLessThan(String value) {
+			addCriterion("order_no <", value, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoLessThanOrEqualTo(String value) {
+			addCriterion("order_no <=", value, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoLike(String value) {
+			addCriterion("order_no like", value, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoNotLike(String value) {
+			addCriterion("order_no not like", value, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoIn(List<String> values) {
+			addCriterion("order_no in", values, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoNotIn(List<String> values) {
+			addCriterion("order_no not in", values, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoBetween(String value1, String value2) {
+			addCriterion("order_no between", value1, value2, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andOrderNoNotBetween(String value1, String value2) {
+			addCriterion("order_no not between", value1, value2, "orderNo");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusIsNull() {
+			addCriterion("refund_status is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusIsNotNull() {
+			addCriterion("refund_status is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusEqualTo(Integer value) {
+			addCriterion("refund_status =", value, "refundStatus");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusNotEqualTo(Integer value) {
+			addCriterion("refund_status <>", value, "refundStatus");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusGreaterThan(Integer value) {
+			addCriterion("refund_status >", value, "refundStatus");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusGreaterThanOrEqualTo(Integer value) {
+			addCriterion("refund_status >=", value, "refundStatus");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusLessThan(Integer value) {
+			addCriterion("refund_status <", value, "refundStatus");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusLessThanOrEqualTo(Integer value) {
+			addCriterion("refund_status <=", value, "refundStatus");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusIn(List<Integer> values) {
+			addCriterion("refund_status in", values, "refundStatus");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusNotIn(List<Integer> values) {
+			addCriterion("refund_status not in", values, "refundStatus");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusBetween(Integer value1, Integer value2) {
+			addCriterion("refund_status between", value1, value2, "refundStatus");
+			return (Criteria) this;
+		}
+
+		public Criteria andRefundStatusNotBetween(Integer value1, Integer value2) {
+			addCriterion("refund_status not between", value1, value2, "refundStatus");
+			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 andInitiateIsNull() {
+			addCriterion("initiate is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateIsNotNull() {
+			addCriterion("initiate is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateEqualTo(String value) {
+			addCriterion("initiate =", value, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateNotEqualTo(String value) {
+			addCriterion("initiate <>", value, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateGreaterThan(String value) {
+			addCriterion("initiate >", value, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateGreaterThanOrEqualTo(String value) {
+			addCriterion("initiate >=", value, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateLessThan(String value) {
+			addCriterion("initiate <", value, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateLessThanOrEqualTo(String value) {
+			addCriterion("initiate <=", value, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateLike(String value) {
+			addCriterion("initiate like", value, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateNotLike(String value) {
+			addCriterion("initiate not like", value, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateIn(List<String> values) {
+			addCriterion("initiate in", values, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateNotIn(List<String> values) {
+			addCriterion("initiate not in", values, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateBetween(String value1, String value2) {
+			addCriterion("initiate between", value1, value2, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andInitiateNotBetween(String value1, String value2) {
+			addCriterion("initiate not between", value1, value2, "initiate");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptIsNull() {
+			addCriterion("accept is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptIsNotNull() {
+			addCriterion("accept is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptEqualTo(String value) {
+			addCriterion("accept =", value, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptNotEqualTo(String value) {
+			addCriterion("accept <>", value, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptGreaterThan(String value) {
+			addCriterion("accept >", value, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptGreaterThanOrEqualTo(String value) {
+			addCriterion("accept >=", value, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptLessThan(String value) {
+			addCriterion("accept <", value, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptLessThanOrEqualTo(String value) {
+			addCriterion("accept <=", value, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptLike(String value) {
+			addCriterion("accept like", value, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptNotLike(String value) {
+			addCriterion("accept not like", value, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptIn(List<String> values) {
+			addCriterion("accept in", values, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptNotIn(List<String> values) {
+			addCriterion("accept not in", values, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptBetween(String value1, String value2) {
+			addCriterion("accept between", value1, value2, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andAcceptNotBetween(String value1, String value2) {
+			addCriterion("accept not between", value1, value2, "accept");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonIsNull() {
+			addCriterion("reason is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonIsNotNull() {
+			addCriterion("reason is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonEqualTo(String value) {
+			addCriterion("reason =", value, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonNotEqualTo(String value) {
+			addCriterion("reason <>", value, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonGreaterThan(String value) {
+			addCriterion("reason >", value, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonGreaterThanOrEqualTo(String value) {
+			addCriterion("reason >=", value, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonLessThan(String value) {
+			addCriterion("reason <", value, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonLessThanOrEqualTo(String value) {
+			addCriterion("reason <=", value, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonLike(String value) {
+			addCriterion("reason like", value, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonNotLike(String value) {
+			addCriterion("reason not like", value, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonIn(List<String> values) {
+			addCriterion("reason in", values, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonNotIn(List<String> values) {
+			addCriterion("reason not in", values, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonBetween(String value1, String value2) {
+			addCriterion("reason between", value1, value2, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andReasonNotBetween(String value1, String value2) {
+			addCriterion("reason not between", value1, value2, "reason");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultIsNull() {
+			addCriterion("result is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultIsNotNull() {
+			addCriterion("result is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultEqualTo(String value) {
+			addCriterion("result =", value, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultNotEqualTo(String value) {
+			addCriterion("result <>", value, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultGreaterThan(String value) {
+			addCriterion("result >", value, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultGreaterThanOrEqualTo(String value) {
+			addCriterion("result >=", value, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultLessThan(String value) {
+			addCriterion("result <", value, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultLessThanOrEqualTo(String value) {
+			addCriterion("result <=", value, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultLike(String value) {
+			addCriterion("result like", value, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultNotLike(String value) {
+			addCriterion("result not like", value, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultIn(List<String> values) {
+			addCriterion("result in", values, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultNotIn(List<String> values) {
+			addCriterion("result not in", values, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultBetween(String value1, String value2) {
+			addCriterion("result between", value1, value2, "result");
+			return (Criteria) this;
+		}
+
+		public Criteria andResultNotBetween(String value1, String value2) {
+			addCriterion("result not between", value1, value2, "result");
+			return (Criteria) this;
+		}
+	}
+
+	/**
+	 * This class was generated by MyBatis Generator. This class corresponds to the database table t_order_refund
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	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);
+		}
+	}
+
+	/**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table t_order_refund
+     *
+     * @mbg.generated do_not_delete_during_merge Tue Nov 20 15:04:45 CST 2018
+     */
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+}

+ 74 - 0
src/main/java/com/goafanti/common/model/TOrderRefundWithBLOBs.java

@@ -0,0 +1,74 @@
+package com.goafanti.common.model;
+
+public class TOrderRefundWithBLOBs extends TOrderRefund {
+
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.reason_attachment_url
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private String reasonAttachmentUrl;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.contract_url
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private String contractUrl;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column t_order_refund.application_url
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	private String applicationUrl;
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.reason_attachment_url
+	 * @return  the value of t_order_refund.reason_attachment_url
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public String getReasonAttachmentUrl() {
+		return reasonAttachmentUrl;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.reason_attachment_url
+	 * @param reasonAttachmentUrl  the value for t_order_refund.reason_attachment_url
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setReasonAttachmentUrl(String reasonAttachmentUrl) {
+		this.reasonAttachmentUrl = reasonAttachmentUrl;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.contract_url
+	 * @return  the value of t_order_refund.contract_url
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public String getContractUrl() {
+		return contractUrl;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.contract_url
+	 * @param contractUrl  the value for t_order_refund.contract_url
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setContractUrl(String contractUrl) {
+		this.contractUrl = contractUrl;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column t_order_refund.application_url
+	 * @return  the value of t_order_refund.application_url
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public String getApplicationUrl() {
+		return applicationUrl;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column t_order_refund.application_url
+	 * @param applicationUrl  the value for t_order_refund.application_url
+	 * @mbg.generated  Tue Nov 20 15:20:39 CST 2018
+	 */
+	public void setApplicationUrl(String applicationUrl) {
+		this.applicationUrl = applicationUrl;
+	}
+}

+ 18 - 5
src/main/java/com/goafanti/order/controller/AdminNewOrderApiController.java

@@ -1,21 +1,17 @@
 package com.goafanti.order.controller;
 
 
-import java.util.List;
 
 import org.apache.commons.lang3.StringUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestMethod;
 import org.springframework.web.bind.annotation.RestController;
-
-import com.alibaba.fastjson.JSON;
 import com.goafanti.common.bo.Result;
 import com.goafanti.common.constant.ErrorConstants;
 import com.goafanti.common.controller.CertifyApiController;
-import com.goafanti.common.model.TDunLog;
-import com.goafanti.common.model.TOrderDun;
 import com.goafanti.common.model.TOrderNew;
+import com.goafanti.common.model.TOrderRefundWithBLOBs;
 import com.goafanti.common.model.TOrderTask;
 import com.goafanti.order.service.OrderNewService;
 
@@ -225,5 +221,22 @@ public class AdminNewOrderApiController extends CertifyApiController {
 			res.data(orderNewService.selectDunLogList(dunId));
 			return res;
 	}
+	/**
+	 * 订单退单
+	 */
+	@RequestMapping(value="/addOrderRefund", method = RequestMethod.POST)
+	public Result addOrderRefund(TOrderRefundWithBLOBs t){
+			Result res=new Result();
+			if (StringUtils.isBlank(t.getOrderNo())) {
+				res.getError().add(buildError(ErrorConstants.PARAM_EMPTY_ERROR, "订单编号","订单编号"));
+				return res;
+			}
+			if(StringUtils.isBlank(t.getContractUrl())||StringUtils.isBlank(t.getApplicationUrl())){
+				res.getError().add(buildError(ErrorConstants.PARAM_EMPTY_ERROR, "合同与申请表","合同与申请表"));
+				return res;
+			}
+			res.data(orderNewService.addOrderRefund(t));
+			return res;
+	}
 	
 }

+ 52 - 0
src/main/java/com/goafanti/order/enums/refundState.java

@@ -0,0 +1,52 @@
+package com.goafanti.order.enums;
+
+import java.util.HashMap;
+import java.util.Map;
+
+public enum refundState {
+	/** 正常  **/
+	DSH(0,"待审核"),
+	/** 废除 **/
+	SHTG(1,"审核通过"),
+	/** 锁定 **/
+	SHJJ(2,"审核拒绝"),
+	/** 无效 **/
+	INVALID(10, "INVALID");
+	
+	
+	private refundState(Integer code, String desc) {
+		this.code = code;
+		this.desc = desc;
+	}
+
+	private static Map<Integer, refundState> status = new HashMap<Integer, refundState>();
+
+	static {
+		for (refundState value : refundState.values()) {
+			status.put(value.getCode(), value);
+		}
+	}
+	public static refundState getStatus(Integer code) {
+		if (containsType(code)) {
+			return status.get(code);
+		}
+		return INVALID;
+	}
+	public static boolean containsType(Integer code) {
+		return status.containsKey(code);
+	}
+	private Integer	code;
+	private String	desc;
+	public Integer getCode() {
+		return code;
+	}
+	public void setCode(Integer code) {
+		this.code = code;
+	}
+	public String getDesc() {
+		return desc;
+	}
+	public void setDesc(String desc) {
+		this.desc = desc;
+	}
+}

+ 8 - 0
src/main/java/com/goafanti/order/service/OrderNewService.java

@@ -4,6 +4,8 @@ import java.util.List;
 
 import com.goafanti.common.model.TDunLog;
 import com.goafanti.common.model.TOrderNew;
+import com.goafanti.common.model.TOrderRefund;
+import com.goafanti.common.model.TOrderRefundWithBLOBs;
 import com.goafanti.common.model.TOrderTask;
 import com.goafanti.core.mybatis.page.Pagination;
 import com.goafanti.order.bo.BillListBo;
@@ -105,6 +107,12 @@ public interface OrderNewService {
 	 * @return
 	 */
 	List<TDunLogListBo> selectDunLogList(String dunId);
+	/**
+	 * 新增退单
+	 * @param t
+	 * @return
+	 */
+	int addOrderRefund(TOrderRefundWithBLOBs t);
 	
 
 	

+ 18 - 0
src/main/java/com/goafanti/order/service/impl/OrderNewServiceImpl.java

@@ -28,6 +28,7 @@ import com.goafanti.common.dao.TDunLogMapper;
 import com.goafanti.common.dao.TOrderDunMapper;
 import com.goafanti.common.dao.TOrderMapper;
 import com.goafanti.common.dao.TOrderNewMapper;
+import com.goafanti.common.dao.TOrderRefundMapper;
 import com.goafanti.common.dao.TOrderTaskMapper;
 import com.goafanti.common.dao.UserLockReleaseMapper;
 import com.goafanti.common.enums.UserLockReleaseStatus;
@@ -37,6 +38,8 @@ import com.goafanti.common.model.TOrder;
 import com.goafanti.common.model.TOrderDetail;
 import com.goafanti.common.model.TOrderDun;
 import com.goafanti.common.model.TOrderNew;
+import com.goafanti.common.model.TOrderRefund;
+import com.goafanti.common.model.TOrderRefundWithBLOBs;
 import com.goafanti.common.model.TOrderTask;
 import com.goafanti.common.model.UserLockRelease;
 import com.goafanti.common.utils.BeanUtilsExt;
@@ -54,6 +57,7 @@ import com.goafanti.order.enums.OrderNewState;
 import com.goafanti.order.enums.ProcessStatus;
 import com.goafanti.order.enums.ProjectNewStage;
 import com.goafanti.order.enums.TaskState;
+import com.goafanti.order.enums.refundState;
 import com.goafanti.order.service.OrderNewService;
 
 @Service
@@ -67,6 +71,8 @@ public class OrderNewServiceImpl extends BaseMybatisDao<TOrderNewMapper> impleme
 	@Autowired
 	private TDunLogMapper tDunLogMapper;
 	@Autowired
+	private TOrderRefundMapper	tOrderRefundMapper;	
+	@Autowired
 	private JDBCIdGenerator	idGenerator;
 	@Autowired
 	private UserLockReleaseMapper	userLockReleaseMapper;
@@ -279,5 +285,17 @@ public class OrderNewServiceImpl extends BaseMybatisDao<TOrderNewMapper> impleme
 	public List<TDunLogListBo> selectDunLogList(String dunId) {
 		return tDunLogMapper.selectByDunId(dunId);
 	}
+
+
+
+	@Override
+	public int addOrderRefund(TOrderRefundWithBLOBs t) {
+		t.setRefundStatus(refundState.DSH.getCode());
+		t.setCreateTime(new Date());
+		t.setInitiate(TokenManager.getAdminId()==null?"1":TokenManager.getAdminId());
+		t.setAccept("受理人");
+		t.setResult("");
+		return tOrderRefundMapper.insertSelective(t);
+	}
 	
 }