| | |
| | | import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX; |
| | | import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX; |
| | | import cn.iocoder.yudao.module.mes.controller.admin.wm.itemconsume.vo.MesWmItemConsumeLinePageReqVO; |
| | | import cn.iocoder.yudao.module.mes.controller.admin.wm.itemconsume.vo.MesWmItemConsumeLineRespVO; |
| | | import cn.iocoder.yudao.module.mes.dal.dataobject.wm.itemconsume.MesWmItemConsumeLineDO; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | |
| | | @Mapper |
| | | public interface MesWmItemConsumeLineMapper extends BaseMapperX<MesWmItemConsumeLineDO> { |
| | | |
| | | default PageResult<MesWmItemConsumeLineDO> selectPage(MesWmItemConsumeLinePageReqVO reqVO, |
| | | Long consumeId) { |
| | | return selectPage(reqVO, new LambdaQueryWrapperX<MesWmItemConsumeLineDO>() |
| | | .eq(MesWmItemConsumeLineDO::getConsumeId, consumeId) |
| | | .orderByDesc(MesWmItemConsumeLineDO::getId)); |
| | | /** |
| | | * 分页查询消耗行(关联 mdm_item + mdm_unit_measure,通过 feedbackId) |
| | | */ |
| | | IPage<MesWmItemConsumeLineRespVO> selectPageByFeedbackId( |
| | | Page<MesWmItemConsumeLineRespVO> page, @Param("feedbackId") Long feedbackId); |
| | | |
| | | default PageResult<MesWmItemConsumeLineRespVO> selectPageByFeedbackId( |
| | | MesWmItemConsumeLinePageReqVO reqVO) { |
| | | Page<MesWmItemConsumeLineRespVO> mpPage = new Page<>(reqVO.getPageNo(), reqVO.getPageSize()); |
| | | IPage<MesWmItemConsumeLineRespVO> result = selectPageByFeedbackId(mpPage, reqVO.getFeedbackId()); |
| | | return new PageResult<>(result.getRecords(), result.getTotal()); |
| | | } |
| | | |
| | | default List<MesWmItemConsumeLineDO> selectListByConsumeId(Long consumeId) { |