43 lines
2.0 KiB
XML
43 lines
2.0 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.nflg.wms.repository.mapper.WmsInCostcenterBackTicketMapper">
|
|
|
|
<select id="getInfo" resultType="com.nflg.wms.common.pojo.vo.InCostcenterBackInfoVO">
|
|
SELECT icbt.id,icbt."no" AS "ticket_no",icbt.create_by,icbt.create_time,icbt.lgort,icb.*
|
|
FROM wms_in_costcenter_back_ticket icbt
|
|
INNER JOIN wms_in_costcenter_back icb ON icbt.order_id=icb."id"
|
|
WHERE icbt."id"=#{id}
|
|
</select>
|
|
|
|
<select id="search" resultType="com.nflg.wms.common.pojo.vo.InCostcenterBackVO">
|
|
SELECT icbt.id,icbt."no" AS "ticket_no",icbt.create_by,icbt.create_time,icbt.mat_doc,icbt.doc_year,icbt.lgort
|
|
,icb.*
|
|
FROM wms_in_costcenter_back_ticket icbt
|
|
INNER JOIN wms_in_costcenter_back icb ON icbt.order_id=icb."id"
|
|
<where>
|
|
<if test="request.startDate!=null">
|
|
and icbt.create_time >= #{request.startDate}
|
|
</if>
|
|
<if test="request.endDate!=null">
|
|
and icbt.create_time <= #{request.endDate}
|
|
</if>
|
|
<if test="request.no != null and request.no!=''">
|
|
AND icb."no" ilike CONCAT('%',#{request.no},'%')
|
|
</if>
|
|
<if test="request.aufnr != null and request.aufnr!=''">
|
|
AND icb."aufnr" ilike CONCAT('%',#{request.aufnr},'%')
|
|
</if>
|
|
<if test="request.werks != null and request.werks!=''">
|
|
AND icb."werks" ilike CONCAT('%',#{request.werks},'%')
|
|
</if>
|
|
<if test="request.rsnum != null and request.rsnum!=''">
|
|
AND icb."rsnum" ilike CONCAT('%',#{request.rsnum},'%')
|
|
</if>
|
|
<if test="request.kostl != null and request.kostl!=''">
|
|
AND icb."kostl" ilike CONCAT('%',#{request.kostl},'%')
|
|
</if>
|
|
</where>
|
|
order by icbt.id desc
|
|
</select>
|
|
</mapper>
|