|
|
@ -23,6 +23,8 @@
|
|
|
|
<result property="updatedTime" column="updated_time" />
|
|
|
|
<result property="updatedTime" column="updated_time" />
|
|
|
|
<result property="incrementDate" column="increment_date" />
|
|
|
|
<result property="incrementDate" column="increment_date" />
|
|
|
|
<result property="DISPO" column="DISPO" />
|
|
|
|
<result property="DISPO" column="DISPO" />
|
|
|
|
|
|
|
|
<result property="productCode" column="product_code" />
|
|
|
|
|
|
|
|
<result property="productName" column="product_name" />
|
|
|
|
</resultMap>
|
|
|
|
</resultMap>
|
|
|
|
|
|
|
|
|
|
|
|
<sql id="selectBaseMaterialInfoVo">
|
|
|
|
<sql id="selectBaseMaterialInfoVo">
|
|
|
@ -45,7 +47,9 @@
|
|
|
|
ml.created_by,
|
|
|
|
ml.created_by,
|
|
|
|
ml.created_time,
|
|
|
|
ml.created_time,
|
|
|
|
ml.updated_by,
|
|
|
|
ml.updated_by,
|
|
|
|
ml.updated_time
|
|
|
|
ml.updated_time,
|
|
|
|
|
|
|
|
ml.product_code,
|
|
|
|
|
|
|
|
ml.product_name
|
|
|
|
from base_materialinfo ml
|
|
|
|
from base_materialinfo ml
|
|
|
|
left join base_factory bf on bf.factory_code = ml.plant_code
|
|
|
|
left join base_factory bf on bf.factory_code = ml.plant_code
|
|
|
|
left join base_productline bpl on bpl.PRODUCT_LINE_CODE = ml.productline_code
|
|
|
|
left join base_productline bpl on bpl.PRODUCT_LINE_CODE = ml.productline_code
|
|
|
@ -69,6 +73,8 @@
|
|
|
|
<if test="createdTime != null "> and ml.created_time = #{createdTime}</if>
|
|
|
|
<if test="createdTime != null "> and ml.created_time = #{createdTime}</if>
|
|
|
|
<if test="updatedBy != null and updatedBy != ''"> and ml.updated_by = #{updatedBy}</if>
|
|
|
|
<if test="updatedBy != null and updatedBy != ''"> and ml.updated_by = #{updatedBy}</if>
|
|
|
|
<if test="updatedTime != null "> and ml.updated_time = #{updatedTime}</if>
|
|
|
|
<if test="updatedTime != null "> and ml.updated_time = #{updatedTime}</if>
|
|
|
|
|
|
|
|
<if test="productCode != null and productCode != ''"> and ml.product_code = #{productCode}</if>
|
|
|
|
|
|
|
|
<if test="productName != null and productName != ''"> and ml.product_name = #{productName}</if>
|
|
|
|
</where>
|
|
|
|
</where>
|
|
|
|
order by ml.material_subclass, ml.increment_date desc
|
|
|
|
order by ml.material_subclass, ml.increment_date desc
|
|
|
|
</select>
|
|
|
|
</select>
|
|
|
@ -102,6 +108,8 @@
|
|
|
|
<if test="updatedBy != null">updated_by,</if>
|
|
|
|
<if test="updatedBy != null">updated_by,</if>
|
|
|
|
<if test="updatedTime != null">updated_time,</if>
|
|
|
|
<if test="updatedTime != null">updated_time,</if>
|
|
|
|
<if test="DISPO != null">DISPO,</if>
|
|
|
|
<if test="DISPO != null">DISPO,</if>
|
|
|
|
|
|
|
|
<if test="productCode != null">product_code,</if>
|
|
|
|
|
|
|
|
<if test="productName != null">product_name,</if>
|
|
|
|
</trim>
|
|
|
|
</trim>
|
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
<if test="objId != null">#{objId},</if>
|
|
|
|
<if test="objId != null">#{objId},</if>
|
|
|
@ -122,6 +130,8 @@
|
|
|
|
<if test="updatedBy != null">#{updatedBy},</if>
|
|
|
|
<if test="updatedBy != null">#{updatedBy},</if>
|
|
|
|
<if test="updatedTime != null">#{updatedTime},</if>
|
|
|
|
<if test="updatedTime != null">#{updatedTime},</if>
|
|
|
|
<if test="DISPO != null">#{DISPO},</if>
|
|
|
|
<if test="DISPO != null">#{DISPO},</if>
|
|
|
|
|
|
|
|
<if test="productCode != null">#{productCode},</if>
|
|
|
|
|
|
|
|
<if test="productName != null">#{productName},</if>
|
|
|
|
</trim>
|
|
|
|
</trim>
|
|
|
|
</insert>
|
|
|
|
</insert>
|
|
|
|
|
|
|
|
|
|
|
@ -145,6 +155,8 @@
|
|
|
|
<if test="updatedBy != null">updated_by = #{updatedBy},</if>
|
|
|
|
<if test="updatedBy != null">updated_by = #{updatedBy},</if>
|
|
|
|
<if test="updatedTime != null">updated_time = #{updatedTime},</if>
|
|
|
|
<if test="updatedTime != null">updated_time = #{updatedTime},</if>
|
|
|
|
<if test="DISPO != null">DISPO = #{DISPO},</if>
|
|
|
|
<if test="DISPO != null">DISPO = #{DISPO},</if>
|
|
|
|
|
|
|
|
<if test="productCode != null">product_code = #{productCode},</if>
|
|
|
|
|
|
|
|
<if test="productName != null">product_name = #{productName},</if>
|
|
|
|
</trim>
|
|
|
|
</trim>
|
|
|
|
where obj_id = #{objId}
|
|
|
|
where obj_id = #{objId}
|
|
|
|
</update>
|
|
|
|
</update>
|
|
|
|