mirror of
https://gitee.com/hhyykk/ipms-sjy.git
synced 2025-07-13 18:45:06 +08:00
页面装修修改,后端只负责存取
This commit is contained in:
@ -113,7 +113,6 @@ public interface BaseMapperX<T> extends MPJBaseMapper<T> {
|
||||
Db.saveBatch(entities, size);
|
||||
}
|
||||
|
||||
// @芋艿 是不是叫 updateByDo 或者 updateByEntity 更合适;回复:因为是使用实体作为条件去批量更新,所以没加 ByEntity,保持和 mybatis plus 风格一致
|
||||
default void updateBatch(T update) {
|
||||
update(update, new QueryWrapper<>());
|
||||
}
|
||||
@ -131,4 +130,12 @@ public interface BaseMapperX<T> extends MPJBaseMapper<T> {
|
||||
Db.updateBatchById(entities, size);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量修改插入, 会根据实体的主键是否为空,更新还是修改。默认为 1000
|
||||
* @param entities 实体们
|
||||
*/
|
||||
default void saveOrUpdateBatch(Collection<T> entities){
|
||||
Db.saveOrUpdateBatch(entities);
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user