|
@@ -0,0 +1,579 @@
|
|
|
|
+<?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.BmsshipFeeMapper">
|
|
|
|
+ <resultMap id="BaseResultMap" type="com.steerinfo.dil.model.BmsshipFee">
|
|
|
|
+ <id column="RESULT_ID" jdbcType="DECIMAL" property="resultId" />
|
|
|
|
+ <result column="FEE" jdbcType="DECIMAL" property="fee" />
|
|
|
|
+ <result column="FEE_TYPE" jdbcType="DECIMAL" property="feeType" />
|
|
|
|
+ <result column="PURCHASE_ORDER_ID" jdbcType="DECIMAL" property="purchaseOrderId" />
|
|
|
|
+ <result column="BATCH_ID" jdbcType="DECIMAL" property="batchId" />
|
|
|
|
+ <result column="REAL_TONNAGE" jdbcType="DECIMAL" property="realTonnage" />
|
|
|
|
+ <result column="UNIT_PRICE" jdbcType="DECIMAL" property="unitPrice" />
|
|
|
|
+ <result column="UNIT_PRICE_ID" jdbcType="DECIMAL" property="unitPriceId" />
|
|
|
|
+ <result column="RESULT_REMARKS" jdbcType="VARCHAR" property="resultRemarks" />
|
|
|
|
+ <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="DELETED" jdbcType="DECIMAL" property="deleted" />
|
|
|
|
+ <result column="IMAGE" jdbcType="VARCHAR" property="image" />
|
|
|
|
+ <result column="WAGON_NUMBER" jdbcType="DECIMAL" property="wagonNumber" />
|
|
|
|
+ <result column="MAKE_TIME" jdbcType="TIMESTAMP" property="makeTime" />
|
|
|
|
+ <result column="PORT_ID" jdbcType="DECIMAL" property="portId" />
|
|
|
|
+ </resultMap>
|
|
|
|
+ <sql id="columns">
|
|
|
|
+ RESULT_ID, FEE, FEE_TYPE, PURCHASE_ORDER_ID, BATCH_ID, REAL_TONNAGE, UNIT_PRICE,
|
|
|
|
+ UNIT_PRICE_ID, RESULT_REMARKS, INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME,
|
|
|
|
+ INSERT_UPDATE_REMARK, DELETED, IMAGE, WAGON_NUMBER, MAKE_TIME, PORT_ID
|
|
|
|
+ </sql>
|
|
|
|
+ <sql id="columns_alias">
|
|
|
|
+ t.RESULT_ID, t.FEE, t.FEE_TYPE, t.PURCHASE_ORDER_ID, t.BATCH_ID, t.REAL_TONNAGE,
|
|
|
|
+ t.UNIT_PRICE, t.UNIT_PRICE_ID, t.RESULT_REMARKS, t.INSERT_USERNAME, t.INSERT_TIME,
|
|
|
|
+ t.UPDATE_USERNAME, t.UPDATE_TIME, t.INSERT_UPDATE_REMARK, t.DELETED, t.IMAGE, t.WAGON_NUMBER,
|
|
|
|
+ t.MAKE_TIME, t.PORT_ID
|
|
|
|
+ </sql>
|
|
|
|
+ <sql id="select">
|
|
|
|
+ SELECT <include refid="columns"/> FROM BMSSHIP_FEE
|
|
|
|
+ </sql>
|
|
|
|
+ <sql id="select_alias">
|
|
|
|
+ SELECT <include refid="columns_alias"/> FROM BMSSHIP_FEE t
|
|
|
|
+ </sql>
|
|
|
|
+ <sql id="where">
|
|
|
|
+ <where>
|
|
|
|
+ <if test="resultId != null">
|
|
|
|
+ and RESULT_ID = #{resultId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fee != null">
|
|
|
|
+ and FEE = #{fee}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="feeType != null">
|
|
|
|
+ and FEE_TYPE = #{feeType}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="purchaseOrderId != null">
|
|
|
|
+ and PURCHASE_ORDER_ID = #{purchaseOrderId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="batchId != null">
|
|
|
|
+ and BATCH_ID = #{batchId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="realTonnage != null">
|
|
|
|
+ and REAL_TONNAGE = #{realTonnage}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPrice != null">
|
|
|
|
+ and UNIT_PRICE = #{unitPrice}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPriceId != null">
|
|
|
|
+ and UNIT_PRICE_ID = #{unitPriceId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="resultRemarks != null and resultRemarks != ''">
|
|
|
|
+ and RESULT_REMARKS = #{resultRemarks}
|
|
|
|
+ </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="deleted != null">
|
|
|
|
+ and DELETED = #{deleted}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="image != null and image != ''">
|
|
|
|
+ and IMAGE = #{image}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="wagonNumber != null">
|
|
|
|
+ and WAGON_NUMBER = #{wagonNumber}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="makeTime != null">
|
|
|
|
+ and TO_CHAR(MAKE_TIME,'yyyy-MM-dd') = #{makeTime}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="portId != null">
|
|
|
|
+ and PORT_ID = #{portId}
|
|
|
|
+ </if>
|
|
|
|
+ </where>
|
|
|
|
+ </sql>
|
|
|
|
+ <sql id="whereLike">
|
|
|
|
+ <where>
|
|
|
|
+ <if test="resultId != null">
|
|
|
|
+ and RESULT_ID = #{resultId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fee != null">
|
|
|
|
+ and FEE = #{fee}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="feeType != null">
|
|
|
|
+ and FEE_TYPE = #{feeType}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="purchaseOrderId != null">
|
|
|
|
+ and PURCHASE_ORDER_ID = #{purchaseOrderId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="batchId != null">
|
|
|
|
+ and BATCH_ID = #{batchId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="realTonnage != null">
|
|
|
|
+ and REAL_TONNAGE = #{realTonnage}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPrice != null">
|
|
|
|
+ and UNIT_PRICE = #{unitPrice}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPriceId != null">
|
|
|
|
+ and UNIT_PRICE_ID = #{unitPriceId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="resultRemarks != null and resultRemarks != ''">
|
|
|
|
+ and RESULT_REMARKS LIKE '%${resultRemarks}%'
|
|
|
|
+ </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="deleted != null">
|
|
|
|
+ and DELETED = #{deleted}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="image != null and image != ''">
|
|
|
|
+ and IMAGE LIKE '%${image}%'
|
|
|
|
+ </if>
|
|
|
|
+ <if test="wagonNumber != null">
|
|
|
|
+ and WAGON_NUMBER = #{wagonNumber}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="makeTime != null">
|
|
|
|
+ and TO_CHAR(MAKE_TIME,'yyyy-MM-dd') = #{makeTime}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="portId != null">
|
|
|
|
+ and PORT_ID = #{portId}
|
|
|
|
+ </if>
|
|
|
|
+ </where>
|
|
|
|
+ </sql>
|
|
|
|
+ <delete id="deleteByPrimaryKey" parameterType="java.math.BigDecimal">
|
|
|
|
+ delete from BMSSHIP_FEE
|
|
|
|
+ where RESULT_ID = #{resultId,jdbcType=DECIMAL}
|
|
|
|
+ </delete>
|
|
|
|
+ <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
|
|
|
|
+ delete from BMSSHIP_FEE
|
|
|
|
+ where 1!=1
|
|
|
|
+ <if test="fee != null">
|
|
|
|
+ or FEE = #{fee}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="feeType != null">
|
|
|
|
+ or FEE_TYPE = #{feeType}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="purchaseOrderId != null">
|
|
|
|
+ or PURCHASE_ORDER_ID = #{purchaseOrderId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="batchId != null">
|
|
|
|
+ or BATCH_ID = #{batchId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="realTonnage != null">
|
|
|
|
+ or REAL_TONNAGE = #{realTonnage}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPrice != null">
|
|
|
|
+ or UNIT_PRICE = #{unitPrice}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPriceId != null">
|
|
|
|
+ or UNIT_PRICE_ID = #{unitPriceId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="resultRemarks != null and resultRemarks != ''">
|
|
|
|
+ or RESULT_REMARKS = #{resultRemarks}
|
|
|
|
+ </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="deleted != null">
|
|
|
|
+ or DELETED = #{deleted}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="image != null and image != ''">
|
|
|
|
+ or IMAGE = #{image}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="wagonNumber != null">
|
|
|
|
+ or WAGON_NUMBER = #{wagonNumber}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="makeTime != null">
|
|
|
|
+ or TO_CHAR(MAKE_TIME,'yyyy-MM-dd') = '#{makeTime}'
|
|
|
|
+ </if>
|
|
|
|
+ <if test="portId != null">
|
|
|
|
+ or PORT_ID = #{portId}
|
|
|
|
+ </if>
|
|
|
|
+ </delete>
|
|
|
|
+ <insert id="insert" parameterType="com.steerinfo.dil.model.BmsshipFee">
|
|
|
|
+ insert into BMSSHIP_FEE (RESULT_ID, FEE, FEE_TYPE,
|
|
|
|
+ PURCHASE_ORDER_ID, BATCH_ID, REAL_TONNAGE,
|
|
|
|
+ UNIT_PRICE, UNIT_PRICE_ID, RESULT_REMARKS,
|
|
|
|
+ INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME,
|
|
|
|
+ UPDATE_TIME, INSERT_UPDATE_REMARK, DELETED,
|
|
|
|
+ IMAGE, WAGON_NUMBER, MAKE_TIME,
|
|
|
|
+ PORT_ID)
|
|
|
|
+ values (#{resultId,jdbcType=DECIMAL}, #{fee,jdbcType=DECIMAL}, #{feeType,jdbcType=DECIMAL},
|
|
|
|
+ #{purchaseOrderId,jdbcType=DECIMAL}, #{batchId,jdbcType=DECIMAL}, #{realTonnage,jdbcType=DECIMAL},
|
|
|
|
+ #{unitPrice,jdbcType=DECIMAL}, #{unitPriceId,jdbcType=DECIMAL}, #{resultRemarks,jdbcType=VARCHAR},
|
|
|
|
+ #{insertUsername,jdbcType=VARCHAR}, #{insertTime,jdbcType=TIMESTAMP}, #{updateUsername,jdbcType=VARCHAR},
|
|
|
|
+ #{updateTime,jdbcType=TIMESTAMP}, #{insertUpdateRemark,jdbcType=VARCHAR}, #{deleted,jdbcType=DECIMAL},
|
|
|
|
+ #{image,jdbcType=VARCHAR}, #{wagonNumber,jdbcType=DECIMAL}, #{makeTime,jdbcType=TIMESTAMP},
|
|
|
|
+ #{portId,jdbcType=DECIMAL})
|
|
|
|
+ </insert>
|
|
|
|
+ <insert id="insertSelective" parameterType="com.steerinfo.dil.model.BmsshipFee">
|
|
|
|
+ insert into BMSSHIP_FEE
|
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
|
+ <if test="resultId != null">
|
|
|
|
+ RESULT_ID,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fee != null">
|
|
|
|
+ FEE,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="feeType != null">
|
|
|
|
+ FEE_TYPE,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="purchaseOrderId != null">
|
|
|
|
+ PURCHASE_ORDER_ID,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="batchId != null">
|
|
|
|
+ BATCH_ID,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="realTonnage != null">
|
|
|
|
+ REAL_TONNAGE,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPrice != null">
|
|
|
|
+ UNIT_PRICE,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPriceId != null">
|
|
|
|
+ UNIT_PRICE_ID,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="resultRemarks != null">
|
|
|
|
+ RESULT_REMARKS,
|
|
|
|
+ </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="deleted != null">
|
|
|
|
+ DELETED,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="image != null">
|
|
|
|
+ IMAGE,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="wagonNumber != null">
|
|
|
|
+ WAGON_NUMBER,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="makeTime != null">
|
|
|
|
+ MAKE_TIME,
|
|
|
|
+ </if>
|
|
|
|
+ <if test="portId != null">
|
|
|
|
+ PORT_ID,
|
|
|
|
+ </if>
|
|
|
|
+ </trim>
|
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
+ <if test="resultId != null">
|
|
|
|
+ #{resultId,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fee != null">
|
|
|
|
+ #{fee,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="feeType != null">
|
|
|
|
+ #{feeType,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="purchaseOrderId != null">
|
|
|
|
+ #{purchaseOrderId,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="batchId != null">
|
|
|
|
+ #{batchId,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="realTonnage != null">
|
|
|
|
+ #{realTonnage,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPrice != null">
|
|
|
|
+ #{unitPrice,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPriceId != null">
|
|
|
|
+ #{unitPriceId,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="resultRemarks != null">
|
|
|
|
+ #{resultRemarks,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="deleted != null">
|
|
|
|
+ #{deleted,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="image != null">
|
|
|
|
+ #{image,jdbcType=VARCHAR},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="wagonNumber != null">
|
|
|
|
+ #{wagonNumber,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="makeTime != null">
|
|
|
|
+ #{makeTime,jdbcType=TIMESTAMP},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="portId != null">
|
|
|
|
+ #{portId,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ </trim>
|
|
|
|
+ </insert>
|
|
|
|
+ <update id="updateByPrimaryKey" parameterType="com.steerinfo.dil.model.BmsshipFee">
|
|
|
|
+ update BMSSHIP_FEE
|
|
|
|
+ set FEE = #{fee,jdbcType=DECIMAL},
|
|
|
|
+ FEE_TYPE = #{feeType,jdbcType=DECIMAL},
|
|
|
|
+ PURCHASE_ORDER_ID = #{purchaseOrderId,jdbcType=DECIMAL},
|
|
|
|
+ BATCH_ID = #{batchId,jdbcType=DECIMAL},
|
|
|
|
+ REAL_TONNAGE = #{realTonnage,jdbcType=DECIMAL},
|
|
|
|
+ UNIT_PRICE = #{unitPrice,jdbcType=DECIMAL},
|
|
|
|
+ UNIT_PRICE_ID = #{unitPriceId,jdbcType=DECIMAL},
|
|
|
|
+ RESULT_REMARKS = #{resultRemarks,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},
|
|
|
|
+ DELETED = #{deleted,jdbcType=DECIMAL},
|
|
|
|
+ IMAGE = #{image,jdbcType=VARCHAR},
|
|
|
|
+ WAGON_NUMBER = #{wagonNumber,jdbcType=DECIMAL},
|
|
|
|
+ MAKE_TIME = #{makeTime,jdbcType=TIMESTAMP},
|
|
|
|
+ PORT_ID = #{portId,jdbcType=DECIMAL}
|
|
|
|
+ where RESULT_ID = #{resultId,jdbcType=DECIMAL}
|
|
|
|
+ </update>
|
|
|
|
+ <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.dil.model.BmsshipFee">
|
|
|
|
+ update BMSSHIP_FEE
|
|
|
|
+ <set>
|
|
|
|
+ <if test="fee != null">
|
|
|
|
+ FEE = #{fee,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="feeType != null">
|
|
|
|
+ FEE_TYPE = #{feeType,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="purchaseOrderId != null">
|
|
|
|
+ PURCHASE_ORDER_ID = #{purchaseOrderId,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="batchId != null">
|
|
|
|
+ BATCH_ID = #{batchId,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="realTonnage != null">
|
|
|
|
+ REAL_TONNAGE = #{realTonnage,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPrice != null">
|
|
|
|
+ UNIT_PRICE = #{unitPrice,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="unitPriceId != null">
|
|
|
|
+ UNIT_PRICE_ID = #{unitPriceId,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="resultRemarks != null">
|
|
|
|
+ RESULT_REMARKS = #{resultRemarks,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="deleted != null">
|
|
|
|
+ DELETED = #{deleted,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="image != null">
|
|
|
|
+ IMAGE = #{image,jdbcType=VARCHAR},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="wagonNumber != null">
|
|
|
|
+ WAGON_NUMBER = #{wagonNumber,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="makeTime != null">
|
|
|
|
+ MAKE_TIME = #{makeTime,jdbcType=TIMESTAMP},
|
|
|
|
+ </if>
|
|
|
|
+ <if test="portId != null">
|
|
|
|
+ PORT_ID = #{portId,jdbcType=DECIMAL},
|
|
|
|
+ </if>
|
|
|
|
+ </set>
|
|
|
|
+ where RESULT_ID = #{resultId,jdbcType=DECIMAL}
|
|
|
|
+ </update>
|
|
|
|
+ <select id="selectByPrimaryKey" parameterType="java.math.BigDecimal" resultMap="BaseResultMap">
|
|
|
|
+ <include refid="select"/>
|
|
|
|
+ where RESULT_ID = #{resultId,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 BMSSHIP_FEE
|
|
|
|
+ (RESULT_ID,
|
|
|
|
+ FEE, FEE_TYPE, PURCHASE_ORDER_ID,
|
|
|
|
+ BATCH_ID, REAL_TONNAGE, UNIT_PRICE,
|
|
|
|
+ UNIT_PRICE_ID, RESULT_REMARKS, INSERT_USERNAME,
|
|
|
|
+ INSERT_TIME, UPDATE_USERNAME,
|
|
|
|
+ UPDATE_TIME, INSERT_UPDATE_REMARK,
|
|
|
|
+ DELETED, IMAGE, WAGON_NUMBER,
|
|
|
|
+ MAKE_TIME, PORT_ID)
|
|
|
|
+ ( <foreach collection="list" item="item" separator="union all">
|
|
|
|
+ select
|
|
|
|
+ #{item.resultId,jdbcType=DECIMAL},
|
|
|
|
+ #{item.fee,jdbcType=DECIMAL}, #{item.feeType,jdbcType=DECIMAL}, #{item.purchaseOrderId,jdbcType=DECIMAL},
|
|
|
|
+ #{item.batchId,jdbcType=DECIMAL}, #{item.realTonnage,jdbcType=DECIMAL}, #{item.unitPrice,jdbcType=DECIMAL},
|
|
|
|
+ #{item.unitPriceId,jdbcType=DECIMAL}, #{item.resultRemarks,jdbcType=VARCHAR}, #{item.insertUsername,jdbcType=VARCHAR},
|
|
|
|
+ #{item.insertTime,jdbcType=TIMESTAMP}, #{item.updateUsername,jdbcType=VARCHAR},
|
|
|
|
+ #{item.updateTime,jdbcType=TIMESTAMP}, #{item.insertUpdateRemark,jdbcType=VARCHAR},
|
|
|
|
+ #{item.deleted,jdbcType=DECIMAL}, #{item.image,jdbcType=VARCHAR}, #{item.wagonNumber,jdbcType=DECIMAL},
|
|
|
|
+ #{item.makeTime,jdbcType=TIMESTAMP}, #{item.portId,jdbcType=DECIMAL} from dual
|
|
|
|
+ </foreach> )
|
|
|
|
+ </insert>
|
|
|
|
+ <update id="batchUpdate" parameterType="java.util.List">
|
|
|
|
+ update BMSSHIP_FEE
|
|
|
|
+ set
|
|
|
|
+ RESULT_ID=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.resultId,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,FEE=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.fee,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,FEE_TYPE=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.feeType,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,PURCHASE_ORDER_ID=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.purchaseOrderId,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,BATCH_ID=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.batchId,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,REAL_TONNAGE=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.realTonnage,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,UNIT_PRICE=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.unitPrice,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,UNIT_PRICE_ID=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.unitPriceId,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,RESULT_REMARKS=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.resultRemarks,jdbcType=VARCHAR}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,INSERT_USERNAME=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.insertUsername,jdbcType=VARCHAR}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,INSERT_TIME=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.insertTime,jdbcType=TIMESTAMP}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,UPDATE_USERNAME=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.updateUsername,jdbcType=VARCHAR}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,UPDATE_TIME=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.updateTime,jdbcType=TIMESTAMP}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,INSERT_UPDATE_REMARK=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.insertUpdateRemark,jdbcType=VARCHAR}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,DELETED=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.deleted,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,IMAGE=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.image,jdbcType=VARCHAR}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,WAGON_NUMBER=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.wagonNumber,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,MAKE_TIME=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.makeTime,jdbcType=TIMESTAMP}
|
|
|
|
+ </foreach>
|
|
|
|
+ ,PORT_ID=
|
|
|
|
+ <foreach collection="list" item="item" index="index" separator=" " open="case RESULT_ID" close="end">
|
|
|
|
+ when #{item.resultId,jdbcType=DECIMAL} then #{item.portId,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ where RESULT_ID in
|
|
|
|
+ <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
|
|
|
|
+ #{item.resultId,jdbcType=DECIMAL}
|
|
|
|
+ </foreach>
|
|
|
|
+ </update>
|
|
|
|
+ <delete id="batchDelete" parameterType="java.util.List">
|
|
|
|
+ delete from BMSSHIP_FEE
|
|
|
|
+ where RESULT_ID in
|
|
|
|
+ <foreach collection="list" item="id" open="(" close=")" separator=",">
|
|
|
|
+ #{id}
|
|
|
|
+ </foreach>
|
|
|
|
+ </delete>
|
|
|
|
+ <!-- 友情提示!!!-->
|
|
|
|
+ <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
|
|
|
|
+ <!-- 根据userId查找用户名-->
|
|
|
|
+ <select id="getPersonnelNameByUserId" resultType="java.lang.String" parameterType="java.lang.String">
|
|
|
|
+ select RP.PERSONNEL_NAME "personnelName"
|
|
|
|
+ from RMS_PERSONNEL RP
|
|
|
|
+ WHERE RP.PERSONNEL_SSO_ID =#{userId}
|
|
|
|
+ </select>
|
|
|
|
+
|
|
|
|
+</mapper>
|