shared-ritm 1.1.62 → 1.1.64

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.
@@ -1,6 +1,6 @@
1
1
  import ApiService, { ResponseApi } from '@/api/settings/ApiService';
2
2
  import { Api_Task_Instrument_Dto, Api_Task_Instrument_From_Warehouse, Api_Task_Module_Instrument_Condition, Api_Tasks_Dto, Api_Tasks_Task_Dto } from '@/api/types/Api_Tasks';
3
- import { Api_Equipment_Full_Dto } from '@/api/types/Api_Repairs';
3
+ import { Api_Equipment_Full_Dto, Api_Task_Video_Source } from '@/api/types/Api_Repairs';
4
4
  declare class TasksService extends ApiService {
5
5
  fetchTaskById(id: string): Promise<ResponseApi<Api_Tasks_Task_Dto>>;
6
6
  fetchTasksList(params: any): Promise<ResponseApi<Api_Tasks_Dto[]>>;
@@ -18,6 +18,8 @@ declare class TasksService extends ApiService {
18
18
  replaceInstruments(payload: any): Promise<ResponseApi<any>>;
19
19
  fetchTaskUsagePersonal(params: any): Promise<ResponseApi<unknown[]>>;
20
20
  fetchEquipment(params: any): Promise<ResponseApi<Api_Equipment_Full_Dto[]>>;
21
+ fetchTaskVideoSources(params: any): Promise<ResponseApi<Api_Task_Video_Source[]>>;
22
+ createWorkZone(params: any): Promise<unknown>;
21
23
  createTask(payload: any): Promise<ResponseApi<any>>;
22
24
  editTask(payload: any): Promise<ResponseApi<any>>;
23
25
  mergeTask(payload: {
@@ -26,6 +26,21 @@ export type Api_Equipment_Full_Dto = {
26
26
  repair_frequency: number;
27
27
  repair_range: number;
28
28
  };
29
+ export type Api_Task_Video_Source = {
30
+ id: string;
31
+ name: string;
32
+ work_zones_by_tasks: Array<{
33
+ coordinates: {
34
+ x0: number;
35
+ x1: number;
36
+ y0: number;
37
+ y1: number;
38
+ };
39
+ id: string;
40
+ tasks: unknown[];
41
+ title: string;
42
+ }>;
43
+ };
29
44
  export type Api_Create_Repair_With_Equipments = {
30
45
  name: string;
31
46
  display_name: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shared-ritm",
3
- "version": "1.1.62",
3
+ "version": "1.1.64",
4
4
  "private": false,
5
5
  "files": [
6
6
  "dist",
@@ -6,7 +6,7 @@ import {
6
6
  Api_Tasks_Dto,
7
7
  Api_Tasks_Task_Dto,
8
8
  } from '@/api/types/Api_Tasks'
9
- import { Api_Equipment_Full_Dto } from '@/api/types/Api_Repairs'
9
+ import { Api_Equipment_Full_Dto, Api_Task_Video_Source } from '@/api/types/Api_Repairs'
10
10
 
11
11
  class TasksService extends ApiService {
12
12
  public async fetchTaskById(id: string): Promise<ResponseApi<Api_Tasks_Task_Dto>> {
@@ -57,6 +57,14 @@ class TasksService extends ApiService {
57
57
  return this.get('repairs/equipment/list', { params })
58
58
  }
59
59
 
60
+ public fetchTaskVideoSources(params: any): Promise<ResponseApi<Api_Task_Video_Source[]>> {
61
+ return this.get('work_zone/get_list_video_source', { params })
62
+ }
63
+
64
+ public createWorkZone(params: any): Promise<unknown> {
65
+ return this.post('admin/work-zones', { params })
66
+ }
67
+
60
68
  public async createTask(payload: any): Promise<ResponseApi<any>> {
61
69
  return await this.post(`tasks`, payload)
62
70
  }
@@ -1,63 +1,74 @@
1
- export type Api_Team = {
2
- id: string
3
- display_name: string
4
- }
5
-
6
- export type Api_Equipment_Short_Dto = {
7
- id: string
8
- name: string
9
- }
10
-
11
- export type Api_Repairs = {
12
- id: string
13
- name: string
14
- }
15
-
16
- export type Api_Projects = {
17
- id: string
18
- name: string
19
- }
20
-
21
- export type OptionFilters = {
22
- teams?: Api_Team[]
23
- equipments?: Api_Equipment_Short_Dto[]
24
- }
25
-
26
- export type Api_Equipment_Full_Dto = {
27
- id: string
28
- model: null | string
29
- name: string
30
- registration_number: string
31
- repair_frequency: number
32
- repair_range: number
33
- }
34
-
35
- export type Api_Create_Repair_With_Equipments = {
36
- name: string
37
- display_name: string
38
- description: string
39
- equipment_id: string
40
- power_output_MWh?: number
41
- cost_per_MWh?: number
42
- category?: string
43
- }
44
-
45
- export type Api_Update_Repair = {
46
- name?: string
47
- display_name?: string
48
- description: string
49
- power_output_MWh?: number
50
- cost_per_MWh?: number
51
- category?: string
52
- }
53
-
54
- export type Api_Repair_Dto = {
55
- id: string
56
- name: string
57
- display_name: string
58
- description: string
59
- start_date: string
60
- end_date: string
61
- projects: Api_Projects[]
62
- equipments: Api_Equipment_Full_Dto[]
63
- }
1
+ export type Api_Team = {
2
+ id: string
3
+ display_name: string
4
+ }
5
+
6
+ export type Api_Equipment_Short_Dto = {
7
+ id: string
8
+ name: string
9
+ }
10
+
11
+ export type Api_Repairs = {
12
+ id: string
13
+ name: string
14
+ }
15
+
16
+ export type Api_Projects = {
17
+ id: string
18
+ name: string
19
+ }
20
+
21
+ export type OptionFilters = {
22
+ teams?: Api_Team[]
23
+ equipments?: Api_Equipment_Short_Dto[]
24
+ }
25
+
26
+ export type Api_Equipment_Full_Dto = {
27
+ id: string
28
+ model: null | string
29
+ name: string
30
+ registration_number: string
31
+ repair_frequency: number
32
+ repair_range: number
33
+ }
34
+
35
+ export type Api_Task_Video_Source = {
36
+ id: string
37
+ name: string
38
+ work_zones_by_tasks: Array<{
39
+ coordinates: { x0: number; x1: number; y0: number; y1: number }
40
+ id: string
41
+ tasks: unknown[]
42
+ title: string
43
+ }>
44
+ }
45
+
46
+ export type Api_Create_Repair_With_Equipments = {
47
+ name: string
48
+ display_name: string
49
+ description: string
50
+ equipment_id: string
51
+ power_output_MWh?: number
52
+ cost_per_MWh?: number
53
+ category?: string
54
+ }
55
+
56
+ export type Api_Update_Repair = {
57
+ name?: string
58
+ display_name?: string
59
+ description: string
60
+ power_output_MWh?: number
61
+ cost_per_MWh?: number
62
+ category?: string
63
+ }
64
+
65
+ export type Api_Repair_Dto = {
66
+ id: string
67
+ name: string
68
+ display_name: string
69
+ description: string
70
+ start_date: string
71
+ end_date: string
72
+ projects: Api_Projects[]
73
+ equipments: Api_Equipment_Full_Dto[]
74
+ }