tsv2-library 1.1.0-dev-alpha.45 → 1.1.0-dev-alpha.47
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/src/components/v2/DialogSelectAsset/DialogSelectAsset.vue.d.ts +7 -0
- package/dist/src/services/assetName.service.d.ts +1 -1
- package/dist/tsv2-library.es.js +9 -7
- package/dist/tsv2-library.umd.js +2 -2
- package/package.json +1 -1
- package/src/components/v2/DialogSelectAsset/DialogSelectAsset.vue.d.ts +7 -0
- package/src/services/assetName.service.ts +5 -3
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { DefineComponent, Slot } from 'vue';
|
|
2
2
|
import { FilterOption } from '../../../types/filterOption.type';
|
|
3
|
+
import { FilterField } from '../../../types/filterField.type';
|
|
3
4
|
|
|
4
5
|
export interface DialogSelectAssetFilterModels {
|
|
5
6
|
assetName?: string[];
|
|
@@ -261,6 +262,12 @@ export interface DialogSelectAssetProps {
|
|
|
261
262
|
* @param params this is required
|
|
262
263
|
*/
|
|
263
264
|
fetchFunction?: (params: QueryParams) => Promise<FetchResponse | undefined>;
|
|
265
|
+
/**
|
|
266
|
+
* The function to fetch filter options for AssetFilters.
|
|
267
|
+
*
|
|
268
|
+
* Overrides the default handleFetchOptions when provided.
|
|
269
|
+
*/
|
|
270
|
+
fetchOptionFunction?: FilterField<QueryParams>['fetchOptionFn'];
|
|
264
271
|
}
|
|
265
272
|
|
|
266
273
|
/**
|
|
@@ -32,7 +32,7 @@ declare const _default: {
|
|
|
32
32
|
getAssetNameDetail: (id: string) => Promise<AxiosResponse<any, any, {}>>;
|
|
33
33
|
getAssetNameList: (params: GetAssetNameListQueryParams) => Promise<AxiosResponse<any, any, {}>>;
|
|
34
34
|
getAssetsByAssetName: (id: string, params?: Partial<Record<string, unknown>> | undefined) => Promise<AxiosResponse<any, any, {}>>;
|
|
35
|
-
|
|
35
|
+
postUnpairedAssetName: (params: GetAssetNameListQueryParams) => Promise<AxiosResponse<any, any, {}>>;
|
|
36
36
|
getAssetNameDropdown: () => Promise<AxiosResponse<GetAssetNameDropdownResponse, any, {}>>;
|
|
37
37
|
getOptions: (params: AssetNameOptionsQueryParams) => Promise<AxiosResponse<any, any, {}>>;
|
|
38
38
|
postAssetNameList: (params?: GetAssetNameListQueryParams | undefined) => Promise<AxiosResponse<any, any, {}>>;
|
package/dist/tsv2-library.es.js
CHANGED
|
@@ -13515,8 +13515,9 @@ const getAssetsByAssetName = (id, params) => {
|
|
|
13515
13515
|
const getAssetNameList = (params) => {
|
|
13516
13516
|
return API$g({ params }).get("/");
|
|
13517
13517
|
};
|
|
13518
|
-
const
|
|
13519
|
-
|
|
13518
|
+
const postUnpairedAssetName = (params) => {
|
|
13519
|
+
const body = buildBodyParams(params);
|
|
13520
|
+
return API$g().post("/unpaired/list", body);
|
|
13520
13521
|
};
|
|
13521
13522
|
const getOptions = (params) => {
|
|
13522
13523
|
return API$g({ params }).get("/options");
|
|
@@ -13532,7 +13533,7 @@ const AssetNameServices = {
|
|
|
13532
13533
|
getAssetNameDetail,
|
|
13533
13534
|
getAssetNameList,
|
|
13534
13535
|
getAssetsByAssetName,
|
|
13535
|
-
|
|
13536
|
+
postUnpairedAssetName,
|
|
13536
13537
|
getAssetNameDropdown,
|
|
13537
13538
|
getOptions,
|
|
13538
13539
|
postAssetNameList
|
|
@@ -62648,7 +62649,8 @@ const _sfc_main$Z = /* @__PURE__ */ defineComponent({
|
|
|
62648
62649
|
tooltipInfo: {},
|
|
62649
62650
|
disabled: { type: Boolean },
|
|
62650
62651
|
btnTooltipInfo: {},
|
|
62651
|
-
fetchFunction: {}
|
|
62652
|
+
fetchFunction: {},
|
|
62653
|
+
fetchOptionFunction: { default: void 0 }
|
|
62652
62654
|
}, {
|
|
62653
62655
|
"visible": { default: false },
|
|
62654
62656
|
"visibleModifiers": {}
|
|
@@ -63015,7 +63017,7 @@ const _sfc_main$Z = /* @__PURE__ */ defineComponent({
|
|
|
63015
63017
|
params.excludeKey = props.excludedKey ? JSON.stringify(props.excludedKey) : void 0;
|
|
63016
63018
|
params.excludeId = props.excludeId ? JSON.stringify(props.excludeId) : void 0;
|
|
63017
63019
|
params.excludeInitialGroup = props.excludeInitialGroup ? JSON.stringify(props.excludeInitialGroup) : void 0;
|
|
63018
|
-
const { data: data30 } = props.unpaired ? await AssetNameServices.
|
|
63020
|
+
const { data: data30 } = props.unpaired ? await AssetNameServices.postUnpairedAssetName(params) : await AssetNameServices.getAssetNameList(params);
|
|
63019
63021
|
if (props.unpaired) {
|
|
63020
63022
|
filterOption.value.nameOptions = (_c = (_b = data30.data) == null ? void 0 : _b.data) == null ? void 0 : _c.map(
|
|
63021
63023
|
(d) => {
|
|
@@ -63224,11 +63226,11 @@ const _sfc_main$Z = /* @__PURE__ */ defineComponent({
|
|
|
63224
63226
|
"onUpdate:filter": _cache[3] || (_cache[3] = ($event) => filter4 = $event),
|
|
63225
63227
|
"visible-columns": visibleColumns.value,
|
|
63226
63228
|
"onUpdate:visibleColumns": _cache[4] || (_cache[4] = ($event) => visibleColumns.value = $event),
|
|
63227
|
-
"fetch-options": handleFetchOptions,
|
|
63229
|
+
"fetch-options": props.fetchOptionFunction ?? handleFetchOptions,
|
|
63228
63230
|
"table-name": TABLE_NAME,
|
|
63229
63231
|
"tag-type": typeof props.tagType !== "boolean" ? props.tagType : void 0,
|
|
63230
63232
|
onUpdateFields: _cache[5] || (_cache[5] = ($event) => containerKey.value++)
|
|
63231
|
-
}, null, 8, ["filter", "visible-columns", "tag-type"])) : (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(filterLists.value, (field2) => {
|
|
63233
|
+
}, null, 8, ["filter", "visible-columns", "fetch-options", "tag-type"])) : (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(filterLists.value, (field2) => {
|
|
63232
63234
|
return openBlock(), createElementBlock(Fragment, null, [
|
|
63233
63235
|
field2.fieldName === "group" ? (openBlock(), createBlock(_sfc_main$1a, {
|
|
63234
63236
|
key: field2.label,
|