tools_batch_files 1.0.22 → 1.0.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/photoBatch.js +14 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tools_batch_files",
3
- "version": "1.0.22",
3
+ "version": "1.0.23",
4
4
  "description": "批处理视频工具",
5
5
  "keywords": [
6
6
  "utils",
package/src/photoBatch.js CHANGED
@@ -38,7 +38,7 @@ const expandedName = ".jpg";
38
38
  const queueCount = 50;
39
39
 
40
40
  //起始任务下标
41
- let taskIndex = 0;
41
+ let taskIndex = 123265;
42
42
 
43
43
  const readExcel = (path) => {
44
44
  const workbook = XLSX.readFile(path);
@@ -494,12 +494,24 @@ const transitionExcelToJSON = () => {
494
494
  logger(
495
495
  `run-------------------------------------第${index}条开始------------------------------------`
496
496
  );
497
- logger(`-------------------${new Date()}------------------`);
497
+ const readExcelStartTime = new Date();
498
498
  const row = jsonData[index];
499
499
 
500
+ const readExcelEndTime = new Date();
501
+ const timeInSeconds = (
502
+ (readExcelEndTime - readExcelStartTime) /
503
+ 1000
504
+ ).toFixed(2);
505
+
506
+ logger(`第${index}条Excel搜索时间:${timeInSeconds}秒`);
507
+ logger(`-------------------${new Date()}------------------`);
500
508
  if (!row) {
501
509
  return;
502
510
  }
511
+ logger(
512
+ `----------------------------------------第${index}条task开始--------------------------------`
513
+ );
514
+ logger(`-------------------${new Date()}------------------`);
503
515
  task(row, index)
504
516
  .then(() => {
505
517
  taskIndex++;