Commit cd263022d4d02df22c6b70c5dfd02c9a1b939e2d
1 parent
387c5cd6
fix:【全局】sqlserver 在分页的兼容性
Showing
5 changed files
with
8 additions
and
12 deletions
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/dal/mysql/codegen/CodegenTableMapper.java
| ... | ... | @@ -23,8 +23,7 @@ public interface CodegenTableMapper extends BaseMapperX<CodegenTableDO> { |
| 23 | 23 | .likeIfPresent(CodegenTableDO::getTableComment, pageReqVO.getTableComment()) |
| 24 | 24 | .likeIfPresent(CodegenTableDO::getClassName, pageReqVO.getClassName()) |
| 25 | 25 | .betweenIfPresent(CodegenTableDO::getCreateTime, pageReqVO.getCreateTime()) |
| 26 | - .orderByDesc(CodegenTableDO::getUpdateTime) | |
| 27 | - ); | |
| 26 | + .orderByDesc(CodegenTableDO::getUpdateTime)); | |
| 28 | 27 | } |
| 29 | 28 | |
| 30 | 29 | default List<CodegenTableDO> selectListByDataSourceConfigId(Long dataSourceConfigId) { | ... | ... |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/dal/mysql/config/ConfigMapper.java
| ... | ... | @@ -19,7 +19,8 @@ public interface ConfigMapper extends BaseMapperX<ConfigDO> { |
| 19 | 19 | .likeIfPresent(ConfigDO::getName, reqVO.getName()) |
| 20 | 20 | .likeIfPresent(ConfigDO::getConfigKey, reqVO.getKey()) |
| 21 | 21 | .eqIfPresent(ConfigDO::getType, reqVO.getType()) |
| 22 | - .betweenIfPresent(ConfigDO::getCreateTime, reqVO.getCreateTime())); | |
| 22 | + .betweenIfPresent(ConfigDO::getCreateTime, reqVO.getCreateTime()) | |
| 23 | + .orderByDesc(ConfigDO::getId)); | |
| 23 | 24 | } |
| 24 | 25 | |
| 25 | 26 | } | ... | ... |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/dal/mysql/job/JobMapper.java
| ... | ... | @@ -24,7 +24,7 @@ public interface JobMapper extends BaseMapperX<JobDO> { |
| 24 | 24 | .likeIfPresent(JobDO::getName, reqVO.getName()) |
| 25 | 25 | .eqIfPresent(JobDO::getStatus, reqVO.getStatus()) |
| 26 | 26 | .likeIfPresent(JobDO::getHandlerName, reqVO.getHandlerName()) |
| 27 | - ); | |
| 27 | + .orderByDesc(JobDO::getId)); | |
| 28 | 28 | } |
| 29 | 29 | |
| 30 | 30 | } | ... | ... |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/mail/MailAccountMapper.java
| ... | ... | @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.system.dal.mysql.mail; |
| 3 | 3 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 4 | 4 | import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX; |
| 5 | 5 | import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX; |
| 6 | -import cn.iocoder.yudao.framework.mybatis.core.query.QueryWrapperX; | |
| 7 | 6 | import cn.iocoder.yudao.module.system.controller.admin.mail.vo.account.MailAccountPageReqVO; |
| 8 | 7 | import cn.iocoder.yudao.module.system.dal.dataobject.mail.MailAccountDO; |
| 9 | 8 | import org.apache.ibatis.annotations.Mapper; |
| ... | ... | @@ -14,7 +13,8 @@ public interface MailAccountMapper extends BaseMapperX<MailAccountDO> { |
| 14 | 13 | default PageResult<MailAccountDO> selectPage(MailAccountPageReqVO pageReqVO) { |
| 15 | 14 | return selectPage(pageReqVO, new LambdaQueryWrapperX<MailAccountDO>() |
| 16 | 15 | .likeIfPresent(MailAccountDO::getMail, pageReqVO.getMail()) |
| 17 | - .likeIfPresent(MailAccountDO::getUsername , pageReqVO.getUsername())); | |
| 16 | + .likeIfPresent(MailAccountDO::getUsername , pageReqVO.getUsername()) | |
| 17 | + .orderByDesc(MailAccountDO::getId)); | |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | 20 | } | ... | ... |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/mail/MailTemplateMapper.java
| ... | ... | @@ -3,14 +3,9 @@ package cn.iocoder.yudao.module.system.dal.mysql.mail; |
| 3 | 3 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 4 | 4 | import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX; |
| 5 | 5 | import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX; |
| 6 | -import cn.iocoder.yudao.framework.mybatis.core.query.QueryWrapperX; | |
| 7 | 6 | import cn.iocoder.yudao.module.system.controller.admin.mail.vo.template.MailTemplatePageReqVO; |
| 8 | 7 | import cn.iocoder.yudao.module.system.dal.dataobject.mail.MailTemplateDO; |
| 9 | -import cn.iocoder.yudao.module.system.dal.dataobject.sms.SmsTemplateDO; | |
| 10 | 8 | import org.apache.ibatis.annotations.Mapper; |
| 11 | -import org.apache.ibatis.annotations.Select; | |
| 12 | - | |
| 13 | -import java.util.Date; | |
| 14 | 9 | |
| 15 | 10 | @Mapper |
| 16 | 11 | public interface MailTemplateMapper extends BaseMapperX<MailTemplateDO> { |
| ... | ... | @@ -21,7 +16,8 @@ public interface MailTemplateMapper extends BaseMapperX<MailTemplateDO> { |
| 21 | 16 | .likeIfPresent(MailTemplateDO::getCode, pageReqVO.getCode()) |
| 22 | 17 | .likeIfPresent(MailTemplateDO::getName, pageReqVO.getName()) |
| 23 | 18 | .eqIfPresent(MailTemplateDO::getAccountId, pageReqVO.getAccountId()) |
| 24 | - .betweenIfPresent(MailTemplateDO::getCreateTime, pageReqVO.getCreateTime())); | |
| 19 | + .betweenIfPresent(MailTemplateDO::getCreateTime, pageReqVO.getCreateTime()) | |
| 20 | + .orderByDesc(MailTemplateDO::getId)); | |
| 25 | 21 | } |
| 26 | 22 | |
| 27 | 23 | default Long selectCountByAccountId(Long accountId) { | ... | ... |