|
@@ -4,6 +4,7 @@ import cn.hutool.core.bean.BeanUtil;
|
|
|
import cn.hutool.core.collection.CollUtil;
|
|
|
import cn.hutool.core.date.DateField;
|
|
|
import cn.hutool.core.date.DateUtil;
|
|
|
+import cn.hutool.core.date.StopWatch;
|
|
|
import cn.hutool.core.util.ObjectUtil;
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
@@ -647,17 +648,24 @@ public class ApsBlankOrderServiceImpl extends ServiceImpl<ApsBlankOrderDao, ApsB
|
|
|
//删除备份
|
|
|
ApsUtils.clearBackup(null);
|
|
|
//增加备份
|
|
|
+ StopWatch stopWatch = new StopWatch();
|
|
|
+ stopWatch.start();
|
|
|
List<List<String>> partition1 = Lists.partition(apsProcessOperationIds, 500);
|
|
|
partition1.forEach(data -> {
|
|
|
- apsProcessOperationBackupDao.processOperationBackup(apsProcessOperationIds,
|
|
|
+ apsProcessOperationBackupDao.processOperationBackup(data,
|
|
|
currentUser == null ? null : currentUser.getId(), currentUser == null ? null : currentUser.getName());
|
|
|
});
|
|
|
+ stopWatch.stop();
|
|
|
+ log.error("工序作业备份时长: {}"+stopWatch.getTotalTimeSeconds());
|
|
|
+ StopWatch stopWatch1 = new StopWatch();
|
|
|
+ stopWatch1.start();
|
|
|
List<List<ApsProcessOperationProcessEquDo>> partition = Lists.partition(apsProcessOperationProcessEquDos, 100);
|
|
|
partition.forEach(data -> {
|
|
|
apsProcessOperationProcessEquBackupDao.processOperationEquBackup(apsProcessOperationProcessEquDos,
|
|
|
currentUser == null ? null : currentUser.getId(), currentUser == null ? null : currentUser.getName());
|
|
|
});
|
|
|
-
|
|
|
+ stopWatch1.stop();
|
|
|
+ log.error("工序作业明细备份时长: {}"+stopWatch1.getTotalTimeSeconds());
|
|
|
}
|
|
|
|
|
|
/**
|