shared-ritm 1.2.64 → 1.2.66

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 (58) hide show
  1. package/README.md +103 -103
  2. package/dist/index.css +1 -1
  3. package/dist/shared-ritm.es.js +3937 -3934
  4. package/dist/shared-ritm.umd.js +7 -7
  5. package/dist/types/api/services/SearchService.d.ts +7 -0
  6. package/dist/types/api/settings/ApiService.d.ts +1 -0
  7. package/dist/types/api/types/Api_Search.d.ts +43 -0
  8. package/dist/types/api/types/Api_Users.d.ts +43 -0
  9. package/dist/types/index.d.ts +4 -2
  10. package/package.json +63 -63
  11. package/src/api/services/ControlsService.ts +64 -64
  12. package/src/api/services/GanttService.ts +17 -17
  13. package/src/api/services/InstrumentsService.ts +22 -22
  14. package/src/api/services/MetricsService.ts +109 -109
  15. package/src/api/services/ProjectsService.ts +67 -67
  16. package/src/api/services/RepairsService.ts +100 -100
  17. package/src/api/services/SearchService.ts +15 -0
  18. package/src/api/services/VideoService.ts +14 -14
  19. package/src/api/settings/ApiService.ts +1 -0
  20. package/src/api/types/Api_Controls.ts +72 -72
  21. package/src/api/types/Api_Files.ts +1 -1
  22. package/src/api/types/Api_Instruments.ts +133 -133
  23. package/src/api/types/Api_Projects.ts +55 -55
  24. package/src/api/types/Api_Repairs.ts +93 -93
  25. package/src/api/types/Api_Search.ts +48 -0
  26. package/src/api/types/Api_Tasks.ts +155 -155
  27. package/src/common/app-checkbox/AppCheckbox.vue +26 -26
  28. package/src/common/app-dialogs/AppConfirmDialog.vue +99 -99
  29. package/src/common/app-dropdown/AppDropdown.vue +31 -31
  30. package/src/common/app-input/AppInput.vue +148 -148
  31. package/src/common/app-select/AppSelect.vue +157 -157
  32. package/src/common/app-sheet/AppSheet.vue +120 -120
  33. package/src/common/app-sidebar/components/SidebarMenuItem.vue +148 -148
  34. package/src/common/app-table/AppTable.vue +250 -250
  35. package/src/common/app-table/AppTableLayout.vue +111 -111
  36. package/src/common/app-table/components/ModalSelect.vue +264 -264
  37. package/src/common/app-table/components/TableModal.vue +329 -329
  38. package/src/common/app-table/components/TablePagination.vue +152 -152
  39. package/src/common/app-table/components/TableSearch.vue +76 -76
  40. package/src/common/app-table/controllers/useBaseTable.ts +42 -42
  41. package/src/common/app-table/controllers/useColumnSelector.ts +38 -38
  42. package/src/common/app-table/controllers/useTableModel.ts +93 -93
  43. package/src/common/app-toggle/AppToggle.vue +23 -23
  44. package/src/common/app-wrapper/AppWrapper.vue +28 -28
  45. package/src/icons/components/table-filter-icon.vue +30 -30
  46. package/src/icons/dialogs/RemoveIcon.vue +12 -12
  47. package/src/icons/dialogs/SafetyIcon.vue +12 -12
  48. package/src/icons/task/attention-icon.vue +13 -13
  49. package/src/icons/task/clock-icon.vue +10 -10
  50. package/src/icons/task/delete-icon.vue +10 -10
  51. package/src/icons/task/fire-icon.vue +16 -16
  52. package/src/index.ts +4 -1
  53. package/src/main.ts +28 -28
  54. package/src/shared/styles/general.css +125 -125
  55. package/src/styles/variables.sass +12 -12
  56. package/src/utils/confirm.ts +12 -12
  57. package/src/utils/helpers.ts +39 -39
  58. package/src/utils/notification.ts +9 -9
@@ -0,0 +1,7 @@
1
+ import ApiService, { ResponseApi } from '@/api/settings/ApiService';
2
+ import { Api_Search_User } from '@/api/types/Api_Search';
3
+ declare class SearchService extends ApiService {
4
+ fetchSearchUsers(params: any): Promise<ResponseApi<Api_Search_User>>;
5
+ }
6
+ export default function useSearchService(): SearchService;
7
+ export {};
@@ -9,6 +9,7 @@ export type ResponseApi<T> = {
9
9
  per_page: number;
10
10
  total: number;
11
11
  total_pages: number;
12
+ filter_value?: string;
12
13
  };
13
14
  export default class ApiService {
14
15
  private axiosInstance;
@@ -0,0 +1,43 @@
1
+ export type Api_Search_User_Passes = {
2
+ id: string;
3
+ type: string;
4
+ uuid: string;
5
+ };
6
+ export type Api_Search_User_Positions = {
7
+ id: string;
8
+ name: string;
9
+ display_name: string;
10
+ description: string;
11
+ };
12
+ export type Api_Search_User_Roles = {
13
+ id: string;
14
+ name: string;
15
+ display_name: string;
16
+ };
17
+ export type Api_Search_User_Teams = {
18
+ id: string;
19
+ name: string;
20
+ display_name: string;
21
+ roles: Api_Search_User_Roles[];
22
+ };
23
+ export type Api_Search_User_Photos = {
24
+ id: string;
25
+ name: string;
26
+ path: string;
27
+ type: string;
28
+ };
29
+ export type Api_Search_User = {
30
+ id: string;
31
+ full_name: string;
32
+ last_name: string;
33
+ first_name: string;
34
+ patronymic: string;
35
+ email: string;
36
+ phone: string;
37
+ divisions: string;
38
+ personnel_number: string;
39
+ passes: Api_Search_User_Passes[];
40
+ positions: Api_Search_User_Positions[];
41
+ teams: Api_Search_User_Teams[];
42
+ photos: Api_Search_User_Photos[];
43
+ };
@@ -0,0 +1,43 @@
1
+ export type Api_Search_User_Passes = {
2
+ id: string;
3
+ type: string;
4
+ uuid: string;
5
+ };
6
+ export type Api_Search_User_Positions = {
7
+ id: string;
8
+ name: string;
9
+ display_name: string;
10
+ description: string;
11
+ };
12
+ export type Api_Search_User_Roles = {
13
+ id: string;
14
+ name: string;
15
+ display_name: string;
16
+ };
17
+ export type Api_Search_User_Teams = {
18
+ id: string;
19
+ name: string;
20
+ display_name: string;
21
+ roles: Api_Search_User_Roles[];
22
+ };
23
+ export type Api_Search_User_Photos = {
24
+ id: string;
25
+ name: string;
26
+ path: string;
27
+ type: string;
28
+ };
29
+ export type Api_Search_User = {
30
+ id: string;
31
+ full_name: string;
32
+ last_name: string;
33
+ first_name: string;
34
+ patronymic: string;
35
+ email: string;
36
+ phone: string;
37
+ divisions: string;
38
+ personnel_number: string;
39
+ passes: Api_Search_User_Passes[];
40
+ positions: Api_Search_User_Positions[];
41
+ teams: Api_Search_User_Teams[];
42
+ photos: Api_Search_User_Photos[];
43
+ };
@@ -21,6 +21,7 @@ import AppTableModal from '@/common/app-table/components/TableModal.vue';
21
21
  import AppTable from '@/common/app-table/AppTable.vue';
22
22
  import AppTableLayout from '@/common/app-table/AppTableLayout.vue';
23
23
  import AppModalSelect from '@/common/app-table/components/ModalSelect.vue';
24
+ import ApiService from '@/api/settings/ApiService';
24
25
  import useGanttService from '@/api/services/GanttService';
25
26
  import useMetricsService from '@/api/services/MetricsService';
26
27
  import useProjectsService from '@/api/services/ProjectsService';
@@ -30,10 +31,10 @@ import useAuthService from '@/api/services/AuthService';
30
31
  import useFileService from '@/api/services/FileService';
31
32
  import useVideoService from '@/api/services/VideoService';
32
33
  import useInstrumentsService from '@/api/services/InstrumentsService';
33
- import ApiService from '@/api/settings/ApiService';
34
34
  import useControlsService from '@/api/services/ControlsService';
35
+ import useSearchService from '@/api/services/SearchService';
35
36
  export { AppButton, AppCheckbox, AppDatePicker, AppInput, AppInputSearch, AppLayout, AppLayoutHeader, AppLayoutPage, AppLoader, AppSelect, AppSheet, AppSidebar, AppToggle, AppWrapper, AppConfirmDialog, AppDropdown, AppTablePagination, AppTableSearch, AppTableModal, AppTable, AppTableLayout, AppModalSelect, };
36
- export { ApiService, useAuthService, useGanttService, useMetricsService, useProjectsService, useRepairsService, useTasksService, useFileService, useControlsService, useVideoService, useInstrumentsService, };
37
+ export { ApiService, useAuthService, useGanttService, useMetricsService, useProjectsService, useRepairsService, useTasksService, useFileService, useControlsService, useVideoService, useInstrumentsService, useSearchService, };
37
38
  export { useBaseTable } from './common/app-table/controllers/useBaseTable';
38
39
  export { useTableModel } from './common/app-table/controllers/useTableModel';
39
40
  export { useColumnSelector } from './common/app-table/controllers/useColumnSelector';
@@ -45,3 +46,4 @@ export * from './api/types/Api_Repairs';
45
46
  export * from './api/types/Api_Projects';
46
47
  export * from './api/types/Api_Controls';
47
48
  export * from './api/types/Api_Instruments';
49
+ export * from './api/types/Api_Search';
package/package.json CHANGED
@@ -1,63 +1,63 @@
1
- {
2
- "name": "shared-ritm",
3
- "version": "1.2.64",
4
- "private": false,
5
- "files": [
6
- "dist",
7
- "src"
8
- ],
9
- "main": "dist/shared-ritm.umd.js",
10
- "type": "module",
11
- "module": "./dist/shared-ritm.es.js",
12
- "types": "./dist/types/index.d.ts",
13
- "exports": {
14
- ".": {
15
- "import": "./dist/shared-ritm.es.js",
16
- "require": "./dist/shared-ritm.umd.js",
17
- "default": "./dist/shared-ritm.es.js",
18
- "types": "./dist/types/index.d.ts"
19
- },
20
- "./style": "./dist/index.css"
21
- },
22
- "scripts": {
23
- "dev": "vite",
24
- "build": "vite build && tsc --emitDeclarationOnly",
25
- "typecheck": "vue-tsc --noEmit",
26
- "lint": "eslint --fix",
27
- "format": "prettier -w -u ."
28
- },
29
- "dependencies": {
30
- "@quasar/extras": "^1.16.17",
31
- "@vueuse/core": "^10.1.2",
32
- "axios": "^1.7.7",
33
- "vue": "^3.5.12",
34
- "vue-router": "^4.0.3"
35
- },
36
- "peerDependencies": {
37
- "quasar": "^2.18.1"
38
- },
39
- "devDependencies": {
40
- "@quasar/vite-plugin": "^1.9.0",
41
- "@rollup/pluginutils": "^5.1.3",
42
- "@types/node": "^22.7.9",
43
- "@typescript-eslint/eslint-plugin": "^4.25.0",
44
- "@typescript-eslint/parser": "^4.25.0",
45
- "@vitejs/plugin-vue": "^5.1.4",
46
- "@vue/compiler-sfc": "^3.0.5",
47
- "@vue/eslint-config-prettier": "^6.0.0",
48
- "@vue/eslint-config-typescript": "^7.0.0",
49
- "eslint": "^7.27.0",
50
- "eslint-plugin-prettier": "^3.4.0",
51
- "eslint-plugin-vue": "^7.10.0",
52
- "install": "^0.13.0",
53
- "npm": "^11.4.0",
54
- "prettier": "^2.3.0",
55
- "quasar": "^2.18.1",
56
- "rollup-plugin-visualizer": "^5.14.0",
57
- "sass": "^1.80.4",
58
- "typescript": "^5.6.3",
59
- "vite": "^5.4.9",
60
- "vite-plugin-css-modules": "^0.0.1",
61
- "vue-tsc": "^2.1.6"
62
- }
63
- }
1
+ {
2
+ "name": "shared-ritm",
3
+ "version": "1.2.66",
4
+ "private": false,
5
+ "files": [
6
+ "dist",
7
+ "src"
8
+ ],
9
+ "main": "dist/shared-ritm.umd.js",
10
+ "type": "module",
11
+ "module": "./dist/shared-ritm.es.js",
12
+ "types": "./dist/types/index.d.ts",
13
+ "exports": {
14
+ ".": {
15
+ "import": "./dist/shared-ritm.es.js",
16
+ "require": "./dist/shared-ritm.umd.js",
17
+ "default": "./dist/shared-ritm.es.js",
18
+ "types": "./dist/types/index.d.ts"
19
+ },
20
+ "./style": "./dist/index.css"
21
+ },
22
+ "scripts": {
23
+ "dev": "vite",
24
+ "build": "vite build && tsc --emitDeclarationOnly",
25
+ "typecheck": "vue-tsc --noEmit",
26
+ "lint": "eslint --fix",
27
+ "format": "prettier -w -u ."
28
+ },
29
+ "dependencies": {
30
+ "@quasar/extras": "^1.16.17",
31
+ "@vueuse/core": "^10.1.2",
32
+ "axios": "^1.7.7",
33
+ "vue": "^3.5.12",
34
+ "vue-router": "^4.0.3"
35
+ },
36
+ "peerDependencies": {
37
+ "quasar": "^2.18.1"
38
+ },
39
+ "devDependencies": {
40
+ "@quasar/vite-plugin": "^1.9.0",
41
+ "@rollup/pluginutils": "^5.1.3",
42
+ "@types/node": "^22.7.9",
43
+ "@typescript-eslint/eslint-plugin": "^4.25.0",
44
+ "@typescript-eslint/parser": "^4.25.0",
45
+ "@vitejs/plugin-vue": "^5.1.4",
46
+ "@vue/compiler-sfc": "^3.0.5",
47
+ "@vue/eslint-config-prettier": "^6.0.0",
48
+ "@vue/eslint-config-typescript": "^7.0.0",
49
+ "eslint": "^7.27.0",
50
+ "eslint-plugin-prettier": "^3.4.0",
51
+ "eslint-plugin-vue": "^7.10.0",
52
+ "install": "^0.13.0",
53
+ "npm": "^11.4.0",
54
+ "prettier": "^2.3.0",
55
+ "quasar": "^2.18.1",
56
+ "rollup-plugin-visualizer": "^5.14.0",
57
+ "sass": "^1.80.4",
58
+ "typescript": "^5.6.3",
59
+ "vite": "^5.4.9",
60
+ "vite-plugin-css-modules": "^0.0.1",
61
+ "vue-tsc": "^2.1.6"
62
+ }
63
+ }
@@ -1,64 +1,64 @@
1
- import ApiService, { ResponseApi } from '@/api/settings/ApiService'
2
-
3
- import { Api_ControlLogs_Dto, Api_ControlZones_Dto } from '@/api/types/Api_Controls'
4
-
5
- class ControlsService extends ApiService {
6
- public fetchControlZones(params: Record<string, any>): Promise<ResponseApi<Api_ControlZones_Dto[]>> {
7
- return this.get('/frame/list', { params })
8
- }
9
-
10
- public async fetchControlZone(id: string): Promise<ResponseApi<Api_ControlZones_Dto>> {
11
- return this.get(`/frame/${id}`)
12
- }
13
-
14
- public createControlZone(params: any): Promise<ResponseApi<any>> {
15
- return this.post<any, ResponseApi<any>>('/frame', params)
16
- }
17
-
18
- public editControlZone(id: string, params: any): Promise<ResponseApi<any>> {
19
- return this.put<any, ResponseApi<any>>(`/frame/${id}`, params)
20
- }
21
-
22
- public deleteControlZone(id: string): Promise<any> {
23
- return this.delete<ResponseApi<any>>(`/frame/${id}`)
24
- }
25
-
26
- public fetchControlLogs(params: Record<string, any>): Promise<ResponseApi<Api_ControlLogs_Dto[]>> {
27
- return this.get('/exposed_equipment_zones/list', { params })
28
- }
29
-
30
- public fetchControllers(params: Record<string, any>): Promise<ResponseApi<Api_ControlLogs_Dto[]>> {
31
- return this.get('/frame/controllers/list', { params })
32
- }
33
-
34
- public fetchUsersWithPasses(): Promise<any> {
35
- return this.get('inspector/users-with-passes')
36
- }
37
-
38
- public fetchWarehousesList(): Promise<any> {
39
- return this.get('tasks/warehouse/list?only_outside_exposed_equipment_zone=1')
40
- }
41
-
42
- public manualEntry(params: any): Promise<ResponseApi<any>> {
43
- return this.post<any, ResponseApi<any>>('exposed_equipment_zones/hand/enter', params)
44
- }
45
-
46
- public manualExit(params: any): Promise<ResponseApi<any>> {
47
- return this.post<any, ResponseApi<any>>('exposed_equipment_zones/hand/exit', params)
48
- }
49
-
50
- public deleteControlLogs(params: any): Promise<any> {
51
- return this.delete<ResponseApi<any>>(`exposed_equipment_zones`, params)
52
- }
53
-
54
- public fetchInstrumentTypeList(params: any): Promise<any> {
55
- return this.get<ResponseApi<any>>(`search/instrument_types`, { params })
56
- }
57
- }
58
-
59
- let api: ControlsService
60
-
61
- export default function useControlsService() {
62
- if (!api) api = new ControlsService()
63
- return api
64
- }
1
+ import ApiService, { ResponseApi } from '@/api/settings/ApiService'
2
+
3
+ import { Api_ControlLogs_Dto, Api_ControlZones_Dto } from '@/api/types/Api_Controls'
4
+
5
+ class ControlsService extends ApiService {
6
+ public fetchControlZones(params: Record<string, any>): Promise<ResponseApi<Api_ControlZones_Dto[]>> {
7
+ return this.get('/frame/list', { params })
8
+ }
9
+
10
+ public async fetchControlZone(id: string): Promise<ResponseApi<Api_ControlZones_Dto>> {
11
+ return this.get(`/frame/${id}`)
12
+ }
13
+
14
+ public createControlZone(params: any): Promise<ResponseApi<any>> {
15
+ return this.post<any, ResponseApi<any>>('/frame', params)
16
+ }
17
+
18
+ public editControlZone(id: string, params: any): Promise<ResponseApi<any>> {
19
+ return this.put<any, ResponseApi<any>>(`/frame/${id}`, params)
20
+ }
21
+
22
+ public deleteControlZone(id: string): Promise<any> {
23
+ return this.delete<ResponseApi<any>>(`/frame/${id}`)
24
+ }
25
+
26
+ public fetchControlLogs(params: Record<string, any>): Promise<ResponseApi<Api_ControlLogs_Dto[]>> {
27
+ return this.get('/exposed_equipment_zones/list', { params })
28
+ }
29
+
30
+ public fetchControllers(params: Record<string, any>): Promise<ResponseApi<Api_ControlLogs_Dto[]>> {
31
+ return this.get('/frame/controllers/list', { params })
32
+ }
33
+
34
+ public fetchUsersWithPasses(): Promise<any> {
35
+ return this.get('inspector/users-with-passes')
36
+ }
37
+
38
+ public fetchWarehousesList(): Promise<any> {
39
+ return this.get('tasks/warehouse/list?only_outside_exposed_equipment_zone=1')
40
+ }
41
+
42
+ public manualEntry(params: any): Promise<ResponseApi<any>> {
43
+ return this.post<any, ResponseApi<any>>('exposed_equipment_zones/hand/enter', params)
44
+ }
45
+
46
+ public manualExit(params: any): Promise<ResponseApi<any>> {
47
+ return this.post<any, ResponseApi<any>>('exposed_equipment_zones/hand/exit', params)
48
+ }
49
+
50
+ public deleteControlLogs(params: any): Promise<any> {
51
+ return this.delete<ResponseApi<any>>(`exposed_equipment_zones`, params)
52
+ }
53
+
54
+ public fetchInstrumentTypeList(params: any): Promise<any> {
55
+ return this.get<ResponseApi<any>>(`search/instrument_types`, { params })
56
+ }
57
+ }
58
+
59
+ let api: ControlsService
60
+
61
+ export default function useControlsService() {
62
+ if (!api) api = new ControlsService()
63
+ return api
64
+ }
@@ -1,17 +1,17 @@
1
- import ApiService from '@/api/settings/ApiService'
2
-
3
- class GanttService extends ApiService {
4
- public async fetchCriticalPathTasks(params: string): Promise<any> {
5
- return await this.get(`gantt/get_list_task_on_critical_path?${params}`)
6
- }
7
- public async fetchGanttList(params: string): Promise<any> {
8
- return await this.get(`/list/tasks/search?${params}&gantt=1`)
9
- }
10
- }
11
-
12
- let api: GanttService
13
-
14
- export default function useGanttService() {
15
- if (!api) api = new GanttService()
16
- return api
17
- }
1
+ import ApiService from '@/api/settings/ApiService'
2
+
3
+ class GanttService extends ApiService {
4
+ public async fetchCriticalPathTasks(params: string): Promise<any> {
5
+ return await this.get(`gantt/get_list_task_on_critical_path?${params}`)
6
+ }
7
+ public async fetchGanttList(params: string): Promise<any> {
8
+ return await this.get(`/list/tasks/search?${params}&gantt=1`)
9
+ }
10
+ }
11
+
12
+ let api: GanttService
13
+
14
+ export default function useGanttService() {
15
+ if (!api) api = new GanttService()
16
+ return api
17
+ }
@@ -1,22 +1,22 @@
1
- import ApiService from '@/api/settings/ApiService'
2
- import { Api_instruments_HistoryResponse } from '@/api/types/Api_Instruments'
3
-
4
- class InstrumentsService extends ApiService {
5
- public async fetchUserInstrumentsHistory(id: string, page: number): Promise<Api_instruments_HistoryResponse> {
6
- const params = {
7
- status: 'issued',
8
- page,
9
- desc: 'desc',
10
- column: 'updated_at',
11
- }
12
-
13
- return await this.get(`users/${id}/instruments`, { params })
14
- }
15
- }
16
-
17
- let api: InstrumentsService
18
-
19
- export default function useInstrumentsService() {
20
- if (!api) api = new InstrumentsService()
21
- return api
22
- }
1
+ import ApiService from '@/api/settings/ApiService'
2
+ import { Api_instruments_HistoryResponse } from '@/api/types/Api_Instruments'
3
+
4
+ class InstrumentsService extends ApiService {
5
+ public async fetchUserInstrumentsHistory(id: string, page: number): Promise<Api_instruments_HistoryResponse> {
6
+ const params = {
7
+ status: 'issued',
8
+ page,
9
+ desc: 'desc',
10
+ column: 'updated_at',
11
+ }
12
+
13
+ return await this.get(`users/${id}/instruments`, { params })
14
+ }
15
+ }
16
+
17
+ let api: InstrumentsService
18
+
19
+ export default function useInstrumentsService() {
20
+ if (!api) api = new InstrumentsService()
21
+ return api
22
+ }