feat(mat): 添加价格历史详情功能

- 在MatMaterialOutServiceImpl中添加逻辑删除过滤和按出库时间降序排序
- 为MatMatPriceHistoryMapper添加分页查询方法和对应的XML映射
- 扩展MatMatPriceHistoryVo实体类,增加物料名称、规格、型号等关联信息字段
- 修改MatProductServiceImpl中的流式处理语法,提升代码简洁性
- 为MatPurchaseBo和MatPurchaseInDetailBo添加开始时间和结束时间查询参数
- 实现价格历史记录的完整查询和展示功能,包括关联物料信息的获取
This commit is contained in:
2026-01-30 14:35:34 +08:00
parent 4d77473c01
commit 7135782d34
8 changed files with 112 additions and 4 deletions

View File

@@ -17,6 +17,28 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="updateBy" column="update_by"/>
<result property="remark" column="remark"/>
</resultMap>
<select id="selectVoPagePlus" resultType="com.gear.mat.domain.vo.MatMatPriceHistoryVo">
SELECT
t.history_id AS historyId,
t.material_id AS materialId,
t.price AS price,
t.avg_price AS avgPrice,
t.quantity AS quantity,
t.create_time AS createTime,
t.create_by AS createBy,
t.update_time AS updateTime,
t.update_by AS updateBy,
t.remark AS remark,
mm.material_name AS materialName,
mm.spec AS spec,
mm.model AS model,
mm.factory AS factory,
mm.unit AS unit,
mm.current_stock AS currentStock
FROM mat_mat_price_history t
LEFT JOIN mat_material mm ON t.material_id = mm.material_id AND mm.del_flag = 0
${ew.customSqlSegment}
</select>
</mapper>