tsv2-library 1.0.61-alpha.3 → 1.0.61-alpha.30
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/dist/loading-0-1a7cddc8.js +4 -0
- package/dist/loading-1-892eee7c.js +4 -0
- package/dist/loading-2-bf39c889.js +4 -0
- package/dist/loading-3-f1ea4b15.js +4 -0
- package/dist/src/build-entry.d.ts +1 -2827
- package/dist/src/components/v2/ButtonSelectTree/ButtonSelectTree.vue.d.ts +9 -3
- package/dist/src/components/v2/Calendar/Calendar.vue.d.ts +1 -1
- package/dist/src/components/v2/DialogReportMissing/DialogReportMissing.vue.d.ts +9 -0
- package/dist/src/components/v2/DialogSelectTree/DialogSelectTree.vue.d.ts +11 -3
- package/dist/src/components/v2/Form/Form.vue.d.ts +2 -0
- package/dist/src/components/v2/HardwareSync/HardwareSync.vue.d.ts +2 -2
- package/dist/src/components/v2/ImageCompressor/BackgroundImageCropper.vue.d.ts +1 -1
- package/dist/src/components/v2/Tree/Tree.vue.d.ts +7 -3
- package/dist/src/components/v2/Tree/helpers/filterNodeKeys.helper.d.ts +1 -1
- package/dist/src/dto/missing.dto.d.ts +2 -0
- package/dist/src/presets/button/index.js +7 -2
- package/dist/src/presets/toast/index.js +1 -1
- package/dist/src/types/assets.type.d.ts +2 -3
- package/dist/src/utils/getImageURL.util.d.ts +11 -2
- package/dist/src/utils/index.d.ts +1 -1
- package/dist/style.css +1 -1
- package/dist/tsv2-library.es.js +47804 -53288
- package/dist/tsv2-library.umd.js +47 -609
- package/package.json +3 -1
- package/src/components/v2/ButtonSelectTree/ButtonSelectTree.vue.d.ts +9 -3
- package/src/components/v2/Calendar/Calendar.vue.d.ts +1 -1
- package/src/components/v2/DialogSelectTree/DialogSelectTree.vue.d.ts +11 -3
- package/src/components/v2/Form/Form.vue.d.ts +2 -0
- package/src/components/v2/Tree/Tree.vue.d.ts +7 -3
- package/src/presets/button/index.js +7 -2
- package/src/presets/toast/index.js +1 -1
- package/src/services/damage.service.ts +1 -1
- package/src/services/missing.service.ts +1 -1
- package/dist/loading-0-7762a473.js +0 -4
- package/dist/loading-1-55418796.js +0 -4
- package/dist/loading-2-b6abf641.js +0 -4
- package/dist/loading-3-705786b6.js +0 -4
|
@@ -4,7 +4,7 @@ import { TreeNode } from '../Tree/Tree.vue.d';
|
|
|
4
4
|
import { TSVueIconSeverities } from '../Icon/Icon.vue.d';
|
|
5
5
|
import { Severities } from '../../../utils/getSeverityByAssetStatus.util';
|
|
6
6
|
|
|
7
|
-
export type KeysModelValue =
|
|
7
|
+
export type KeysModelValue = string[] | undefined;
|
|
8
8
|
|
|
9
9
|
export interface ButtonSelectTreeProps {
|
|
10
10
|
/**
|
|
@@ -133,7 +133,7 @@ export interface ButtonSelectTreeProps {
|
|
|
133
133
|
/**
|
|
134
134
|
* Defines the group tree to disable excluded keys
|
|
135
135
|
*/
|
|
136
|
-
excludedKeys?:
|
|
136
|
+
excludedKeys?: string[];
|
|
137
137
|
/**
|
|
138
138
|
* Define wether single selection can be edited or readonly
|
|
139
139
|
* @default true
|
|
@@ -150,6 +150,10 @@ export interface ButtonSelectTreeProps {
|
|
|
150
150
|
* @default false
|
|
151
151
|
*/
|
|
152
152
|
fetchTreeOnButtonRender?: boolean;
|
|
153
|
+
/**
|
|
154
|
+
* Disable level 2 (All > Level 1 > Level 2)
|
|
155
|
+
*/
|
|
156
|
+
disableSubChildren?: boolean;
|
|
153
157
|
}
|
|
154
158
|
|
|
155
159
|
export type ButtonSelectTreeEmits = {
|
|
@@ -171,7 +175,9 @@ export type ButtonSelectTreeEmits = {
|
|
|
171
175
|
*
|
|
172
176
|
* @group Component
|
|
173
177
|
*/
|
|
174
|
-
declare class ButtonSelectTree extends ClassComponent<ButtonSelectTreeProps> {
|
|
178
|
+
declare class ButtonSelectTree extends ClassComponent<ButtonSelectTreeProps> {
|
|
179
|
+
dialogTreeKey: Ref<number>;
|
|
180
|
+
}
|
|
175
181
|
|
|
176
182
|
declare module '@vue/runtime-core' {
|
|
177
183
|
interface GlobalComponents {
|
|
@@ -27,7 +27,7 @@ export interface TSCalendarProps {
|
|
|
27
27
|
*
|
|
28
28
|
* @example [DD,MM,YYY, 00.00.00, DD,MM,YYY, 23.59.59]
|
|
29
29
|
*
|
|
30
|
-
* @default
|
|
30
|
+
* @default true returns [DD,MM,YYY, 00.00.00, DD,MM,YYY, 00.00.00]
|
|
31
31
|
*/
|
|
32
32
|
setEndDateHours?: boolean;
|
|
33
33
|
/**
|
|
@@ -1,9 +1,14 @@
|
|
|
1
1
|
import type { PropType as __PropType } from 'vue';
|
|
2
|
+
import { ReportSourceType } from '../../../dto/missing.dto';
|
|
2
3
|
declare const _sfc_main: import("vue").DefineComponent<{
|
|
3
4
|
id: {
|
|
4
5
|
type: __PropType<string>;
|
|
5
6
|
required: true;
|
|
6
7
|
};
|
|
8
|
+
reportSource: {
|
|
9
|
+
type: __PropType<ReportSourceType>;
|
|
10
|
+
required: true;
|
|
11
|
+
};
|
|
7
12
|
trackingId: {
|
|
8
13
|
type: __PropType<string | undefined>;
|
|
9
14
|
required: false;
|
|
@@ -38,6 +43,10 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
38
43
|
type: __PropType<string>;
|
|
39
44
|
required: true;
|
|
40
45
|
};
|
|
46
|
+
reportSource: {
|
|
47
|
+
type: __PropType<ReportSourceType>;
|
|
48
|
+
required: true;
|
|
49
|
+
};
|
|
41
50
|
trackingId: {
|
|
42
51
|
type: __PropType<string | undefined>;
|
|
43
52
|
required: false;
|
|
@@ -26,7 +26,7 @@ export interface SelectTreeDialogProps {
|
|
|
26
26
|
/**
|
|
27
27
|
* The previously selected tree key to be displayed again.
|
|
28
28
|
*/
|
|
29
|
-
keys?:
|
|
29
|
+
keys?: string[];
|
|
30
30
|
/**
|
|
31
31
|
* The lists to be displayed in the dialog.
|
|
32
32
|
*/
|
|
@@ -57,11 +57,15 @@ export interface SelectTreeDialogProps {
|
|
|
57
57
|
/**
|
|
58
58
|
* Defines the group tree to disable excluded keys
|
|
59
59
|
*/
|
|
60
|
-
excludedKeys?:
|
|
60
|
+
excludedKeys?: string[];
|
|
61
61
|
/**
|
|
62
62
|
* Render hidden dialog to trigger fetch tree
|
|
63
63
|
*/
|
|
64
64
|
hidden?: boolean;
|
|
65
|
+
/**
|
|
66
|
+
* Disable level 2 (All > Level 1 > Level 2)
|
|
67
|
+
*/
|
|
68
|
+
disableSubChildren?: boolean;
|
|
65
69
|
}
|
|
66
70
|
|
|
67
71
|
type TreeSelectPayload = {
|
|
@@ -76,6 +80,10 @@ export type SelectTreeDialogEmits = {
|
|
|
76
80
|
'hide': [];
|
|
77
81
|
};
|
|
78
82
|
|
|
83
|
+
export interface SelectTreeDialogSlots {
|
|
84
|
+
description: VNode[];
|
|
85
|
+
}
|
|
86
|
+
|
|
79
87
|
/**
|
|
80
88
|
* **TSVue v2 - SelectTreeDialog**
|
|
81
89
|
*
|
|
@@ -86,7 +94,7 @@ export type SelectTreeDialogEmits = {
|
|
|
86
94
|
*/
|
|
87
95
|
declare class SelectTreeDialog extends ClassComponent<
|
|
88
96
|
SelectTreeDialogProps,
|
|
89
|
-
|
|
97
|
+
SelectTreeDialogSlots,
|
|
90
98
|
SelectTreeDialogEmits
|
|
91
99
|
> {}
|
|
92
100
|
|
|
@@ -105,6 +105,8 @@ export type FormEmits = {
|
|
|
105
105
|
* @group components
|
|
106
106
|
*/
|
|
107
107
|
declare class Form extends ClassComponent<FormProps, FormSlots, FormEmits> {
|
|
108
|
+
values: GenericObject;
|
|
109
|
+
errors: ComputedRef<Partial<Record<string, string | undefined>>>;
|
|
108
110
|
/**
|
|
109
111
|
* Wether to keep the dialog remains visible or not after submit.
|
|
110
112
|
*/
|
|
@@ -10,7 +10,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
10
10
|
required: false;
|
|
11
11
|
};
|
|
12
12
|
searchBy: {
|
|
13
|
-
type: __PropType<"
|
|
13
|
+
type: __PropType<"RFID" | "QR" | undefined>;
|
|
14
14
|
required: false;
|
|
15
15
|
};
|
|
16
16
|
bulk: {
|
|
@@ -35,7 +35,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
35
35
|
required: false;
|
|
36
36
|
};
|
|
37
37
|
searchBy: {
|
|
38
|
-
type: __PropType<"
|
|
38
|
+
type: __PropType<"RFID" | "QR" | undefined>;
|
|
39
39
|
required: false;
|
|
40
40
|
};
|
|
41
41
|
bulk: {
|
|
@@ -34,7 +34,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
34
34
|
required: false;
|
|
35
35
|
};
|
|
36
36
|
}>> & {
|
|
37
|
-
onMove?: ((...args: any[]) => any) | undefined;
|
|
38
37
|
onResize?: ((...args: any[]) => any) | undefined;
|
|
38
|
+
onMove?: ((...args: any[]) => any) | undefined;
|
|
39
39
|
}, {}, {}>;
|
|
40
40
|
export default _sfc_main;
|
|
@@ -11,7 +11,7 @@ export interface TreeNode {
|
|
|
11
11
|
/**
|
|
12
12
|
* Mandatory unique key of the node.
|
|
13
13
|
*/
|
|
14
|
-
key?: string
|
|
14
|
+
key?: string;
|
|
15
15
|
/**
|
|
16
16
|
* Label of the node.
|
|
17
17
|
*/
|
|
@@ -71,7 +71,7 @@ export interface TreeNode {
|
|
|
71
71
|
|
|
72
72
|
export interface TreeProps {
|
|
73
73
|
type: 'Group' | 'Category';
|
|
74
|
-
selectedKeys?: TreeSelectionKeys |
|
|
74
|
+
selectedKeys?: TreeSelectionKeys | string[] | undefined;
|
|
75
75
|
selectedTreeNodes?: TreeNode[] | undefined;
|
|
76
76
|
selectionMode?: 'single' | 'checkbox' | undefined;
|
|
77
77
|
/**
|
|
@@ -95,6 +95,10 @@ export interface TreeProps {
|
|
|
95
95
|
* Disable node 'All' selection
|
|
96
96
|
*/
|
|
97
97
|
disableNodeAll?: boolean;
|
|
98
|
+
/**
|
|
99
|
+
* Disable level 2 (All > Level 1 > Level 2)
|
|
100
|
+
*/
|
|
101
|
+
disableSubChildren?: boolean;
|
|
98
102
|
/**
|
|
99
103
|
* Include node All key (-1) on Checkbox Selection
|
|
100
104
|
*
|
|
@@ -124,7 +128,7 @@ export interface TreeProps {
|
|
|
124
128
|
/**
|
|
125
129
|
* Defines the group tree to disable excluded keys
|
|
126
130
|
*/
|
|
127
|
-
excludedKeys?:
|
|
131
|
+
excludedKeys?: string[];
|
|
128
132
|
}
|
|
129
133
|
|
|
130
134
|
export type TreeEmits = {
|
|
@@ -5,7 +5,7 @@ import { TreeSelectionKeys } from '../../../../../node_modules/primevue/tree';
|
|
|
5
5
|
* @param nodeKeys - A collection of selected node keys.
|
|
6
6
|
* @param includeNodeAllKey - Whether to include the "-1" key (representing "All").
|
|
7
7
|
*/
|
|
8
|
-
export declare const parseNodeKeys: (nodeKeys: TreeSelectionKeys, includeNodeAllKey?: boolean) =>
|
|
8
|
+
export declare const parseNodeKeys: (nodeKeys: TreeSelectionKeys, includeNodeAllKey?: boolean) => string[];
|
|
9
9
|
/**
|
|
10
10
|
* Filters a collection of selected node keys based on specific criteria.
|
|
11
11
|
*
|
|
@@ -449,7 +449,7 @@ export default {
|
|
|
449
449
|
|
|
450
450
|
// Disabled
|
|
451
451
|
{
|
|
452
|
-
'!
|
|
452
|
+
'!pointer-events-none !cursor-default':
|
|
453
453
|
context.disabled || props.disabled,
|
|
454
454
|
},
|
|
455
455
|
|
|
@@ -463,9 +463,14 @@ export default {
|
|
|
463
463
|
},
|
|
464
464
|
// Outlined Disabled
|
|
465
465
|
{
|
|
466
|
-
'!ring-1 !ring-offset-0 !ring-general-200':
|
|
466
|
+
'!text-general-200 !ring-1 !ring-offset-0 !ring-general-200':
|
|
467
467
|
(props.disabled || context.disabled) && props.outlined,
|
|
468
468
|
},
|
|
469
|
+
// Text Disabled
|
|
470
|
+
{
|
|
471
|
+
'!text-general-200':
|
|
472
|
+
(props.disabled || context.disabled) && props.text,
|
|
473
|
+
},
|
|
469
474
|
|
|
470
475
|
// Transitions
|
|
471
476
|
'transition duration-200 ease-in-out',
|
|
@@ -62,14 +62,13 @@ export type Asset = {
|
|
|
62
62
|
updatedAt?: string;
|
|
63
63
|
rfid?: string;
|
|
64
64
|
qr?: string;
|
|
65
|
-
|
|
66
|
-
firstImageMedium?: string;
|
|
67
|
-
firstImageBig?: string;
|
|
65
|
+
firstImage?: string;
|
|
68
66
|
secondImageSmall?: string;
|
|
69
67
|
secondImageMedium?: string;
|
|
70
68
|
secondImageBig?: string;
|
|
71
69
|
assetImageSmall?: string;
|
|
72
70
|
assetImageMedium?: string;
|
|
73
71
|
assetImageBig?: string;
|
|
72
|
+
assetImage?: string;
|
|
74
73
|
setDefault?: 'firstImage' | 'secondImage';
|
|
75
74
|
};
|
|
@@ -1,2 +1,11 @@
|
|
|
1
|
-
declare const
|
|
2
|
-
export
|
|
1
|
+
export declare const buildFileURL: (name?: string, width?: number, height?: number) => string;
|
|
2
|
+
export declare const fetchBlobFile: (url: string, token: string) => Promise<Blob>;
|
|
3
|
+
/**
|
|
4
|
+
*
|
|
5
|
+
* @param fileUrl The full URL
|
|
6
|
+
* @param fileName Custom File name
|
|
7
|
+
* @param immediateRevoke Immediately revoke the object URL after download - default to true
|
|
8
|
+
* @returns
|
|
9
|
+
*/
|
|
10
|
+
export declare const downloadFile: (fileUrl: string, fileName: string, immediateRevoke?: boolean) => Promise<string>;
|
|
11
|
+
export declare const getImageURL: (name?: string | null, width?: number, height?: number, returnURLOnly?: boolean) => Promise<string | undefined>;
|
|
@@ -3,7 +3,7 @@ import handleTokenExpiration from './handleTokenExpiration.util';
|
|
|
3
3
|
import exportToExcel from './exportToExcel.util';
|
|
4
4
|
import { formatGoDate, formatDate, formatDateReadable, getUserLocale } from './date.util';
|
|
5
5
|
import useToast from './toast.util';
|
|
6
|
-
import getImageURL from './getImageURL.util';
|
|
6
|
+
import { getImageURL } from './getImageURL.util';
|
|
7
7
|
import { getTransactionRole, getSystemRole, hasSystemRole, hasTransactionRole, checkRouteAccess, hasApprovalRole, hasManagerRole, hasAnyManagerRole, hasAnyMonitoringReportRole, hasMonitoringReportRole, hasStaffRole } from './role.util';
|
|
8
8
|
import { getCurrency, formatCurrency } from './currency.util';
|
|
9
9
|
import { unListenSidebarChanges, listenSidebarChanges } from './listenSidebarChanges.util';
|