tsv2-library 1.1.0-dev-alpha.13 → 1.1.0-dev-alpha.15
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/package.json
CHANGED
|
@@ -9,6 +9,7 @@ import {
|
|
|
9
9
|
} from '@/dto/assets.dto';
|
|
10
10
|
import { AssetOptionField } from '@/components/v2/DialogSelectAsset/DialogSelectAsset.vue.d';
|
|
11
11
|
import { buildBodyParams } from '@/utils';
|
|
12
|
+
import { QueryParams } from '@/components/v2/DataTable/DataTable.vue.d';
|
|
12
13
|
|
|
13
14
|
export interface ServiceOptions {
|
|
14
15
|
headers?: Record<string, unknown>;
|
|
@@ -57,6 +58,9 @@ const getAllAssets = (
|
|
|
57
58
|
return API({ params }).get('/');
|
|
58
59
|
};
|
|
59
60
|
|
|
61
|
+
/**
|
|
62
|
+
* @deprecated - use postAssetAvailableList instead
|
|
63
|
+
*/
|
|
60
64
|
const getAvailableAssets = (
|
|
61
65
|
params: GetAvailableAssetsQueryParams,
|
|
62
66
|
): Promise<AxiosResponse> => {
|
|
@@ -74,6 +78,9 @@ const scanAsset = (tag: string): Promise<AxiosResponse> => {
|
|
|
74
78
|
return API({ params: { tag } }).get('');
|
|
75
79
|
};
|
|
76
80
|
|
|
81
|
+
/**
|
|
82
|
+
* @deprecated - Replaced with getAvailableAssets
|
|
83
|
+
*/
|
|
77
84
|
const getAssetsById = (
|
|
78
85
|
_id: string,
|
|
79
86
|
params: GetAvailableAssetsQueryParams,
|
|
@@ -81,6 +88,13 @@ const getAssetsById = (
|
|
|
81
88
|
return API({ params: { _id, ...params } }).get('/by-id');
|
|
82
89
|
};
|
|
83
90
|
|
|
91
|
+
const postAvailableListOptions = (
|
|
92
|
+
params?: QueryParams,
|
|
93
|
+
): Promise<AxiosResponse> => {
|
|
94
|
+
const body = buildBodyParams(params);
|
|
95
|
+
return API().post('/available/list/options', body);
|
|
96
|
+
};
|
|
97
|
+
|
|
84
98
|
const getOptions = (
|
|
85
99
|
endpoint?: 'unlinked' | 'by-id',
|
|
86
100
|
params?: Partial<Record<AssetOptionField, boolean>> & {
|
|
@@ -146,6 +160,7 @@ export default {
|
|
|
146
160
|
postAssetOption,
|
|
147
161
|
getAvailableAssets,
|
|
148
162
|
postAssetAvailableList,
|
|
163
|
+
postAvailableListOptions,
|
|
149
164
|
getAssetsById,
|
|
150
165
|
getAssetDetail,
|
|
151
166
|
matchAssetWithTag,
|