123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792 |
- <?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.steerinfo.dil.mapper.RmsCapacityMapper">
- <resultMap id="BaseResultMap" type="com.steerinfo.dil.model.RmsCapacity">
- <id column="CAPACITY_ID" jdbcType="DECIMAL" property="capacityId" />
- <result column="CAPACITY_NUMBER" jdbcType="VARCHAR" property="capacityNumber" />
- <result column="CAPACITY_MAX_LOAD" jdbcType="DECIMAL" property="capacityMaxLoad" />
- <result column="CAPACITY_TYPE_ID" jdbcType="DECIMAL" property="capacityTypeId" />
- <result column="CAPACITY_STATUS" jdbcType="DECIMAL" property="capacityStatus" />
- <result column="CARRIER_ID" jdbcType="DECIMAL" property="carrierId" />
- <result column="CAPACITY_ENERGY_ID" jdbcType="VARCHAR" property="capacityEnergyId" />
- <result column="CAPACITY_LEN_VAL" jdbcType="DECIMAL" property="capacityLenVal" />
- <result column="CAPACITY_WID_VAL" jdbcType="DECIMAL" property="capacityWidVal" />
- <result column="CAPACITY_HIG_VAL" jdbcType="DECIMAL" property="capacityHigVal" />
- <result column="CAPACITY_OIL_ID" jdbcType="DECIMAL" property="capacityOilId" />
- <result column="CAPACITY_FUEL_CONSUMPTION" jdbcType="VARCHAR" property="capacityFuelConsumption" />
- <result column="CAPACITY_OWNERIS" jdbcType="VARCHAR" property="capacityOwneris" />
- <result column="CAPACITY_BLACKLIST" jdbcType="VARCHAR" property="capacityBlacklist" />
- <result column="MEMO" jdbcType="VARCHAR" property="memo" />
- <result column="INSERT_USERNAME" jdbcType="VARCHAR" property="insertUsername" />
- <result column="INSERT_TIME" jdbcType="TIMESTAMP" property="insertTime" />
- <result column="UPDATE_USERNAME" jdbcType="VARCHAR" property="updateUsername" />
- <result column="UPDATE_TIME" jdbcType="TIMESTAMP" property="updateTime" />
- <result column="INSERT_UPDATE_REMARK" jdbcType="VARCHAR" property="insertUpdateRemark" />
- <result column="CAPACITY_CORLOR" jdbcType="VARCHAR" property="capacityCorlor" />
- <result column="CAPACITY_VIP" jdbcType="VARCHAR" property="capacityVip" />
- <result column="DELETED" jdbcType="DECIMAL" property="deleted" />
- </resultMap>
- <sql id="columns">
- CAPACITY_ID, CAPACITY_NUMBER, CAPACITY_MAX_LOAD, CAPACITY_TYPE_ID, CAPACITY_STATUS,
- CARRIER_ID, CAPACITY_ENERGY_ID, CAPACITY_LEN_VAL, CAPACITY_WID_VAL, CAPACITY_HIG_VAL,
- CAPACITY_OIL_ID, CAPACITY_FUEL_CONSUMPTION, CAPACITY_OWNERIS, CAPACITY_BLACKLIST,
- MEMO, INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK,
- CAPACITY_CORLOR, CAPACITY_VIP, DELETED
- </sql>
- <sql id="columns_alias">
- t.CAPACITY_ID, t.CAPACITY_NUMBER, t.CAPACITY_MAX_LOAD, t.CAPACITY_TYPE_ID, t.CAPACITY_STATUS,
- t.CARRIER_ID, t.CAPACITY_ENERGY_ID, t.CAPACITY_LEN_VAL, t.CAPACITY_WID_VAL, t.CAPACITY_HIG_VAL,
- t.CAPACITY_OIL_ID, t.CAPACITY_FUEL_CONSUMPTION, t.CAPACITY_OWNERIS, t.CAPACITY_BLACKLIST,
- t.MEMO, t.INSERT_USERNAME, t.INSERT_TIME, t.UPDATE_USERNAME, t.UPDATE_TIME, t.INSERT_UPDATE_REMARK,
- t.CAPACITY_CORLOR, t.CAPACITY_VIP, t.DELETED
- </sql>
- <sql id="select">
- SELECT <include refid="columns" /> FROM RMS_CAPACITY
- </sql>
- <sql id="select_alias">
- SELECT <include refid="columns_alias" /> FROM RMS_CAPACITY t
- </sql>
- <sql id="where">
- <where>
- <if test="capacityId != null">
- and CAPACITY_ID = #{capacityId}
- </if>
- <if test="capacityNumber != null and capacityNumber != ''">
- and CAPACITY_NUMBER = #{capacityNumber}
- </if>
- <if test="capacityMaxLoad != null">
- and CAPACITY_MAX_LOAD = #{capacityMaxLoad}
- </if>
- <if test="capacityTypeId != null">
- and CAPACITY_TYPE_ID = #{capacityTypeId}
- </if>
- <if test="capacityStatus != null and capacityStatus != ''">
- and CAPACITY_STATUS = #{capacityStatus}
- </if>
- <if test="carrierId != null">
- and CARRIER_ID = #{carrierId}
- </if>
- <if test="capacityEnergyId != null and capacityEnergyId != ''">
- and CAPACITY_ENERGY_ID = #{capacityEnergyId}
- </if>
- <if test="capacityLenVal != null">
- and CAPACITY_LEN_VAL = #{capacityLenVal}
- </if>
- <if test="capacityWidVal != null">
- and CAPACITY_WID_VAL = #{capacityWidVal}
- </if>
- <if test="capacityHigVal != null">
- and CAPACITY_HIG_VAL = #{capacityHigVal}
- </if>
- <if test="capacityOilId != null">
- and CAPACITY_OIL_ID = #{capacityOilId}
- </if>
- <if test="capacityFuelConsumption != null and capacityFuelConsumption != ''">
- and CAPACITY_FUEL_CONSUMPTION = #{capacityFuelConsumption}
- </if>
- <if test="capacityOwneris != null and capacityOwneris != ''">
- and CAPACITY_OWNERIS = #{capacityOwneris}
- </if>
- <if test="capacityBlacklist != null and capacityBlacklist != ''">
- and CAPACITY_BLACKLIST = #{capacityBlacklist}
- </if>
- <if test="memo != null and memo != ''">
- and MEMO = #{memo}
- </if>
- <if test="insertUsername != null and insertUsername != ''">
- and INSERT_USERNAME = #{insertUsername}
- </if>
- <if test="insertTime != null">
- and TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = #{insertTime}
- </if>
- <if test="updateUsername != null and updateUsername != ''">
- and UPDATE_USERNAME = #{updateUsername}
- </if>
- <if test="updateTime != null">
- and TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = #{updateTime}
- </if>
- <if test="insertUpdateRemark != null and insertUpdateRemark != ''">
- and INSERT_UPDATE_REMARK = #{insertUpdateRemark}
- </if>
- <if test="capacityCorlor != null and capacityCorlor != ''">
- and CAPACITY_CORLOR = #{capacityCorlor}
- </if>
- <if test="capacityVip != null and capacityVip != ''">
- and CAPACITY_VIP = #{capacityVip}
- </if>
- <if test="deleted != null">
- and DELETED = #{deleted}
- </if>
- </where>
- </sql>
- <sql id="whereLike">
- <where>
- <if test="capacityId != null">
- and CAPACITY_ID = #{capacityId}
- </if>
- <if test="capacityNumber != null and capacityNumber != ''">
- and CAPACITY_NUMBER LIKE '%${capacityNumber}%'
- </if>
- <if test="capacityMaxLoad != null">
- and CAPACITY_MAX_LOAD = #{capacityMaxLoad}
- </if>
- <if test="capacityTypeId != null">
- and CAPACITY_TYPE_ID = #{capacityTypeId}
- </if>
- <if test="capacityStatus != null and capacityStatus != ''">
- and CAPACITY_STATUS LIKE '%${capacityStatus}%'
- </if>
- <if test="carrierId != null">
- and CARRIER_ID = #{carrierId}
- </if>
- <if test="capacityEnergyId != null and capacityEnergyId != ''">
- and CAPACITY_ENERGY_ID LIKE '%${capacityEnergyId}%'
- </if>
- <if test="capacityLenVal != null">
- and CAPACITY_LEN_VAL = #{capacityLenVal}
- </if>
- <if test="capacityWidVal != null">
- and CAPACITY_WID_VAL = #{capacityWidVal}
- </if>
- <if test="capacityHigVal != null">
- and CAPACITY_HIG_VAL = #{capacityHigVal}
- </if>
- <if test="capacityOilId != null">
- and CAPACITY_OIL_ID = #{capacityOilId}
- </if>
- <if test="capacityFuelConsumption != null and capacityFuelConsumption != ''">
- and CAPACITY_FUEL_CONSUMPTION LIKE '%${capacityFuelConsumption}%'
- </if>
- <if test="capacityOwneris != null and capacityOwneris != ''">
- and CAPACITY_OWNERIS LIKE '%${capacityOwneris}%'
- </if>
- <if test="capacityBlacklist != null and capacityBlacklist != ''">
- and CAPACITY_BLACKLIST LIKE '%${capacityBlacklist}%'
- </if>
- <if test="memo != null and memo != ''">
- and MEMO LIKE '%${memo}%'
- </if>
- <if test="insertUsername != null and insertUsername != ''">
- and INSERT_USERNAME LIKE '%${insertUsername}%'
- </if>
- <if test="insertTime != null">
- and TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = #{insertTime}
- </if>
- <if test="updateUsername != null and updateUsername != ''">
- and UPDATE_USERNAME LIKE '%${updateUsername}%'
- </if>
- <if test="updateTime != null">
- and TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = #{updateTime}
- </if>
- <if test="insertUpdateRemark != null and insertUpdateRemark != ''">
- and INSERT_UPDATE_REMARK LIKE '%${insertUpdateRemark}%'
- </if>
- <if test="capacityCorlor != null and capacityCorlor != ''">
- and CAPACITY_CORLOR LIKE '%${capacityCorlor}%'
- </if>
- <if test="capacityVip != null and capacityVip != ''">
- and CAPACITY_VIP LIKE '%${capacityVip}%'
- </if>
- <if test="deleted != null">
- and DELETED = #{deleted}
- </if>
- </where>
- </sql>
- <delete id="deleteByPrimaryKey" parameterType="java.math.BigDecimal">
- delete from RMS_CAPACITY
- where CAPACITY_ID = #{capacityId,jdbcType=DECIMAL}
- </delete>
- <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
- delete from RMS_CAPACITY
- where 1!=1
- <if test="capacityNumber != null and capacityNumber != ''">
- or CAPACITY_NUMBER = #{capacityNumber}
- </if>
- <if test="capacityMaxLoad != null">
- or CAPACITY_MAX_LOAD = #{capacityMaxLoad}
- </if>
- <if test="capacityTypeId != null">
- or CAPACITY_TYPE_ID = #{capacityTypeId}
- </if>
- <if test="capacityStatus != null and capacityStatus != ''">
- or CAPACITY_STATUS = #{capacityStatus}
- </if>
- <if test="carrierId != null">
- or CARRIER_ID = #{carrierId}
- </if>
- <if test="capacityEnergyId != null and capacityEnergyId != ''">
- or CAPACITY_ENERGY_ID = #{capacityEnergyId}
- </if>
- <if test="capacityLenVal != null">
- or CAPACITY_LEN_VAL = #{capacityLenVal}
- </if>
- <if test="capacityWidVal != null">
- or CAPACITY_WID_VAL = #{capacityWidVal}
- </if>
- <if test="capacityHigVal != null">
- or CAPACITY_HIG_VAL = #{capacityHigVal}
- </if>
- <if test="capacityOilId != null">
- or CAPACITY_OIL_ID = #{capacityOilId}
- </if>
- <if test="capacityFuelConsumption != null and capacityFuelConsumption != ''">
- or CAPACITY_FUEL_CONSUMPTION = #{capacityFuelConsumption}
- </if>
- <if test="capacityOwneris != null and capacityOwneris != ''">
- or CAPACITY_OWNERIS = #{capacityOwneris}
- </if>
- <if test="capacityBlacklist != null and capacityBlacklist != ''">
- or CAPACITY_BLACKLIST = #{capacityBlacklist}
- </if>
- <if test="memo != null and memo != ''">
- or MEMO = #{memo}
- </if>
- <if test="insertUsername != null and insertUsername != ''">
- or INSERT_USERNAME = #{insertUsername}
- </if>
- <if test="insertTime != null">
- or TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = '#{insertTime}'
- </if>
- <if test="updateUsername != null and updateUsername != ''">
- or UPDATE_USERNAME = #{updateUsername}
- </if>
- <if test="updateTime != null">
- or TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = '#{updateTime}'
- </if>
- <if test="insertUpdateRemark != null and insertUpdateRemark != ''">
- or INSERT_UPDATE_REMARK = #{insertUpdateRemark}
- </if>
- <if test="capacityCorlor != null and capacityCorlor != ''">
- or CAPACITY_CORLOR = #{capacityCorlor}
- </if>
- <if test="capacityVip != null and capacityVip != ''">
- or CAPACITY_VIP = #{capacityVip}
- </if>
- <if test="deleted != null">
- or DELETED = #{deleted}
- </if>
- </delete>
- <insert id="insert" parameterType="com.steerinfo.dil.model.RmsCapacity">
- insert into RMS_CAPACITY (CAPACITY_ID, CAPACITY_NUMBER, CAPACITY_MAX_LOAD,
- CAPACITY_TYPE_ID, CAPACITY_STATUS, CARRIER_ID,
- CAPACITY_ENERGY_ID, CAPACITY_LEN_VAL, CAPACITY_WID_VAL,
- CAPACITY_HIG_VAL, CAPACITY_OIL_ID, CAPACITY_FUEL_CONSUMPTION,
- CAPACITY_OWNERIS, CAPACITY_BLACKLIST, MEMO,
- INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME,
- UPDATE_TIME, INSERT_UPDATE_REMARK, CAPACITY_CORLOR,
- CAPACITY_VIP, DELETED)
- values (#{capacityId,jdbcType=DECIMAL}, #{capacityNumber,jdbcType=VARCHAR}, #{capacityMaxLoad,jdbcType=DECIMAL},
- #{capacityTypeId,jdbcType=DECIMAL}, #{capacityStatus,jdbcType=DECIMAL}, #{carrierId,jdbcType=DECIMAL},
- #{capacityEnergyId,jdbcType=VARCHAR}, #{capacityLenVal,jdbcType=DECIMAL}, #{capacityWidVal,jdbcType=DECIMAL},
- #{capacityHigVal,jdbcType=DECIMAL}, #{capacityOilId,jdbcType=DECIMAL}, #{capacityFuelConsumption,jdbcType=VARCHAR},
- #{capacityOwneris,jdbcType=VARCHAR}, #{capacityBlacklist,jdbcType=VARCHAR}, #{memo,jdbcType=VARCHAR},
- #{insertUsername,jdbcType=VARCHAR}, #{insertTime,jdbcType=TIMESTAMP}, #{updateUsername,jdbcType=VARCHAR},
- #{updateTime,jdbcType=TIMESTAMP}, #{insertUpdateRemark,jdbcType=VARCHAR}, #{capacityCorlor,jdbcType=VARCHAR},
- #{capacityVip,jdbcType=VARCHAR}, #{deleted,jdbcType=DECIMAL})
- </insert>
- <insert id="insertSelective" parameterType="com.steerinfo.dil.model.RmsCapacity">
- insert into RMS_CAPACITY
- <trim prefix="(" suffix=")" suffixOverrides=",">
- <if test="capacityId != null">
- CAPACITY_ID,
- </if>
- <if test="capacityNumber != null">
- CAPACITY_NUMBER,
- </if>
- <if test="capacityMaxLoad != null">
- CAPACITY_MAX_LOAD,
- </if>
- <if test="capacityTypeId != null">
- CAPACITY_TYPE_ID,
- </if>
- <if test="capacityStatus != null">
- CAPACITY_STATUS,
- </if>
- <if test="carrierId != null">
- CARRIER_ID,
- </if>
- <if test="capacityEnergyId != null">
- CAPACITY_ENERGY_ID,
- </if>
- <if test="capacityLenVal != null">
- CAPACITY_LEN_VAL,
- </if>
- <if test="capacityWidVal != null">
- CAPACITY_WID_VAL,
- </if>
- <if test="capacityHigVal != null">
- CAPACITY_HIG_VAL,
- </if>
- <if test="capacityOilId != null">
- CAPACITY_OIL_ID,
- </if>
- <if test="capacityFuelConsumption != null">
- CAPACITY_FUEL_CONSUMPTION,
- </if>
- <if test="capacityOwneris != null">
- CAPACITY_OWNERIS,
- </if>
- <if test="capacityBlacklist != null">
- CAPACITY_BLACKLIST,
- </if>
- <if test="memo != null">
- MEMO,
- </if>
- <if test="insertUsername != null">
- INSERT_USERNAME,
- </if>
- <if test="insertTime != null">
- INSERT_TIME,
- </if>
- <if test="updateUsername != null">
- UPDATE_USERNAME,
- </if>
- <if test="updateTime != null">
- UPDATE_TIME,
- </if>
- <if test="insertUpdateRemark != null">
- INSERT_UPDATE_REMARK,
- </if>
- <if test="capacityCorlor != null">
- CAPACITY_CORLOR,
- </if>
- <if test="capacityVip != null">
- CAPACITY_VIP,
- </if>
- <if test="deleted != null">
- DELETED,
- </if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides=",">
- <if test="capacityId != null">
- #{capacityId,jdbcType=DECIMAL},
- </if>
- <if test="capacityNumber != null">
- #{capacityNumber,jdbcType=VARCHAR},
- </if>
- <if test="capacityMaxLoad != null">
- #{capacityMaxLoad,jdbcType=DECIMAL},
- </if>
- <if test="capacityTypeId != null">
- #{capacityTypeId,jdbcType=DECIMAL},
- </if>
- <if test="capacityStatus != null">
- #{capacityStatus,jdbcType=DECIMAL},
- </if>
- <if test="carrierId != null">
- #{carrierId,jdbcType=DECIMAL},
- </if>
- <if test="capacityEnergyId != null">
- #{capacityEnergyId,jdbcType=VARCHAR},
- </if>
- <if test="capacityLenVal != null">
- #{capacityLenVal,jdbcType=DECIMAL},
- </if>
- <if test="capacityWidVal != null">
- #{capacityWidVal,jdbcType=DECIMAL},
- </if>
- <if test="capacityHigVal != null">
- #{capacityHigVal,jdbcType=DECIMAL},
- </if>
- <if test="capacityOilId != null">
- #{capacityOilId,jdbcType=DECIMAL},
- </if>
- <if test="capacityFuelConsumption != null">
- #{capacityFuelConsumption,jdbcType=VARCHAR},
- </if>
- <if test="capacityOwneris != null">
- #{capacityOwneris,jdbcType=VARCHAR},
- </if>
- <if test="capacityBlacklist != null">
- #{capacityBlacklist,jdbcType=VARCHAR},
- </if>
- <if test="memo != null">
- #{memo,jdbcType=VARCHAR},
- </if>
- <if test="insertUsername != null">
- #{insertUsername,jdbcType=VARCHAR},
- </if>
- <if test="insertTime != null">
- #{insertTime,jdbcType=TIMESTAMP},
- </if>
- <if test="updateUsername != null">
- #{updateUsername,jdbcType=VARCHAR},
- </if>
- <if test="updateTime != null">
- #{updateTime,jdbcType=TIMESTAMP},
- </if>
- <if test="insertUpdateRemark != null">
- #{insertUpdateRemark,jdbcType=VARCHAR},
- </if>
- <if test="capacityCorlor != null">
- #{capacityCorlor,jdbcType=VARCHAR},
- </if>
- <if test="capacityVip != null">
- #{capacityVip,jdbcType=VARCHAR},
- </if>
- <if test="deleted != null">
- #{deleted,jdbcType=DECIMAL},
- </if>
- </trim>
- </insert>
- <update id="updateByPrimaryKey" parameterType="com.steerinfo.dil.model.RmsCapacity">
- update RMS_CAPACITY
- set CAPACITY_NUMBER = #{capacityNumber,jdbcType=VARCHAR},
- CAPACITY_MAX_LOAD = #{capacityMaxLoad,jdbcType=DECIMAL},
- CAPACITY_TYPE_ID = #{capacityTypeId,jdbcType=DECIMAL},
- CAPACITY_STATUS = #{capacityStatus,jdbcType=DECIMAL},
- CARRIER_ID = #{carrierId,jdbcType=DECIMAL},
- CAPACITY_ENERGY_ID = #{capacityEnergyId,jdbcType=VARCHAR},
- CAPACITY_LEN_VAL = #{capacityLenVal,jdbcType=DECIMAL},
- CAPACITY_WID_VAL = #{capacityWidVal,jdbcType=DECIMAL},
- CAPACITY_HIG_VAL = #{capacityHigVal,jdbcType=DECIMAL},
- CAPACITY_OIL_ID = #{capacityOilId,jdbcType=DECIMAL},
- CAPACITY_FUEL_CONSUMPTION = #{capacityFuelConsumption,jdbcType=VARCHAR},
- CAPACITY_OWNERIS = #{capacityOwneris,jdbcType=VARCHAR},
- CAPACITY_BLACKLIST = #{capacityBlacklist,jdbcType=VARCHAR},
- MEMO = #{memo,jdbcType=VARCHAR},
- INSERT_USERNAME = #{insertUsername,jdbcType=VARCHAR},
- INSERT_TIME = #{insertTime,jdbcType=TIMESTAMP},
- UPDATE_USERNAME = #{updateUsername,jdbcType=VARCHAR},
- UPDATE_TIME = #{updateTime,jdbcType=TIMESTAMP},
- INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR},
- CAPACITY_CORLOR = #{capacityCorlor,jdbcType=VARCHAR},
- CAPACITY_VIP = #{capacityVip,jdbcType=VARCHAR},
- DELETED = #{deleted,jdbcType=DECIMAL}
- where CAPACITY_ID = #{capacityId,jdbcType=DECIMAL}
- </update>
- <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.dil.model.RmsCapacity">
- update RMS_CAPACITY
- <set>
- <if test="capacityNumber != null">
- CAPACITY_NUMBER = #{capacityNumber,jdbcType=VARCHAR},
- </if>
- <if test="capacityMaxLoad != null">
- CAPACITY_MAX_LOAD = #{capacityMaxLoad,jdbcType=DECIMAL},
- </if>
- <if test="capacityTypeId != null">
- CAPACITY_TYPE_ID = #{capacityTypeId,jdbcType=DECIMAL},
- </if>
- <if test="capacityStatus != null">
- CAPACITY_STATUS = #{capacityStatus,jdbcType=DECIMAL},
- </if>
- <if test="carrierId != null">
- CARRIER_ID = #{carrierId,jdbcType=DECIMAL},
- </if>
- <if test="capacityEnergyId != null">
- CAPACITY_ENERGY_ID = #{capacityEnergyId,jdbcType=VARCHAR},
- </if>
- <if test="capacityLenVal != null">
- CAPACITY_LEN_VAL = #{capacityLenVal,jdbcType=DECIMAL},
- </if>
- <if test="capacityWidVal != null">
- CAPACITY_WID_VAL = #{capacityWidVal,jdbcType=DECIMAL},
- </if>
- <if test="capacityHigVal != null">
- CAPACITY_HIG_VAL = #{capacityHigVal,jdbcType=DECIMAL},
- </if>
- <if test="capacityOilId != null">
- CAPACITY_OIL_ID = #{capacityOilId,jdbcType=DECIMAL},
- </if>
- <if test="capacityFuelConsumption != null">
- CAPACITY_FUEL_CONSUMPTION = #{capacityFuelConsumption,jdbcType=VARCHAR},
- </if>
- <if test="capacityOwneris != null">
- CAPACITY_OWNERIS = #{capacityOwneris,jdbcType=VARCHAR},
- </if>
- <if test="capacityBlacklist != null">
- CAPACITY_BLACKLIST = #{capacityBlacklist,jdbcType=VARCHAR},
- </if>
- <if test="memo != null">
- MEMO = #{memo,jdbcType=VARCHAR},
- </if>
- <if test="insertUsername != null">
- INSERT_USERNAME = #{insertUsername,jdbcType=VARCHAR},
- </if>
- <if test="insertTime != null">
- INSERT_TIME = #{insertTime,jdbcType=TIMESTAMP},
- </if>
- <if test="updateUsername != null">
- UPDATE_USERNAME = #{updateUsername,jdbcType=VARCHAR},
- </if>
- <if test="updateTime != null">
- UPDATE_TIME = #{updateTime,jdbcType=TIMESTAMP},
- </if>
- <if test="insertUpdateRemark != null">
- INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR},
- </if>
- <if test="capacityCorlor != null">
- CAPACITY_CORLOR = #{capacityCorlor,jdbcType=VARCHAR},
- </if>
- <if test="capacityVip != null">
- CAPACITY_VIP = #{capacityVip,jdbcType=VARCHAR},
- </if>
- <if test="deleted != null">
- DELETED = #{deleted,jdbcType=DECIMAL},
- </if>
- </set>
- where CAPACITY_ID = #{capacityId,jdbcType=DECIMAL}
- </update>
- <select id="selectByPrimaryKey" parameterType="java.math.BigDecimal" resultMap="BaseResultMap">
- <include refid="select" />
- where CAPACITY_ID = #{capacityId,jdbcType=DECIMAL}
- </select>
- <select id="selectByParameters" parameterType="java.util.HashMap" resultMap="BaseResultMap">
- <include refid="select" />
- <include refid="where" />
- </select>
- <select id="selectLikeByParameters" parameterType="java.util.HashMap" resultMap="BaseResultMap">
- <include refid="select" />
- <include refid="whereLike" />
- </select>
- <insert id="batchInsert" parameterType="java.util.List">
- insert into RMS_CAPACITY
- (CAPACITY_ID,
- CAPACITY_NUMBER, CAPACITY_MAX_LOAD,
- CAPACITY_TYPE_ID, CAPACITY_STATUS,
- CARRIER_ID, CAPACITY_ENERGY_ID,
- CAPACITY_LEN_VAL, CAPACITY_WID_VAL,
- CAPACITY_HIG_VAL, CAPACITY_OIL_ID,
- CAPACITY_FUEL_CONSUMPTION, CAPACITY_OWNERIS,
- CAPACITY_BLACKLIST, MEMO, INSERT_USERNAME,
- INSERT_TIME, UPDATE_USERNAME,
- UPDATE_TIME, INSERT_UPDATE_REMARK,
- CAPACITY_CORLOR, CAPACITY_VIP,
- DELETED)
- ( <foreach collection="list" item="item" separator="union all">
- select
- #{item.capacityId,jdbcType=DECIMAL},
- #{item.capacityNumber,jdbcType=VARCHAR}, #{item.capacityMaxLoad,jdbcType=DECIMAL},
- #{item.capacityTypeId,jdbcType=DECIMAL}, #{item.capacityStatus,jdbcType=DECIMAL},
- #{item.carrierId,jdbcType=DECIMAL}, #{item.capacityEnergyId,jdbcType=VARCHAR},
- #{item.capacityLenVal,jdbcType=DECIMAL}, #{item.capacityWidVal,jdbcType=DECIMAL},
- #{item.capacityHigVal,jdbcType=DECIMAL}, #{item.capacityOilId,jdbcType=DECIMAL},
- #{item.capacityFuelConsumption,jdbcType=VARCHAR}, #{item.capacityOwneris,jdbcType=VARCHAR},
- #{item.capacityBlacklist,jdbcType=VARCHAR}, #{item.memo,jdbcType=VARCHAR}, #{item.insertUsername,jdbcType=VARCHAR},
- #{item.insertTime,jdbcType=TIMESTAMP}, #{item.updateUsername,jdbcType=VARCHAR},
- #{item.updateTime,jdbcType=TIMESTAMP}, #{item.insertUpdateRemark,jdbcType=VARCHAR},
- #{item.capacityCorlor,jdbcType=VARCHAR}, #{item.capacityVip,jdbcType=VARCHAR},
- #{item.deleted,jdbcType=DECIMAL} from dual
- </foreach> )
- </insert>
- <update id="batchUpdate" parameterType="java.util.List">
- update RMS_CAPACITY
- set
- CAPACITY_ID=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityId,jdbcType=DECIMAL}
- </foreach>
- ,CAPACITY_NUMBER=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityNumber,jdbcType=VARCHAR}
- </foreach>
- ,CAPACITY_MAX_LOAD=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityMaxLoad,jdbcType=DECIMAL}
- </foreach>
- ,CAPACITY_TYPE_ID=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityTypeId,jdbcType=DECIMAL}
- </foreach>
- ,CAPACITY_STATUS=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityStatus,jdbcType=DECIMAL}
- </foreach>
- ,CARRIER_ID=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.carrierId,jdbcType=DECIMAL}
- </foreach>
- ,CAPACITY_ENERGY_ID=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityEnergyId,jdbcType=VARCHAR}
- </foreach>
- ,CAPACITY_LEN_VAL=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityLenVal,jdbcType=DECIMAL}
- </foreach>
- ,CAPACITY_WID_VAL=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityWidVal,jdbcType=DECIMAL}
- </foreach>
- ,CAPACITY_HIG_VAL=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityHigVal,jdbcType=DECIMAL}
- </foreach>
- ,CAPACITY_OIL_ID=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityOilId,jdbcType=DECIMAL}
- </foreach>
- ,CAPACITY_FUEL_CONSUMPTION=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityFuelConsumption,jdbcType=VARCHAR}
- </foreach>
- ,CAPACITY_OWNERIS=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityOwneris,jdbcType=VARCHAR}
- </foreach>
- ,CAPACITY_BLACKLIST=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityBlacklist,jdbcType=VARCHAR}
- </foreach>
- ,MEMO=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.memo,jdbcType=VARCHAR}
- </foreach>
- ,INSERT_USERNAME=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.insertUsername,jdbcType=VARCHAR}
- </foreach>
- ,INSERT_TIME=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.insertTime,jdbcType=TIMESTAMP}
- </foreach>
- ,UPDATE_USERNAME=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.updateUsername,jdbcType=VARCHAR}
- </foreach>
- ,UPDATE_TIME=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.updateTime,jdbcType=TIMESTAMP}
- </foreach>
- ,INSERT_UPDATE_REMARK=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.insertUpdateRemark,jdbcType=VARCHAR}
- </foreach>
- ,CAPACITY_CORLOR=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityCorlor,jdbcType=VARCHAR}
- </foreach>
- ,CAPACITY_VIP=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.capacityVip,jdbcType=VARCHAR}
- </foreach>
- ,DELETED=
- <foreach close="end" collection="list" index="index" item="item" open="case CAPACITY_ID" separator=" ">
- when #{item.capacityId,jdbcType=DECIMAL} then #{item.deleted,jdbcType=DECIMAL}
- </foreach>
- where CAPACITY_ID in
- <foreach close=")" collection="list" index="index" item="item" open="(" separator=",">
- #{item.capacityId,jdbcType=DECIMAL}
- </foreach>
- </update>
- <delete id="batchDelete" parameterType="java.util.List">
- delete from RMS_CAPACITY
- where CAPACITY_ID in
- <foreach close=")" collection="list" item="id" open="(" separator=",">
- #{id}
- </foreach>
- </delete>
- <!-- 友情提示!!!-->
- <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
- <select id="getCapacityList" parameterType="java.util.Map" resultType="java.util.Map">
- SELECT * FROM
- (
- SELECT
- RC.CAPACITY_ID AS "capacityId",
- RCT.CAPACITY_TYPE_NAME AS "capacityTypeName",
- RC.CAPACITY_NUMBER AS "capacityNumber",
- RC.CAPACITY_CORLOR AS "capacityCorlor",
- RC.CAPACITY_OWNERIS AS "capacityOwneris",
- RC.CAPACITY_VIP AS "capacityVip",
- RC.CAPACITY_BLACKLIST AS "capacityBlacklist",
- RCA.CARRIER_NAME AS "carrierName"
- FROM RMS_CAPACITY RC
- LEFT JOIN
- RMS_CAPACITY_TYPE RCT
- ON RC.CAPACITY_TYPE_ID=RCT.CAPACITY_TYPE_ID
- LEFT JOIN
- RMS_CARRIER RCA
- ON RCA.CARRIER_ID=RC.CARRIER_ID
- WHERE RC.DELETED!=1
- ORDER BY RC.INSERT_TIME DESC
- )
- <where>
- <if test="capacityId!= null">
- and
- <foreach collection="capacityId" item="item" open="(" separator="," close=")">
- "capacityId" in #{item}
- </foreach>
- </if>
- <if test="capacityTypeName!= null">
- and
- <foreach collection="capacityTypeName" item="item" open="(" separator="," close=")">
- "capacityTypeName" in #{item}
- </foreach>
- </if>
- <if test="capacityNumber!= null">
- and
- <foreach collection="capacityNumber" item="item" open="(" separator="," close=")">
- "capacityNumber" in #{item}
- </foreach>
- </if>
- <if test="capacityCorlor!= null">
- and
- <foreach collection="capacityCorlor" item="item" open="(" separator="," close=")">
- "capacityCorlor" in #{item}
- </foreach>
- </if>
- <if test="capacityOwneris!= null">
- and
- <foreach collection="capacityOwneris" item="item" open="(" separator="," close=")">
- "capacityOwneris" in #{item}
- </foreach>
- </if>
- <if test="capacityVip!= null">
- and
- <foreach collection="capacityVip" item="item" open="(" separator="," close=")">
- "capacityVip" in #{item}
- </foreach>
- </if>
- <if test="capacityBlacklist!= null">
- and
- <foreach collection="capacityBlacklist" item="item" open="(" separator="," close=")">
- "capacityBlacklist" in #{item}
- </foreach>
- </if>
- <if test="carrierName!= null">
- and
- <foreach collection="carrierName" item="item" open="(" separator="," close=")">
- "carrierName" in #{item}
- </foreach>
- </if>
- </where>
- </select>
- <select id="getCapacityById" resultType="java.util.LinkedHashMap" >
- SELECT
- RC.CAPACITY_ID AS "capacityId",
- RC.CAPACITY_TYPE_ID AS "capacityTypeId",
- RC.CAPACITY_NUMBER AS "capacityNumber",
- RC.CAPACITY_CORLOR AS "capacityCorlor",
- RC.CAPACITY_OWNERIS AS "capacityOwneris",
- RC.CAPACITY_VIP AS "capacityVip",
- RC.CAPACITY_BLACKLIST AS "capacityBlacklist",
- RC.CARRIER_ID AS "carrierId"
- FROM RMS_CAPACITY RC
- WHERE RC.CAPACITY_ID=#{id}
- </select>
- <select id="getCapacityTypeId" resultType="java.util.LinkedHashMap">
- SELECT
- RCT.CAPACITY_TYPE_ID AS "id",
- RCT.CAPACITY_TYPE_ID AS "value",
- RCT.CAPACITY_TYPE_NAME AS "label"
- FROM RMS_CAPACITY_TYPE RCT
- </select>
- <select id="getCarrierId" resultType="java.util.LinkedHashMap">
- SELECT
- RC.CARRIER_ID AS "id",
- RC.CARRIER_ID AS "value",
- RC.CARRIER_NAME AS "label"
- FROM RMS_CARRIER RC
- WHERE RC.DELETED!=1
- </select>
- </mapper>
|