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.
@@ -18,6 +18,7 @@ export type GetAvailableAssetsQueryParams = DataTableParams & DialogSelectAssetF
18
18
  mode?: string;
19
19
  asset?: string;
20
20
  maintenanceAuditStatus?: string[];
21
+ _id?: string;
21
22
  };
22
23
  export type GetAssetDetailParams = DataTableParams & {
23
24
  tag?: string;
@@ -13,6 +13,7 @@ declare const _default: {
13
13
  postAssetOption: (params?: GetAllAssetsQueryParams | undefined) => Promise<AxiosResponse<any, any, {}>>;
14
14
  getAvailableAssets: (params: GetAvailableAssetsQueryParams) => Promise<AxiosResponse<any, any, {}>>;
15
15
  postAssetAvailableList: (params?: GetAllAssetsQueryParams | GetAvailableAssetsQueryParams | undefined) => Promise<AxiosResponse<any, any, {}>>;
16
+ postAvailableListOptions: (params?: Partial<Record<string, unknown>> | undefined) => Promise<AxiosResponse<any, any, {}>>;
16
17
  getAssetsById: (_id: string, params: GetAvailableAssetsQueryParams) => Promise<AxiosResponse<any, any, {}>>;
17
18
  getAssetDetail: (id: string, params?: GetAssetDetailParams | undefined) => Promise<AxiosResponse<any, any, {}>>;
18
19
  matchAssetWithTag: (id: string, tag?: string | undefined) => Promise<AxiosResponse<any, any, {}>>;
@@ -13438,6 +13438,10 @@ const scanAsset = (tag2) => {
13438
13438
  const getAssetsById = (_id2, params) => {
13439
13439
  return API$h({ params: { _id: _id2, ...params } }).get("/by-id");
13440
13440
  };
13441
+ const postAvailableListOptions = (params) => {
13442
+ const body = buildBodyParams(params);
13443
+ return API$h().post("/available/list/options", body);
13444
+ };
13441
13445
  const getOptions$1 = (endpoint, params) => {
13442
13446
  return API$h({ params }).get(endpoint ? `/${endpoint}/options` : "/options");
13443
13447
  };
@@ -13474,6 +13478,7 @@ const AssetsServices = {
13474
13478
  postAssetOption,
13475
13479
  getAvailableAssets,
13476
13480
  postAssetAvailableList,
13481
+ postAvailableListOptions,
13477
13482
  getAssetsById,
13478
13483
  getAssetDetail,
13479
13484
  matchAssetWithTag,
@@ -73148,7 +73153,9 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
73148
73153
  _id: JSON.stringify(assetId),
73149
73154
  [optionField]: true
73150
73155
  };
73151
- const { data: data30 } = await AssetsServices.getOptions("by-id", params);
73156
+ const { data: data30 } = await AssetsServices.postAvailableListOptions(
73157
+ params
73158
+ );
73152
73159
  filterOptions2.value[optionField] = (_c = data30.data) == null ? void 0 : _c[optionField];
73153
73160
  }
73154
73161
  } catch (error) {
@@ -73391,7 +73398,9 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
73391
73398
  try {
73392
73399
  setLoading(true);
73393
73400
  const assets = sessionStorage.getItem("assetsDisposalReport") ?? "[]";
73394
- const { data: data30 } = await AssetsServices.getAssetsById(assets, {});
73401
+ const { data: data30 } = await AssetsServices.postAssetAvailableList({
73402
+ _id: assets
73403
+ });
73395
73404
  data30.data.data.forEach((d) => {
73396
73405
  assetNotes.value.set(d._id ?? "", null);
73397
73406
  });