手动增加仓库调拨明细过滤查询

This commit is contained in:
c
2026-03-06 14:58:54 +08:00
parent 4c4716c151
commit d838d17902
14 changed files with 158 additions and 143 deletions

View File

@@ -24,4 +24,21 @@
<result column="PartId" property="partId" />
</resultMap>
<select id="selectByPartNumber" resultType="DocumentMaterialWithInfo">
SELECT m.*, p.ProductSpecs
FROM materialinout m
LEFT JOIN product p ON p.PartNumber = m.PartNumber
<where>
<if test="documentIds != null and !documentIds.isEmpty()">
AND m.DocumentNo IN
<foreach collection="documentIds" open="(" separator="," close=")" item="documentId">
#{documentId}
</foreach>
</if>
<if test="partNumber != null and partNumber != ''">
AND m.PartNumber LIKE CONCAT('%', #{partNumber}, '%')
</if>
</where>
</select>
</mapper>