123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338 |
- <?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.mvc.dao.WmAccMapper">
- <resultMap id="BaseResultMap" type="com.mvc.entity.WmAcc">
- <id column="ID" jdbcType="INTEGER" property="id" />
- <result column="WM_ID" jdbcType="VARCHAR" property="wmId" />
- <result column="STATION_CODE" jdbcType="VARCHAR" property="stationCode" />
- <result column="WM_INDEX" jdbcType="INTEGER" property="wmIndex" />
- <result column="INIT_VOL_FLAG" jdbcType="CHAR" property="initVolFlag" />
- <result column="INIT_VOL" jdbcType="INTEGER" property="initVol" />
- <result column="DN_TYPE" jdbcType="INTEGER" property="dnType" />
- <result column="UINT_TYPE" jdbcType="VARCHAR" property="uintType" />
- <result column="DIGIT_NUM" jdbcType="INTEGER" property="digitNum" />
- <result column="WHELL_NUM" jdbcType="INTEGER" property="whellNum" />
- <result column="CREATE_DATE" jdbcType="TIMESTAMP" property="createDate" />
- <result column="EXP_DATE" jdbcType="TIMESTAMP" property="expDate" />
- <result column="USE_FLAG" jdbcType="CHAR" property="useFlag" />
- </resultMap>
- <sql id="Example_Where_Clause">
- <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">
- <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">
- ID, WM_ID, STATION_CODE, WM_INDEX, INIT_VOL_FLAG, INIT_VOL, DN_TYPE, UINT_TYPE, DIGIT_NUM,
- WHELL_NUM, CREATE_DATE, EXP_DATE, USE_FLAG
- </sql>
- <select id="selectByExample" parameterType="com.mvc.entity.WmAccExample" resultMap="BaseResultMap">
- select
- <if test="distinct">
- distinct
- </if>
- <include refid="Base_Column_List" />
- from wm_acc
- <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="BaseResultMap">
- select
- <include refid="Base_Column_List" />
- from wm_acc
- where ID = #{id,jdbcType=INTEGER}
- </select>
- <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
- delete from wm_acc
- where ID = #{id,jdbcType=INTEGER}
- </delete>
- <delete id="deleteByExample" parameterType="com.mvc.entity.WmAccExample">
- delete from wm_acc
- <if test="_parameter != null">
- <include refid="Example_Where_Clause" />
- </if>
- </delete>
- <insert id="insert" parameterType="com.mvc.entity.WmAcc" useGeneratedKeys="true" keyProperty="id">
- insert into wm_acc (ID, WM_ID, STATION_CODE,
- WM_INDEX, INIT_VOL_FLAG, INIT_VOL,
- DN_TYPE, UINT_TYPE, DIGIT_NUM,
- WHELL_NUM, CREATE_DATE, EXP_DATE,
- USE_FLAG)
- values (#{id,jdbcType=INTEGER}, #{wmId,jdbcType=VARCHAR}, #{stationCode,jdbcType=VARCHAR},
- #{wmIndex,jdbcType=INTEGER}, #{initVolFlag,jdbcType=CHAR}, #{initVol,jdbcType=INTEGER},
- #{dnType,jdbcType=INTEGER}, #{uintType,jdbcType=VARCHAR}, #{digitNum,jdbcType=INTEGER},
- #{whellNum,jdbcType=INTEGER}, #{createDate,jdbcType=TIMESTAMP}, #{expDate,jdbcType=TIMESTAMP},
- #{useFlag,jdbcType=CHAR})
- </insert>
- <insert id="insertSelective" parameterType="com.mvc.entity.WmAcc">
- insert into wm_acc
- <trim prefix="(" suffix=")" suffixOverrides=",">
- <if test="id != null">
- ID,
- </if>
- <if test="wmId != null">
- WM_ID,
- </if>
- <if test="stationCode != null">
- STATION_CODE,
- </if>
- <if test="wmIndex != null">
- WM_INDEX,
- </if>
- <if test="initVolFlag != null">
- INIT_VOL_FLAG,
- </if>
- <if test="initVol != null">
- INIT_VOL,
- </if>
- <if test="dnType != null">
- DN_TYPE,
- </if>
- <if test="uintType != null">
- UINT_TYPE,
- </if>
- <if test="digitNum != null">
- DIGIT_NUM,
- </if>
- <if test="whellNum != null">
- WHELL_NUM,
- </if>
- <if test="createDate != null">
- CREATE_DATE,
- </if>
- <if test="expDate != null">
- EXP_DATE,
- </if>
- <if test="useFlag != null">
- USE_FLAG,
- </if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides=",">
- <if test="id != null">
- #{id,jdbcType=INTEGER},
- </if>
- <if test="wmId != null">
- #{wmId,jdbcType=VARCHAR},
- </if>
- <if test="stationCode != null">
- #{stationCode,jdbcType=VARCHAR},
- </if>
- <if test="wmIndex != null">
- #{wmIndex,jdbcType=INTEGER},
- </if>
- <if test="initVolFlag != null">
- #{initVolFlag,jdbcType=CHAR},
- </if>
- <if test="initVol != null">
- #{initVol,jdbcType=INTEGER},
- </if>
- <if test="dnType != null">
- #{dnType,jdbcType=INTEGER},
- </if>
- <if test="uintType != null">
- #{uintType,jdbcType=VARCHAR},
- </if>
- <if test="digitNum != null">
- #{digitNum,jdbcType=INTEGER},
- </if>
- <if test="whellNum != null">
- #{whellNum,jdbcType=INTEGER},
- </if>
- <if test="createDate != null">
- #{createDate,jdbcType=TIMESTAMP},
- </if>
- <if test="expDate != null">
- #{expDate,jdbcType=TIMESTAMP},
- </if>
- <if test="useFlag != null">
- #{useFlag,jdbcType=CHAR},
- </if>
- </trim>
- </insert>
- <select id="countByExample" parameterType="com.mvc.entity.WmAccExample" resultType="java.lang.Long">
- select count(*) from wm_acc
- <if test="_parameter != null">
- <include refid="Example_Where_Clause" />
- </if>
- </select>
- <update id="updateByExampleSelective" parameterType="map">
- update wm_acc
- <set>
- <if test="record.id != null">
- ID = #{record.id,jdbcType=INTEGER},
- </if>
- <if test="record.wmId != null">
- WM_ID = #{record.wmId,jdbcType=VARCHAR},
- </if>
- <if test="record.stationCode != null">
- STATION_CODE = #{record.stationCode,jdbcType=VARCHAR},
- </if>
- <if test="record.wmIndex != null">
- WM_INDEX = #{record.wmIndex,jdbcType=INTEGER},
- </if>
- <if test="record.initVolFlag != null">
- INIT_VOL_FLAG = #{record.initVolFlag,jdbcType=CHAR},
- </if>
- <if test="record.initVol != null">
- INIT_VOL = #{record.initVol,jdbcType=INTEGER},
- </if>
- <if test="record.dnType != null">
- DN_TYPE = #{record.dnType,jdbcType=INTEGER},
- </if>
- <if test="record.uintType != null">
- UINT_TYPE = #{record.uintType,jdbcType=VARCHAR},
- </if>
- <if test="record.digitNum != null">
- DIGIT_NUM = #{record.digitNum,jdbcType=INTEGER},
- </if>
- <if test="record.whellNum != null">
- WHELL_NUM = #{record.whellNum,jdbcType=INTEGER},
- </if>
- <if test="record.createDate != null">
- CREATE_DATE = #{record.createDate,jdbcType=TIMESTAMP},
- </if>
- <if test="record.expDate != null">
- EXP_DATE = #{record.expDate,jdbcType=TIMESTAMP},
- </if>
- <if test="record.useFlag != null">
- USE_FLAG = #{record.useFlag,jdbcType=CHAR},
- </if>
- </set>
- <if test="_parameter != null">
- <include refid="Update_By_Example_Where_Clause" />
- </if>
- </update>
- <update id="updateByExample" parameterType="map">
- update wm_acc
- set ID = #{record.id,jdbcType=INTEGER},
- WM_ID = #{record.wmId,jdbcType=VARCHAR},
- STATION_CODE = #{record.stationCode,jdbcType=VARCHAR},
- WM_INDEX = #{record.wmIndex,jdbcType=INTEGER},
- INIT_VOL_FLAG = #{record.initVolFlag,jdbcType=CHAR},
- INIT_VOL = #{record.initVol,jdbcType=INTEGER},
- DN_TYPE = #{record.dnType,jdbcType=INTEGER},
- UINT_TYPE = #{record.uintType,jdbcType=VARCHAR},
- DIGIT_NUM = #{record.digitNum,jdbcType=INTEGER},
- WHELL_NUM = #{record.whellNum,jdbcType=INTEGER},
- CREATE_DATE = #{record.createDate,jdbcType=TIMESTAMP},
- EXP_DATE = #{record.expDate,jdbcType=TIMESTAMP},
- USE_FLAG = #{record.useFlag,jdbcType=CHAR}
- <if test="_parameter != null">
- <include refid="Update_By_Example_Where_Clause" />
- </if>
- </update>
- <update id="updateByPrimaryKeySelective" parameterType="com.mvc.entity.WmAcc">
- update wm_acc
- <set>
- <if test="wmId != null">
- WM_ID = #{wmId,jdbcType=VARCHAR},
- </if>
- <if test="stationCode != null">
- STATION_CODE = #{stationCode,jdbcType=VARCHAR},
- </if>
- <if test="wmIndex != null">
- WM_INDEX = #{wmIndex,jdbcType=INTEGER},
- </if>
- <if test="initVolFlag != null">
- INIT_VOL_FLAG = #{initVolFlag,jdbcType=CHAR},
- </if>
- <if test="initVol != null">
- INIT_VOL = #{initVol,jdbcType=INTEGER},
- </if>
- <if test="dnType != null">
- DN_TYPE = #{dnType,jdbcType=INTEGER},
- </if>
- <if test="uintType != null">
- UINT_TYPE = #{uintType,jdbcType=VARCHAR},
- </if>
- <if test="digitNum != null">
- DIGIT_NUM = #{digitNum,jdbcType=INTEGER},
- </if>
- <if test="whellNum != null">
- WHELL_NUM = #{whellNum,jdbcType=INTEGER},
- </if>
- <if test="createDate != null">
- CREATE_DATE = #{createDate,jdbcType=TIMESTAMP},
- </if>
- <if test="expDate != null">
- EXP_DATE = #{expDate,jdbcType=TIMESTAMP},
- </if>
- <if test="useFlag != null">
- USE_FLAG = #{useFlag,jdbcType=CHAR},
- </if>
- </set>
- where ID = #{id,jdbcType=INTEGER}
- </update>
- <update id="updateByPrimaryKey" parameterType="com.mvc.entity.WmAcc">
- update wm_acc
- set WM_ID = #{wmId,jdbcType=VARCHAR},
- STATION_CODE = #{stationCode,jdbcType=VARCHAR},
- WM_INDEX = #{wmIndex,jdbcType=INTEGER},
- INIT_VOL_FLAG = #{initVolFlag,jdbcType=CHAR},
- INIT_VOL = #{initVol,jdbcType=INTEGER},
- DN_TYPE = #{dnType,jdbcType=INTEGER},
- UINT_TYPE = #{uintType,jdbcType=VARCHAR},
- DIGIT_NUM = #{digitNum,jdbcType=INTEGER},
- WHELL_NUM = #{whellNum,jdbcType=INTEGER},
- CREATE_DATE = #{createDate,jdbcType=TIMESTAMP},
- EXP_DATE = #{expDate,jdbcType=TIMESTAMP},
- USE_FLAG = #{useFlag,jdbcType=CHAR}
- where ID = #{id,jdbcType=INTEGER}
- </update>
- </mapper>
|