automation-lib 5.10.4 → 5.10.6

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.
package/commit.bat CHANGED
@@ -7,10 +7,10 @@ git add .
7
7
  echo Committing changes...
8
8
  set /p commit_message="Enter commit message: "
9
9
  git commit -m "%commit_message%"
10
- sleep 2
10
+ timeout /t 2 /nobreak >nul
11
11
 
12
12
  :: Push changes to the 'main' branch of the 'cp' remote
13
- git pull origin toan
13
+ git pull hs main
14
14
 
15
15
  :: Read the current version from package.json
16
16
  for /f "tokens=2 delims=:, " %%i in ('findstr "version" package.json') do set currentVersion=%%i
@@ -41,10 +41,10 @@ echo New version: %newVersion%
41
41
  call npm run pub
42
42
 
43
43
  git add .
44
- sleep 1
44
+ timeout /t 1 /nobreak >nul
45
45
  git commit -m "%commit_message%"
46
- sleep 2
46
+ timeout /t 2 /nobreak >nul
47
47
 
48
- git push origin toan
48
+ git push hs main
49
49
 
50
50
 
package/dist/index.d.mts CHANGED
@@ -11301,6 +11301,7 @@ interface FilterManagerImageAIInstagramDto extends IFilterBaseDto, IFilterAssign
11301
11301
  startStop: EStartStop[];
11302
11302
  sheetName: string[];
11303
11303
  accountGroup: string[];
11304
+ accountSocial: string[];
11304
11305
  }
11305
11306
 
11306
11307
  interface IManagerImageAIInstagram extends IBaseModel, ITrackingModel, IAssignUser {
@@ -11558,17 +11559,11 @@ interface FilterManagerSheetDto extends IFilterBaseDto {
11558
11559
  interface CreateSheetToolDto {
11559
11560
  type: ESheetToolInstagram;
11560
11561
  typeSocial: ETypeSocial;
11561
- url: string;
11562
- name: string;
11563
- deviceId: string;
11564
- description: string;
11565
- timeCrawl: ESheetToolTimeCrawl;
11566
- totalRows: number;
11567
- totalCols: number;
11568
- }
11569
- interface PayloadUrlSheetToolDto extends Partial<ISheetsTool> {
11570
11562
  sheetUrl: string;
11571
11563
  sheetName: string;
11564
+ deviceId: string;
11565
+ timeCrawl: ESheetToolTimeCrawl;
11566
+ description: string;
11572
11567
  }
11573
11568
  interface LoadInfoUrlSheetToolDto {
11574
11569
  idea: string;
@@ -11577,8 +11572,10 @@ interface LoadInfoUrlSheetToolDto {
11577
11572
  accountGroup: string[];
11578
11573
  listAccountIds: string[];
11579
11574
  listAccountUsername: string[];
11580
- totalRows: number;
11581
- totalCols: number;
11575
+ }
11576
+ interface PayloadUrlSheetToolDto extends Partial<ISheetsTool> {
11577
+ sheetUrl: string;
11578
+ sheetName: string;
11582
11579
  }
11583
11580
  interface ActionLoadInfoUrlSheetToolDto {
11584
11581
  typeSocial: ETypeSocial;
@@ -11623,34 +11620,13 @@ interface OverviewSheetsToolDto {
11623
11620
  totalReplyMessenger: number;
11624
11621
  }
11625
11622
  interface FindSheetsToolDto extends IFindBaseDto {
11626
- typeSocial: ETypeSocial;
11627
- idea: {
11628
- id: string;
11629
- name: string;
11630
- };
11631
- niche: {
11632
- id: string;
11633
- name: string;
11634
- };
11635
- type: ETypeManagerWorkClassify;
11636
- device: {
11637
- id: string;
11638
- name: string;
11639
- statusConnectPC: EStatusDeviceConnectPC;
11640
- };
11641
11623
  pc: {
11642
11624
  id: string;
11643
11625
  name: string;
11644
11626
  };
11645
- url: string;
11646
- name: string;
11647
- typeSheet: ESheetToolInstagram;
11627
+ deviceID: string;
11628
+ statusDevice: EStatusDeviceConnectPC;
11648
11629
  statusImport: ESheetToolStatusImport;
11649
- statusRun: ESheetToolStatusRun;
11650
- timeCrawl: ESheetToolTimeCrawl;
11651
- totalRows: number;
11652
- totalCols: number;
11653
- description: string;
11654
11630
  listAccountSocial: Array<{
11655
11631
  id: string;
11656
11632
  accountId: string;
@@ -11659,6 +11635,28 @@ interface FindSheetsToolDto extends IFindBaseDto {
11659
11635
  status: string;
11660
11636
  createdAt: Date;
11661
11637
  }>;
11638
+ statusRun: ESheetToolStatusRun;
11639
+ typeSheet: ESheetToolInstagram;
11640
+ timeReadingSheet: number;
11641
+ sheetName: string;
11642
+ sheetUrl: string;
11643
+ totalCols: number;
11644
+ totalRows: number;
11645
+ timeCrawl: ESheetToolTimeCrawl;
11646
+ statusCrawl: EStatusActive;
11647
+ description: string;
11648
+ typeSocial: ETypeSocial;
11649
+ idea: {
11650
+ id: string;
11651
+ name: string;
11652
+ };
11653
+ niche: {
11654
+ id: string;
11655
+ name: string;
11656
+ };
11657
+ type: ETypeManagerWorkClassify;
11658
+ url: string;
11659
+ name: string;
11662
11660
  noteFixImport: string;
11663
11661
  lastUserInfo: IUserInfoAssignment;
11664
11662
  }
@@ -12216,7 +12214,7 @@ interface ImageVideoVoiceDetailInstagramDto {
12216
12214
  typeIdea: ETypeManagerWorkClassify;
12217
12215
  createdAt: Date;
12218
12216
  updatedAt: Date;
12219
- toolAuto: "Browser Automation";
12217
+ toolAuto: 'Browser Automation';
12220
12218
  taskToolKeyAiGen: string;
12221
12219
  statusImageVideoVoice: ETaskStatus;
12222
12220
  currentStepImageVideoVoice: number;
@@ -12252,7 +12250,7 @@ interface ImageVideoVoiceDetailInstagramDto {
12252
12250
  }>;
12253
12251
  infoBrowserInfo: {
12254
12252
  browserName: string;
12255
- browserType: "GPM";
12253
+ browserType: 'GPM';
12256
12254
  listProxy: Array<{
12257
12255
  proxyFormat: string;
12258
12256
  proxyType: ETypeProxy;
@@ -12274,7 +12272,7 @@ interface ImageVideoVoiceDetailInstagramDto {
12274
12272
  }>;
12275
12273
  infoGenVoice: {
12276
12274
  model: string;
12277
- modeVoice: "Multi Speaker Audio";
12275
+ modeVoice: 'Multi Speaker Audio';
12278
12276
  modelSetting: string;
12279
12277
  language: string;
12280
12278
  totalVoice: number;
@@ -12313,11 +12311,11 @@ interface ImageVideoVoiceDetailInstagramDto {
12313
12311
  urlFolderDrive: string;
12314
12312
  result: Array<{
12315
12313
  timestamp: Date;
12316
- typeTask: "Image" | "Video";
12314
+ typeTask: 'Image' | 'Video';
12317
12315
  taskName: string;
12318
12316
  status: string;
12319
12317
  timeGenerate: number;
12320
- typeAction: "Tool" | "Api";
12318
+ typeAction: 'Tool' | 'Api';
12321
12319
  message: string;
12322
12320
  }>;
12323
12321
  };
@@ -12333,7 +12331,7 @@ interface CanvaDetailInstagramDto {
12333
12331
  typeIdea: ETypeManagerWorkClassify;
12334
12332
  createdAt: Date;
12335
12333
  updatedAt: Date;
12336
- toolAuto: "Canva";
12334
+ toolAuto: 'Canva';
12337
12335
  taskToolKeyCanva: string;
12338
12336
  currentStepCanva: number;
12339
12337
  totalStepCanva: number;
@@ -12362,7 +12360,7 @@ interface CanvaDetailInstagramDto {
12362
12360
  }>;
12363
12361
  infoBrowserInfo: {
12364
12362
  browserName: string;
12365
- browserType: "GPM";
12363
+ browserType: 'GPM';
12366
12364
  listProxy: Array<{
12367
12365
  proxyFormat: string;
12368
12366
  proxyType: ETypeProxy;
@@ -12393,7 +12391,7 @@ interface CanvaDetailInstagramDto {
12393
12391
  effectPage27: string;
12394
12392
  };
12395
12393
  infoCanvaEditPage: Array<{
12396
- page: "Page1" | "Page2" | "Page3" | "Page4" | "Page5" | "Page6" | "Page7";
12394
+ page: 'Page1' | 'Page2' | 'Page3' | 'Page4' | 'Page5' | 'Page6' | 'Page7';
12397
12395
  status: ETaskStatus;
12398
12396
  time: number;
12399
12397
  retry: number;
@@ -12427,8 +12425,8 @@ interface CanvaDetailInstagramDto {
12427
12425
  result: Array<{
12428
12426
  timestamp: Date;
12429
12427
  status: ETaskStatus;
12430
- typeAction: "Edit";
12431
- page: "Page1" | "Page2" | "Page3" | "Page4" | "Page5" | "Page6" | "Page7";
12428
+ typeAction: 'Edit';
12429
+ page: 'Page1' | 'Page2' | 'Page3' | 'Page4' | 'Page5' | 'Page6' | 'Page7';
12432
12430
  background: string;
12433
12431
  frontText: string;
12434
12432
  effect: string;
package/dist/index.d.ts CHANGED
@@ -11301,6 +11301,7 @@ interface FilterManagerImageAIInstagramDto extends IFilterBaseDto, IFilterAssign
11301
11301
  startStop: EStartStop[];
11302
11302
  sheetName: string[];
11303
11303
  accountGroup: string[];
11304
+ accountSocial: string[];
11304
11305
  }
11305
11306
 
11306
11307
  interface IManagerImageAIInstagram extends IBaseModel, ITrackingModel, IAssignUser {
@@ -11558,17 +11559,11 @@ interface FilterManagerSheetDto extends IFilterBaseDto {
11558
11559
  interface CreateSheetToolDto {
11559
11560
  type: ESheetToolInstagram;
11560
11561
  typeSocial: ETypeSocial;
11561
- url: string;
11562
- name: string;
11563
- deviceId: string;
11564
- description: string;
11565
- timeCrawl: ESheetToolTimeCrawl;
11566
- totalRows: number;
11567
- totalCols: number;
11568
- }
11569
- interface PayloadUrlSheetToolDto extends Partial<ISheetsTool> {
11570
11562
  sheetUrl: string;
11571
11563
  sheetName: string;
11564
+ deviceId: string;
11565
+ timeCrawl: ESheetToolTimeCrawl;
11566
+ description: string;
11572
11567
  }
11573
11568
  interface LoadInfoUrlSheetToolDto {
11574
11569
  idea: string;
@@ -11577,8 +11572,10 @@ interface LoadInfoUrlSheetToolDto {
11577
11572
  accountGroup: string[];
11578
11573
  listAccountIds: string[];
11579
11574
  listAccountUsername: string[];
11580
- totalRows: number;
11581
- totalCols: number;
11575
+ }
11576
+ interface PayloadUrlSheetToolDto extends Partial<ISheetsTool> {
11577
+ sheetUrl: string;
11578
+ sheetName: string;
11582
11579
  }
11583
11580
  interface ActionLoadInfoUrlSheetToolDto {
11584
11581
  typeSocial: ETypeSocial;
@@ -11623,34 +11620,13 @@ interface OverviewSheetsToolDto {
11623
11620
  totalReplyMessenger: number;
11624
11621
  }
11625
11622
  interface FindSheetsToolDto extends IFindBaseDto {
11626
- typeSocial: ETypeSocial;
11627
- idea: {
11628
- id: string;
11629
- name: string;
11630
- };
11631
- niche: {
11632
- id: string;
11633
- name: string;
11634
- };
11635
- type: ETypeManagerWorkClassify;
11636
- device: {
11637
- id: string;
11638
- name: string;
11639
- statusConnectPC: EStatusDeviceConnectPC;
11640
- };
11641
11623
  pc: {
11642
11624
  id: string;
11643
11625
  name: string;
11644
11626
  };
11645
- url: string;
11646
- name: string;
11647
- typeSheet: ESheetToolInstagram;
11627
+ deviceID: string;
11628
+ statusDevice: EStatusDeviceConnectPC;
11648
11629
  statusImport: ESheetToolStatusImport;
11649
- statusRun: ESheetToolStatusRun;
11650
- timeCrawl: ESheetToolTimeCrawl;
11651
- totalRows: number;
11652
- totalCols: number;
11653
- description: string;
11654
11630
  listAccountSocial: Array<{
11655
11631
  id: string;
11656
11632
  accountId: string;
@@ -11659,6 +11635,28 @@ interface FindSheetsToolDto extends IFindBaseDto {
11659
11635
  status: string;
11660
11636
  createdAt: Date;
11661
11637
  }>;
11638
+ statusRun: ESheetToolStatusRun;
11639
+ typeSheet: ESheetToolInstagram;
11640
+ timeReadingSheet: number;
11641
+ sheetName: string;
11642
+ sheetUrl: string;
11643
+ totalCols: number;
11644
+ totalRows: number;
11645
+ timeCrawl: ESheetToolTimeCrawl;
11646
+ statusCrawl: EStatusActive;
11647
+ description: string;
11648
+ typeSocial: ETypeSocial;
11649
+ idea: {
11650
+ id: string;
11651
+ name: string;
11652
+ };
11653
+ niche: {
11654
+ id: string;
11655
+ name: string;
11656
+ };
11657
+ type: ETypeManagerWorkClassify;
11658
+ url: string;
11659
+ name: string;
11662
11660
  noteFixImport: string;
11663
11661
  lastUserInfo: IUserInfoAssignment;
11664
11662
  }
@@ -12216,7 +12214,7 @@ interface ImageVideoVoiceDetailInstagramDto {
12216
12214
  typeIdea: ETypeManagerWorkClassify;
12217
12215
  createdAt: Date;
12218
12216
  updatedAt: Date;
12219
- toolAuto: "Browser Automation";
12217
+ toolAuto: 'Browser Automation';
12220
12218
  taskToolKeyAiGen: string;
12221
12219
  statusImageVideoVoice: ETaskStatus;
12222
12220
  currentStepImageVideoVoice: number;
@@ -12252,7 +12250,7 @@ interface ImageVideoVoiceDetailInstagramDto {
12252
12250
  }>;
12253
12251
  infoBrowserInfo: {
12254
12252
  browserName: string;
12255
- browserType: "GPM";
12253
+ browserType: 'GPM';
12256
12254
  listProxy: Array<{
12257
12255
  proxyFormat: string;
12258
12256
  proxyType: ETypeProxy;
@@ -12274,7 +12272,7 @@ interface ImageVideoVoiceDetailInstagramDto {
12274
12272
  }>;
12275
12273
  infoGenVoice: {
12276
12274
  model: string;
12277
- modeVoice: "Multi Speaker Audio";
12275
+ modeVoice: 'Multi Speaker Audio';
12278
12276
  modelSetting: string;
12279
12277
  language: string;
12280
12278
  totalVoice: number;
@@ -12313,11 +12311,11 @@ interface ImageVideoVoiceDetailInstagramDto {
12313
12311
  urlFolderDrive: string;
12314
12312
  result: Array<{
12315
12313
  timestamp: Date;
12316
- typeTask: "Image" | "Video";
12314
+ typeTask: 'Image' | 'Video';
12317
12315
  taskName: string;
12318
12316
  status: string;
12319
12317
  timeGenerate: number;
12320
- typeAction: "Tool" | "Api";
12318
+ typeAction: 'Tool' | 'Api';
12321
12319
  message: string;
12322
12320
  }>;
12323
12321
  };
@@ -12333,7 +12331,7 @@ interface CanvaDetailInstagramDto {
12333
12331
  typeIdea: ETypeManagerWorkClassify;
12334
12332
  createdAt: Date;
12335
12333
  updatedAt: Date;
12336
- toolAuto: "Canva";
12334
+ toolAuto: 'Canva';
12337
12335
  taskToolKeyCanva: string;
12338
12336
  currentStepCanva: number;
12339
12337
  totalStepCanva: number;
@@ -12362,7 +12360,7 @@ interface CanvaDetailInstagramDto {
12362
12360
  }>;
12363
12361
  infoBrowserInfo: {
12364
12362
  browserName: string;
12365
- browserType: "GPM";
12363
+ browserType: 'GPM';
12366
12364
  listProxy: Array<{
12367
12365
  proxyFormat: string;
12368
12366
  proxyType: ETypeProxy;
@@ -12393,7 +12391,7 @@ interface CanvaDetailInstagramDto {
12393
12391
  effectPage27: string;
12394
12392
  };
12395
12393
  infoCanvaEditPage: Array<{
12396
- page: "Page1" | "Page2" | "Page3" | "Page4" | "Page5" | "Page6" | "Page7";
12394
+ page: 'Page1' | 'Page2' | 'Page3' | 'Page4' | 'Page5' | 'Page6' | 'Page7';
12397
12395
  status: ETaskStatus;
12398
12396
  time: number;
12399
12397
  retry: number;
@@ -12427,8 +12425,8 @@ interface CanvaDetailInstagramDto {
12427
12425
  result: Array<{
12428
12426
  timestamp: Date;
12429
12427
  status: ETaskStatus;
12430
- typeAction: "Edit";
12431
- page: "Page1" | "Page2" | "Page3" | "Page4" | "Page5" | "Page6" | "Page7";
12428
+ typeAction: 'Edit';
12429
+ page: 'Page1' | 'Page2' | 'Page3' | 'Page4' | 'Page5' | 'Page6' | 'Page7';
12432
12430
  background: string;
12433
12431
  frontText: string;
12434
12432
  effect: string;
package/docs.txt CHANGED
@@ -1,3 +1,3 @@
1
-
2
- ############ Cấu hình npm ############
1
+
2
+ ############ Cấu hình npm ############
3
3
  npm config set //registry.npmjs.org/:_authToken {token}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "automation-lib",
3
- "version": "5.10.4",
3
+ "version": "5.10.6",
4
4
  "description": "Common features and type of applications auto",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
@@ -1,81 +1,81 @@
1
- @echo off
2
- setlocal enabledelayedexpansion
3
- chcp 65001 >nul
4
- echo ====================================
5
- echo FILE SEARCH AND LIST UTILITY
6
- echo ====================================
7
- echo.
8
-
9
- set /p folder_path="Enter folder path: "
10
-
11
- if not exist "%folder_path%" (
12
- echo.
13
- echo [ERROR] Folder does not exist!
14
- pause
15
- exit /b
16
- )
17
-
18
- echo.
19
- set /p file_pattern="Enter file name pattern (press Enter to list all files): "
20
-
21
- if "%file_pattern%"=="" (
22
- set search_mode=ALL_FILES
23
- set output_file=all_files_%date:~10,4%%date:~4,2%%date:~7,2%_%time:~0,2%%time:~3,2%%time:~6,2%.txt
24
- ) else (
25
- set search_mode=PATTERN_SEARCH
26
- set output_file=search_%file_pattern:_=_%_%date:~10,4%%date:~4,2%%date:~7,2%_%time:~0,2%%time:~3,2%%time:~6,2%.txt
27
- )
28
-
29
- set output_file=%output_file: =0%
30
-
31
- echo.
32
- echo Searching files...
33
- if "%search_mode%"=="PATTERN_SEARCH" (
34
- echo Pattern: *%file_pattern%*
35
- ) else (
36
- echo Listing all files...
37
- )
38
- echo.
39
-
40
- echo ============ SEARCH RESULTS ============ > "%output_file%"
41
- echo Folder: %folder_path% >> "%output_file%"
42
- echo Time: %date% %time% >> "%output_file%"
43
- if "%search_mode%"=="PATTERN_SEARCH" (
44
- echo Search Pattern: *%file_pattern%* >> "%output_file%"
45
- ) else (
46
- echo Search Mode: All Files >> "%output_file%"
47
- )
48
- echo ====================================== >> "%output_file%"
49
- echo. >> "%output_file%"
50
-
51
- set count=0
52
-
53
- if "%search_mode%"=="ALL_FILES" (
54
- for /r "%folder_path%" %%f in (*) do (
55
- echo %%f
56
- echo %%f >> "%output_file%"
57
- set /a count+=1
58
- )
59
- ) else (
60
- for /r "%folder_path%" %%f in (*) do (
61
- echo %%~nxf | findstr /i "%file_pattern%" >nul
62
- if !errorlevel! equ 0 (
63
- echo %%f
64
- echo %%f >> "%output_file%"
65
- set /a count+=1
66
- )
67
- )
68
- )
69
-
70
- echo.
71
- echo ====================================
72
- if "%search_mode%"=="PATTERN_SEARCH" (
73
- echo Total matching files: %count%
74
- ) else (
75
- echo Total files: %count%
76
- )
77
- echo Result saved to: %output_file%
78
- echo ====================================
79
- echo.
80
-
81
- pause
1
+ @echo off
2
+ setlocal enabledelayedexpansion
3
+ chcp 65001 >nul
4
+ echo ====================================
5
+ echo FILE SEARCH AND LIST UTILITY
6
+ echo ====================================
7
+ echo.
8
+
9
+ set /p folder_path="Enter folder path: "
10
+
11
+ if not exist "%folder_path%" (
12
+ echo.
13
+ echo [ERROR] Folder does not exist!
14
+ pause
15
+ exit /b
16
+ )
17
+
18
+ echo.
19
+ set /p file_pattern="Enter file name pattern (press Enter to list all files): "
20
+
21
+ if "%file_pattern%"=="" (
22
+ set search_mode=ALL_FILES
23
+ set output_file=all_files_%date:~10,4%%date:~4,2%%date:~7,2%_%time:~0,2%%time:~3,2%%time:~6,2%.txt
24
+ ) else (
25
+ set search_mode=PATTERN_SEARCH
26
+ set output_file=search_%file_pattern:_=_%_%date:~10,4%%date:~4,2%%date:~7,2%_%time:~0,2%%time:~3,2%%time:~6,2%.txt
27
+ )
28
+
29
+ set output_file=%output_file: =0%
30
+
31
+ echo.
32
+ echo Searching files...
33
+ if "%search_mode%"=="PATTERN_SEARCH" (
34
+ echo Pattern: *%file_pattern%*
35
+ ) else (
36
+ echo Listing all files...
37
+ )
38
+ echo.
39
+
40
+ echo ============ SEARCH RESULTS ============ > "%output_file%"
41
+ echo Folder: %folder_path% >> "%output_file%"
42
+ echo Time: %date% %time% >> "%output_file%"
43
+ if "%search_mode%"=="PATTERN_SEARCH" (
44
+ echo Search Pattern: *%file_pattern%* >> "%output_file%"
45
+ ) else (
46
+ echo Search Mode: All Files >> "%output_file%"
47
+ )
48
+ echo ====================================== >> "%output_file%"
49
+ echo. >> "%output_file%"
50
+
51
+ set count=0
52
+
53
+ if "%search_mode%"=="ALL_FILES" (
54
+ for /r "%folder_path%" %%f in (*) do (
55
+ echo %%f
56
+ echo %%f >> "%output_file%"
57
+ set /a count+=1
58
+ )
59
+ ) else (
60
+ for /r "%folder_path%" %%f in (*) do (
61
+ echo %%~nxf | findstr /i "%file_pattern%" >nul
62
+ if !errorlevel! equ 0 (
63
+ echo %%f
64
+ echo %%f >> "%output_file%"
65
+ set /a count+=1
66
+ )
67
+ )
68
+ )
69
+
70
+ echo.
71
+ echo ====================================
72
+ if "%search_mode%"=="PATTERN_SEARCH" (
73
+ echo Total matching files: %count%
74
+ ) else (
75
+ echo Total files: %count%
76
+ )
77
+ echo Result saved to: %output_file%
78
+ echo ====================================
79
+ echo.
80
+
81
+ pause