2025-07-25 15:09:12 +08:00
|
|
|
<?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.WmsSrmQualityInspectionMapper">
|
2025-07-28 09:36:00 +08:00
|
|
|
<select id="search" resultType="com.nflg.wms.common.pojo.vo.QualityInspectionVO">
|
|
|
|
|
<!-- SELECT DISTINCT ON ("no") *-->
|
|
|
|
|
<!-- FROM wms_material-->
|
|
|
|
|
<!-- <where>-->
|
|
|
|
|
<!-- <if test="request.no!=null and request.no!=''">-->
|
|
|
|
|
<!-- and "no" like concat('%', #{request.no}, '%')-->
|
|
|
|
|
<!-- </if>-->
|
|
|
|
|
<!-- <if test="request.describe!=null and request.describe!=''">-->
|
|
|
|
|
<!-- and describe like concat('%', #{request.describe}, '%')-->
|
|
|
|
|
<!-- </if>-->
|
|
|
|
|
<!-- </where>-->
|
|
|
|
|
<!-- ORDER BY "no",id DESC-->
|
2025-07-25 15:09:12 +08:00
|
|
|
|
2025-07-28 09:36:00 +08:00
|
|
|
select
|
|
|
|
|
a.inspection_num,a.factory,a.suppler_num as supplier_num,c.supplier_name,a.delivery_qty,a.inspection_result,a.item_code,a.inspection_type,
|
|
|
|
|
a.po_line_number,a.inspection_qty,a.item_name,a.unit,a.received_warehouse,a.unqualified_reason,a.po_num,a.receive_num,a.unqualified_qty,
|
2025-08-18 18:15:20 +08:00
|
|
|
a.qualified_qty,a.material_batch as receive_batch_num,a.serial_num,a.line_number,a.note_num,,a.sap_status as in_status
|
|
|
|
|
from wms_srm_quality_inspection a
|
2025-07-28 09:36:00 +08:00
|
|
|
left join user_supplier c on a.suppler_num=c.supplier_code
|
|
|
|
|
<where>
|
|
|
|
|
<if test="request.poNum !=null and request.poNum !='' ">
|
|
|
|
|
and a.po_num like concat('%', #{request.poNum}, '%')
|
|
|
|
|
</if>
|
|
|
|
|
|
|
|
|
|
<if test="request.noteNum !=null and request.noteNum !='' ">
|
|
|
|
|
and a.note_num like concat('%', #{request.noteNum}, '%')
|
|
|
|
|
</if>
|
|
|
|
|
|
|
|
|
|
<if test="request.inStatus !=null and request.inStatus !='' ">
|
|
|
|
|
and b.data_status=#{request.inStatus}
|
|
|
|
|
</if>
|
|
|
|
|
|
|
|
|
|
<if test="request.inspectionNum !=null and request.inspectionNum !='' ">
|
|
|
|
|
and a.inspection_num like concat('%', #{request.inspectionNum}, '%')
|
|
|
|
|
</if>
|
|
|
|
|
|
|
|
|
|
<if test="request.supplierNum !=null and request.supplierNum !='' ">
|
|
|
|
|
and a.suppler_num =#{request.supplierNum}
|
|
|
|
|
</if>
|
|
|
|
|
|
|
|
|
|
<if test="request.itemCode !=null and request.itemCode !='' ">
|
|
|
|
|
and a.item_code like =#{request.itemCode}
|
|
|
|
|
</if>
|
2025-07-28 18:22:40 +08:00
|
|
|
|
|
|
|
|
order by a.create_time desc
|
2025-07-28 09:36:00 +08:00
|
|
|
</where>
|
|
|
|
|
</select>
|
2025-07-25 15:09:12 +08:00
|
|
|
</mapper>
|