From 3f07ab2e03e501ae55d1d1b0d031daf50c8e13e5 Mon Sep 17 00:00:00 2001 From: dongyukun <1208714201@qq.com> Date: 星期二, 10 十二月 2024 17:27:44 +0800 Subject: [PATCH] common依赖排除父类 --- iailab-xmc-pms-biz/src/main/java/com/iailab/module/pms/production/warehouse/dao/McMzDao.java | 31 +++++++++++++++++++++++++++++++ 1 files changed, 31 insertions(+), 0 deletions(-) diff --git a/iailab-xmc-pms-biz/src/main/java/com/iailab/module/pms/production/warehouse/dao/McMzDao.java b/iailab-xmc-pms-biz/src/main/java/com/iailab/module/pms/production/warehouse/dao/McMzDao.java new file mode 100644 index 0000000..c7c356e --- /dev/null +++ b/iailab-xmc-pms-biz/src/main/java/com/iailab/module/pms/production/warehouse/dao/McMzDao.java @@ -0,0 +1,31 @@ +package com.iailab.module.pms.production.warehouse.dao; + +import com.iailab.framework.common.dao.BaseDao; +import com.iailab.framework.common.pojo.PageResult; +import com.iailab.framework.mybatis.core.mapper.BaseMapperX; +import com.iailab.framework.mybatis.core.query.LambdaQueryWrapperX; +import com.iailab.module.pms.production.warehouse.entity.McMzEntity; +import com.iailab.module.pms.production.warehouse.vo.McMzPageReqVO; +import org.apache.ibatis.annotations.Delete; +import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; +import org.apache.ibatis.annotations.Select; +import org.springframework.stereotype.Component; + +import java.util.List; + +@Mapper +@Component +public interface McMzDao extends BaseMapperX<McMzEntity> { + + @Select("SELECT * , SUM(proportion) OVER () as den FROM t_mc_mz WHERE mc = #{mc}") + List<McMzEntity> selectMzList(@Param("mc") String mc); + + @Delete("DELETE FROM t_mc_mz WHERE mc = #{mc}") + void deleteByMc(@Param("mc") String mc); + + default PageResult<McMzEntity> selectPage(McMzPageReqVO Entity) { + return selectPage(Entity, new LambdaQueryWrapperX<McMzEntity>() + .orderByDesc(McMzEntity::getCreateBy)); + } +} -- Gitblit v1.9.3