# v2.8.0 升级至 v2.9.0
# 组件更改说明
该升级指南以v2.8.0版本为基准,更早的版本请先参考之前版本的升级文档。
diboot v2.9.x是基于spring boot 2.7的长期维护版本。
将diboot所有的组件版本号替换至2.9.0的最新版本,然后按照下述内容进行相关更改即可。
# diboot-core 内核
- 数据权限拦截实现变更:interceptor.addInnerInterceptor(new DataAccessControlInterceptor()) -> interceptor.addInnerInterceptor(new DataPermissionInterceptor(new DataAccessControlHandler()))
/**
* 配置拦截器
*/
@Bean
public MybatisPlusInterceptor mybatisPlusInterceptor() {
MybatisPlusInterceptor interceptor = new MybatisPlusInterceptor();
// 数据权限拦截器
interceptor.addInnerInterceptor(new DataPermissionInterceptor(new DataAccessControlHandler()));
// 分页拦截器
interceptor.addInnerInterceptor(new PaginationInnerInterceptor());
return interceptor;
}
1
2
3
4
5
6
7
8
9
10
11
12
2
3
4
5
6
7
8
9
10
11
12
# diboot-iam 权限体系
- IamUserController 中删除用户方法变更:iamUserService.deleteUserAndAccount -> iamUserService.deleteUserAndRelatedInfo
@Log(operation = OperationCons.LABEL_DELETE)
@BindPermission(name = OperationCons.LABEL_DELETE, code = OperationCons.CODE_WRITE)
@DeleteMapping("/{id}")
public JsonResult deleteEntityMapping(@PathVariable("id")Long id) throws Exception {
iamUserService.deleteUserAndRelatedInfo(id);
return JsonResult.OK();
}
1
2
3
4
5
6
7
2
3
4
5
6
7
# 前端升级说明
- diboot-antd-admin前端调整
升级前请下载diboot-antd-admin 2.9.0 (opens new window)源码包,以下升级流程将依赖此包。
- diboot-element-admin前端调整
升级前请下载diboot-element-admin 2.9.0 (opens new window)源码包,以下升级流程将依赖此包。
- diboot-mobile-ui前端调整
升级前请下载diboot-mobile-ui 2.9.0 (opens new window)源码包,以下升级流程将依赖此包。
- 对比新旧版本的相关页面及代码,替换或合并至本地。
← 通用技术文档 2.7.0升至2.8.0 →