shared-ritm 1.1.47 → 1.1.48

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.
@@ -4,7 +4,6 @@ declare class RepairsService extends ApiService {
4
4
  fetchFilters(fullParams: string): Promise<OptionFilters>;
5
5
  fetchRepairs(isQuery: boolean, queries?: string, hasTeams?: boolean | string, teamsFilter?: string, typeFilter?: string): Promise<ResponseApi<Api_Repair_Dto[]>>;
6
6
  fetchEquipment(): Promise<ResponseApi<Api_Equipment_Full_Dto[]>>;
7
- fetchEquipmentPagination(params: any): Promise<ResponseApi<Api_Equipment_Full_Dto[]>>;
8
7
  createRepair(payload: Api_Create_Repair_With_Equipments): Promise<any>;
9
8
  startRepair(id: string): Promise<void>;
10
9
  finishRepair(id: string): Promise<void>;
@@ -1,11 +1,13 @@
1
1
  import ApiService, { ResponseApi } from '@/api/settings/ApiService';
2
2
  import { Api_Tasks_Dto, Api_Tasks_Task_Dto } from '@/api/types/Api_Tasks';
3
+ import { Api_Equipment_Full_Dto } from '@/api/types/Api_Repairs';
3
4
  declare class TasksService extends ApiService {
4
5
  fetchTaskById(id: string): Promise<ResponseApi<Api_Tasks_Task_Dto>>;
5
6
  fetchTasksList(params: any): Promise<ResponseApi<Api_Tasks_Dto[]>>;
6
7
  fetchSubtasksList(id: string): Promise<ResponseApi<Api_Tasks_Dto[]>>;
7
8
  fetchTaskBranch(id: string): Promise<ResponseApi<any>>;
8
9
  fetchInstrumentsList(params: any): Promise<ResponseApi<any[]>>;
10
+ fetchEquipment(params: any): Promise<ResponseApi<Api_Equipment_Full_Dto[]>>;
9
11
  createTask(payload: any): Promise<ResponseApi<any>>;
10
12
  mergeTask(payload: {
11
13
  name: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shared-ritm",
3
- "version": "1.1.47",
3
+ "version": "1.1.48",
4
4
  "private": false,
5
5
  "files": [
6
6
  "dist",
@@ -31,10 +31,6 @@ class RepairsService extends ApiService {
31
31
  return this.get('repairs/equipment/list?per_page=100000')
32
32
  }
33
33
 
34
- public fetchEquipmentPagination(params: any): Promise<ResponseApi<Api_Equipment_Full_Dto[]>> {
35
- return this.get('repairs/equipment/list', { params })
36
- }
37
-
38
34
  public createRepair(payload: Api_Create_Repair_With_Equipments) {
39
35
  return this.post<Api_Create_Repair_With_Equipments, any>('/repairs/equipments', payload)
40
36
  }
@@ -1,43 +1,48 @@
1
- import ApiService, { ResponseApi } from '@/api/settings/ApiService'
2
- import { Api_Tasks_Dto, Api_Tasks_Task_Dto } from '@/api/types/Api_Tasks'
3
-
4
- class TasksService extends ApiService {
5
- public async fetchTaskById(id: string): Promise<ResponseApi<Api_Tasks_Task_Dto>> {
6
- return await this.get(`/tasks/${id}`)
7
- }
8
-
9
- public async fetchTasksList(params: any): Promise<ResponseApi<Api_Tasks_Dto[]>> {
10
- return await this.get('/list/tasks/search', { params })
11
- }
12
-
13
- public async fetchSubtasksList(id: string): Promise<ResponseApi<Api_Tasks_Dto[]>> {
14
- return await this.get(`/task/${id}/subtasks/list`)
15
- }
16
-
17
- public async fetchTaskBranch(id: string): Promise<ResponseApi<any>> {
18
- return await this.get(`/get_list_task_branch?task_id=${id}`)
19
- }
20
-
21
- public async fetchInstrumentsList(params: any): Promise<ResponseApi<any[]>> {
22
- return await this.get(`admin/instruments`, { params })
23
- }
24
-
25
- public async createTask(payload: any): Promise<ResponseApi<any>> {
26
- return await this.post(`tasks`, payload)
27
- }
28
-
29
- public async mergeTask(payload: { name: string; tasks_id: string[] }): Promise<ResponseApi<any>> {
30
- return await this.post(`tasks/merge`, payload)
31
- }
32
-
33
- public async deleteTask(id: string): Promise<any> {
34
- return await this.delete(`tasks/${id}`)
35
- }
36
- }
37
-
38
- let api: TasksService
39
-
40
- export default function useTasksService() {
41
- if (!api) api = new TasksService()
42
- return api
43
- }
1
+ import ApiService, { ResponseApi } from '@/api/settings/ApiService'
2
+ import { Api_Tasks_Dto, Api_Tasks_Task_Dto } from '@/api/types/Api_Tasks'
3
+ import { Api_Equipment_Full_Dto } from '@/api/types/Api_Repairs'
4
+
5
+ class TasksService extends ApiService {
6
+ public async fetchTaskById(id: string): Promise<ResponseApi<Api_Tasks_Task_Dto>> {
7
+ return await this.get(`/tasks/${id}`)
8
+ }
9
+
10
+ public async fetchTasksList(params: any): Promise<ResponseApi<Api_Tasks_Dto[]>> {
11
+ return await this.get('/list/tasks/search', { params })
12
+ }
13
+
14
+ public async fetchSubtasksList(id: string): Promise<ResponseApi<Api_Tasks_Dto[]>> {
15
+ return await this.get(`/task/${id}/subtasks/list`)
16
+ }
17
+
18
+ public async fetchTaskBranch(id: string): Promise<ResponseApi<any>> {
19
+ return await this.get(`/get_list_task_branch?task_id=${id}`)
20
+ }
21
+
22
+ public async fetchInstrumentsList(params: any): Promise<ResponseApi<any[]>> {
23
+ return await this.get(`admin/instruments`, { params })
24
+ }
25
+
26
+ public fetchEquipment(params: any): Promise<ResponseApi<Api_Equipment_Full_Dto[]>> {
27
+ return this.get('repairs/equipment/list', { params })
28
+ }
29
+
30
+ public async createTask(payload: any): Promise<ResponseApi<any>> {
31
+ return await this.post(`tasks`, payload)
32
+ }
33
+
34
+ public async mergeTask(payload: { name: string; tasks_id: string[] }): Promise<ResponseApi<any>> {
35
+ return await this.post(`tasks/merge`, payload)
36
+ }
37
+
38
+ public async deleteTask(id: string): Promise<any> {
39
+ return await this.delete(`tasks/${id}`)
40
+ }
41
+ }
42
+
43
+ let api: TasksService
44
+
45
+ export default function useTasksService() {
46
+ if (!api) api = new TasksService()
47
+ return api
48
+ }