Mybatis-Plus 3.0-gamma 发布,超级棒棒糖之伽玛版

栏目: 数据库 · 发布时间: 7年前

内容简介:葫芦娃,葫芦娃,一根藤上七朵花。小小树藤,是我家,啦啦啦啦。

Mybatis-Plus 是一款 Mybatis 动态 SQL 自动注入 Mybatis 增删改查 CRUD 操作中间件, 减少你的开发周期优化动态维护 XML 实体字段,无入侵全方位 ORM 辅助层让您拥有更多时间陪家人。

Mybatis-Plus 3.0-gamma 发布,超级棒棒糖之伽玛版

葫芦娃,葫芦娃,一根藤上七朵花。小小树藤,是我家,啦啦啦啦。

叮当当咚咚当当,小树藤,叮当当咚咚当当,是我家,啦啦啦啦。

升级打怪我用 MP3 ,啦啦啦啦。

GITEE GITHUB 文档地址

MP 3.0 升级日志:

  • IPage 新增 listMode 集合模式

  • fixd gitee issues/IL7W4

  • fixed gitee issues/IL7W4

  • 优化生成器包导入

  • 解决 Page ascs,descs 异常

  • 逻辑删除无法 set where entity 一个参数并存逻辑

  • 合并 PR 修改typeAliasesPackage扫描多维度

  • 完善 3.0 测试用例

  • 代码性能优化及其他

1、强大的条件构造器

// SQL: SELECT name, age FROM user WHERE sex=1 AND ( age=3 OR age =5 ) AND name LIKE '%MP3%'
new QueryWrapper<User>(可传实体条件,字符串类型默认模糊查询)
.lambda().select(User::getName, User::getAge)
.eq(User::getSex, 1)
.and(i -> i.eq(User::getAge, 3).or().eq(User::getAge, 5))
.like(User::getName, "MP3");

2、 无限制的分页模型设计

// 分页 Mapper 层直接返回 IPage 接口,让分页模型完全自定义
IPage page = baseMapper.selectPage(page, ...);

3、通用 Api Controller 层

@GetMapping("/api")
public ApiResult<String> testApi(String content) {
   ApiAssert.isNull(ErrorCode.TEST, content);
   return success(content);
}

更多姿势!期待您的发现 ...

mybatis-plus 从2.x到3.x升级指南


以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网

查看所有标签

猜你喜欢:

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

Computers and Intractability

Computers and Intractability

M R Garey、D S Johnson / W. H. Freeman / 1979-4-26 / GBP 53.99

This book's introduction features a humorous story of a man with a line of people behind him, who explains to his boss, "I can't find an efficient algorithm, but neither can all these famous people." ......一起来看看 《Computers and Intractability》 这本书的介绍吧!

UNIX 时间戳转换
UNIX 时间戳转换

UNIX 时间戳转换

RGB CMYK 转换工具
RGB CMYK 转换工具

RGB CMYK 互转工具

HEX CMYK 转换工具
HEX CMYK 转换工具

HEX CMYK 互转工具