69 lines
4.6 KiB
XML
69 lines
4.6 KiB
XML
<?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.xdadan.erp.oms.mapper.EmisWarehouseInMapper">
|
|
|
|
<resultMap type="EmisWarehouseIn" id="EmisWarehouseInResult" extends="com.xdadan.erp.oms.mapper.EmisBaseMapper.EmisBaseResult">
|
|
<result property="id" column="id" />
|
|
<result property="serialNo" column="serial_no" />
|
|
<result property="inNo" column="in_no" />
|
|
<result property="orderSn" column="order_sn" />
|
|
<result property="billCode" column="bill_code" />
|
|
<result property="customerCode" column="customer_code" />
|
|
<result property="customerName" column="customer_name" />
|
|
<result property="entryDate" column="entry_date" />
|
|
<result property="confirmStatus" column="confirm_status" />
|
|
<result property="confirmDate" column="confirm_date" />
|
|
<result property="usedStatus" column="used_status" />
|
|
<result property="status" column="status" />
|
|
|
|
</resultMap>
|
|
|
|
<sql id="selectEmisWarehouseInVo">
|
|
select id, serial_no, in_no, order_sn, bill_code, customer_code, customer_name, entry_date, confirm_status, confirm_date, used_status, status, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site from emis_warehouse_in
|
|
</sql>
|
|
|
|
<select id="selectEmisWarehouseInList" parameterType="EmisWarehouseIn" resultMap="EmisWarehouseInResult">
|
|
<include refid="selectEmisWarehouseInVo"/>
|
|
<where>
|
|
del_flag='0'
|
|
<if test="id != null "> and id = #{id}</if>
|
|
<if test="serialNo != null and serialNo != ''"> and serial_no like concat('%', #{serialNo}, '%')</if>
|
|
<if test="inNo != null and inNo != ''"> and in_no like concat('%', #{inNo}, '%')</if>
|
|
<if test="orderSn != null and orderSn != ''"> and order_sn like concat('%', #{orderSn}, '%')</if>
|
|
<if test="billCode != null and billCode != ''"> and bill_code like concat('%', #{billCode}, '%')</if>
|
|
<if test="customerCode != null and customerCode != ''"> and customer_code like concat('%', #{customerCode}, '%')</if>
|
|
<if test="customerName != null and customerName != ''"> and customer_name like concat('%', #{customerName}, '%')</if>
|
|
<if test="entryDate != null "> and entry_date = #{entryDate}</if>
|
|
<if test="confirmStatus != null and confirmStatus != ''"> and confirm_status like concat('%', #{confirmStatus}, '%')</if>
|
|
<if test="confirmDate != null "> and confirm_date = #{confirmDate}</if>
|
|
<if test="usedStatus != null and usedStatus != ''"> and used_status like concat('%', #{usedStatus}, '%')</if>
|
|
<if test="status != null and status != ''"> and status like concat('%', #{status}, '%')</if>
|
|
<if test="remark != null and remark != ''"> and remark like concat('%', #{remark}, '%')</if>
|
|
<if test="tenantId != null and tenantId != ''"> and tenant_id like concat('%', #{tenantId}, '%')</if>
|
|
<if test="delFlag != null and delFlag != ''"> and del_flag like concat('%', #{delFlag}, '%')</if>
|
|
<if test="createBy != null and createBy != ''"> and create_by like concat('%', #{createBy}, '%')</if>
|
|
<if test="createTime != null "> and create_time = #{createTime}</if>
|
|
<if test="updateBy != null and updateBy != ''"> and update_by like concat('%', #{updateBy}, '%')</if>
|
|
<if test="updateTime != null "> and update_time = #{updateTime}</if>
|
|
<if test="createSite != null and createSite != ''"> and create_site like concat('%', #{createSite}, '%')</if>
|
|
<if test="updateSite != null and updateSite != ''"> and update_site like concat('%', #{updateSite}, '%')</if>
|
|
</where>
|
|
order by create_time desc
|
|
</select>
|
|
|
|
<select id="selectEmisWarehouseInById" parameterType="Long" resultMap="EmisWarehouseInResult">
|
|
select id, serial_no, in_no, order_sn, bill_code, customer_code, customer_name, entry_date, confirm_status, confirm_date, used_status, status, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site
|
|
from emis_warehouse_in a
|
|
where a.id = #{id}
|
|
</select>
|
|
|
|
|
|
|
|
<update id="cusConfirmWsIn" parameterType="EmisWarehouseIn">
|
|
update emis_warehouse_in set confirm_status=#{confirmStatus},confirm_date=now()
|
|
where in_no = #{inNo} and customer_code = #{customerCode}
|
|
</update>
|
|
|
|
</mapper> |