yaowanxin
2025-06-23 4c001e8b7efc1383d1cdfc8219538eeaec49c51b
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>