feat: 新需求功能代码提交,新增MPJLambdaWrapper查询。
This commit is contained in:
@@ -169,7 +169,7 @@ public class SysConfigServiceImpl implements ISysConfigService, ConfigService {
|
||||
*/
|
||||
@Override
|
||||
public void deleteConfigByIds(List<Long> configIds) {
|
||||
List<SysConfig> list = baseMapper.selectByIds(configIds);
|
||||
List<SysConfig> list = baseMapper.selectBatchIds(configIds);
|
||||
list.forEach(config -> {
|
||||
if (StringUtils.equals(SystemConstants.YES, config.getConfigType())) {
|
||||
throw new ServiceException("内置参数【{}】不能删除", config.getConfigKey());
|
||||
|
||||
@@ -102,7 +102,7 @@ public class SysDictDataServiceImpl implements ISysDictDataService {
|
||||
*/
|
||||
@Override
|
||||
public void deleteDictDataByIds(List<Long> dictCodes) {
|
||||
List<SysDictData> list = baseMapper.selectByIds(dictCodes);
|
||||
List<SysDictData> list = baseMapper.selectBatchIds(dictCodes);
|
||||
baseMapper.deleteByIds(dictCodes);
|
||||
list.forEach(x -> CacheUtils.evict(CacheNames.SYS_DICT, x.getDictType()));
|
||||
}
|
||||
|
||||
@@ -138,7 +138,7 @@ public class SysDictTypeServiceImpl implements ISysDictTypeService, DictService
|
||||
*/
|
||||
@Override
|
||||
public void deleteDictTypeByIds(List<Long> dictIds) {
|
||||
List<SysDictType> list = baseMapper.selectByIds(dictIds);
|
||||
List<SysDictType> list = baseMapper.selectBatchIds(dictIds);
|
||||
list.forEach(x -> {
|
||||
boolean assigned = dictDataMapper.exists(new LambdaQueryWrapper<SysDictData>()
|
||||
.eq(SysDictData::getDictType, x.getDictType()));
|
||||
|
||||
@@ -252,7 +252,7 @@ public class SysOssServiceImpl implements ISysOssService, OssService {
|
||||
if (isValid) {
|
||||
// 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
List<SysOss> list = baseMapper.selectByIds(ids);
|
||||
List<SysOss> list = baseMapper.selectBatchIds(ids);
|
||||
for (SysOss sysOss : list) {
|
||||
OssClient storage = OssFactory.instance(sysOss.getService());
|
||||
storage.delete(sysOss.getUrl());
|
||||
|
||||
@@ -222,7 +222,7 @@ public class SysPostServiceImpl implements ISysPostService, PostService {
|
||||
*/
|
||||
@Override
|
||||
public int deletePostByIds(List<Long> postIds) {
|
||||
List<SysPost> list = baseMapper.selectByIds(postIds);
|
||||
List<SysPost> list = baseMapper.selectBatchIds(postIds);
|
||||
for (SysPost post : list) {
|
||||
if (this.countUserPostById(post.getPostId()) > 0) {
|
||||
throw new ServiceException("{}已分配,不能删除!", post.getPostName());
|
||||
|
||||
@@ -428,7 +428,7 @@ public class SysRoleServiceImpl implements ISysRoleService, RoleService {
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public int deleteRoleByIds(List<Long> roleIds) {
|
||||
this.checkRoleDataScope(roleIds);
|
||||
List<SysRole> roles = baseMapper.selectByIds(roleIds);
|
||||
List<SysRole> roles = baseMapper.selectBatchIds(roleIds);
|
||||
for (SysRole role : roles) {
|
||||
checkRoleAllowed(BeanUtil.toBean(role, SysRoleBo.class));
|
||||
if (countUserRoleByRoleId(role.getRoleId()) > 0) {
|
||||
|
||||
Reference in New Issue
Block a user