yaowanxin
2025-06-24 d3d6287a3222b9c85a56e4c55c35350c4233c7db
src/main/resources/mapper/purchase/ProductRecordMapper.xml
@@ -32,10 +32,10 @@
            and sl.supplier_name = #{c.supplierName}
        </if>
        <if test="c.createdAtStart != null and c.createdAtStart != ''">
            and pr.created_at &gt;= date_format(#{c.createdAtStart},'%Y-%m-%d')
            and pr.created_at &gt;= date_format(#{c.createdAtStart},'%Y-%m-%d hh:mm:ss')
        </if>
        <if test="c.createdAtEnd != null and c.createdAtEnd != ''">
            and pr.created_at &lt; date_format(#{c.createdAtEnd},'%Y-%m-%d')
            and pr.created_at &lt;= date_format(#{c.createdAtEnd},'%Y-%m-%d hh:mm:ss')
        </if>
    </select>
</mapper>