- 在 WmsStockLogMapper 中添加 selectVoPagePlus 方法,支持自定义查询条件 - 在 WmsStockLogServiceImpl 中实现自定义查询方法,使用 QueryWrapper 替代 LambdaQueryWrapper - 在 WmsStockLogVo 中添加 warehouseName 字段,用于显示仓库/库区名称 - 更新 mapper XML 文件,添加自定义查询 SQL 语句
33 lines
1.3 KiB
XML
33 lines
1.3 KiB
XML
<?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.klp.mapper.WmsStockLogMapper">
|
|
|
|
<resultMap type="com.klp.domain.WmsStockLog" id="WmsStockLogResult">
|
|
<result property="id" column="id"/>
|
|
<result property="warehouseId" column="warehouse_id"/>
|
|
<result property="itemId" column="item_id"/>
|
|
<result property="itemType" column="item_type"/>
|
|
<result property="changeQty" column="change_qty"/>
|
|
<result property="afterQty" column="after_qty"/>
|
|
<result property="changeType" column="change_type"/>
|
|
<result property="changeTime" column="change_time"/>
|
|
<result property="remark" column="remark"/>
|
|
<result property="createTime" column="create_time"/>
|
|
<result property="createBy" column="create_by"/>
|
|
<result property="updateTime" column="update_time"/>
|
|
<result property="updateBy" column="update_by"/>
|
|
<result property="delFlag" column="del_flag"/>
|
|
</resultMap>
|
|
|
|
<select id="selectVoPagePlus" resultType="com.klp.domain.vo.WmsStockLogVo">
|
|
select sl.*, w.warehouse_name
|
|
from wms_stock_log sl
|
|
left join wms_warehouse w on sl.warehouse_id = w.warehouse_id
|
|
${ew.customSqlSegment}
|
|
</select>
|
|
|
|
|
|
</mapper>
|