perf:【INFRA 基础设施】优化一些 todo 提到的问题

This commit is contained in:
puhui999
2025-05-20 16:34:40 +08:00
parent c320b525b5
commit 6982243370
11 changed files with 15 additions and 44 deletions

View File

@@ -215,4 +215,11 @@ public interface BaseMapperX<T> extends MPJBaseMapper<T> {
return delete(new LambdaQueryWrapper<T>().eq(field, value));
}
default int deleteBatch(SFunction<T, ?> field, Collection<?> values) {
if (CollUtil.isEmpty(values)) {
return 0;
}
return delete(new LambdaQueryWrapper<T>().in(field, values));
}
}