@tagsamurai/fats-api-services 1.1.0-dev-alpha.19 → 1.1.0-dev-alpha.21

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.
@@ -1458,6 +1458,11 @@ const CustomFieldServices = {
1458
1458
  },
1459
1459
  getUsedCustomFields: async () => {
1460
1460
  return API$s.get("/used-by-assets");
1461
+ },
1462
+ getAvailableAssetNameList: (type, queryParams) => {
1463
+ return API$s.get(`/${type}/asset-name/available`, {
1464
+ params: queryParams
1465
+ });
1461
1466
  }
1462
1467
  };
1463
1468
  const API$r = createAxiosInstance({
@@ -2304,6 +2309,9 @@ const TAGServices = {
2304
2309
  },
2305
2310
  putDeclineReport: (body, tagType) => {
2306
2311
  return API$c.put(`/report/decline-report/${tagType}`, body);
2312
+ },
2313
+ postScanLog: (body) => {
2314
+ return API$c.post("/scan-log", body);
2307
2315
  }
2308
2316
  };
2309
2317
  const API$b = createAxiosInstance({
@@ -2437,6 +2445,11 @@ const SettingAssetNameServiceGo = {
2437
2445
  return API$9.delete("", {
2438
2446
  data: body
2439
2447
  });
2448
+ },
2449
+ //https://dev-api.supply.tagsamurai.com/settings-attribute/v2/asset-name/list
2450
+ postAssetNameList: (params) => {
2451
+ const body = buildBodyParams(params);
2452
+ return API$9.post("/list", body);
2440
2453
  }
2441
2454
  };
2442
2455
  const API$8 = createAxiosInstance({
@@ -1466,6 +1466,11 @@ System.register(["axios"], function(exports, module) {
1466
1466
  },
1467
1467
  getUsedCustomFields: async () => {
1468
1468
  return API$s.get("/used-by-assets");
1469
+ },
1470
+ getAvailableAssetNameList: (type, queryParams) => {
1471
+ return API$s.get(`/${type}/asset-name/available`, {
1472
+ params: queryParams
1473
+ });
1469
1474
  }
1470
1475
  });
1471
1476
  const API$r = createAxiosInstance({
@@ -2312,6 +2317,9 @@ System.register(["axios"], function(exports, module) {
2312
2317
  },
2313
2318
  putDeclineReport: (body, tagType) => {
2314
2319
  return API$c.put(`/report/decline-report/${tagType}`, body);
2320
+ },
2321
+ postScanLog: (body) => {
2322
+ return API$c.post("/scan-log", body);
2315
2323
  }
2316
2324
  });
2317
2325
  const API$b = createAxiosInstance({
@@ -2445,6 +2453,11 @@ System.register(["axios"], function(exports, module) {
2445
2453
  return API$9.delete("", {
2446
2454
  data: body
2447
2455
  });
2456
+ },
2457
+ //https://dev-api.supply.tagsamurai.com/settings-attribute/v2/asset-name/list
2458
+ postAssetNameList: (params) => {
2459
+ const body = buildBodyParams(params);
2460
+ return API$9.post("/list", body);
2448
2461
  }
2449
2462
  });
2450
2463
  const API$8 = createAxiosInstance({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tagsamurai/fats-api-services",
3
- "version": "1.1.0-dev-alpha.19",
3
+ "version": "1.1.0-dev-alpha.21",
4
4
  "author": "developer.tagsamurai",
5
5
  "description": "Fixed Asset Tag Samurai Services Library",
6
6
  "module": "./api-services.es.js",
@@ -23,3 +23,13 @@ export interface CustomField {
23
23
  _id: string;
24
24
  name: string;
25
25
  }
26
+ export type CustomFieldTypeParams = 'general' | 'purchase' | 'accounting';
27
+ export type CustomFieldQueryParams = {
28
+ page?: number;
29
+ limit?: number;
30
+ sortBy?: string;
31
+ sortOrder?: number;
32
+ search?: string;
33
+ category?: string | string[];
34
+ excludeIds?: string | string[];
35
+ };
@@ -1,5 +1,5 @@
1
1
  import { AxiosResponse } from 'axios';
2
- import { BodyFiltered, CustomFieldFilterQuery, CustomFieldQuery, CustomFieldResponse } from '../dto/customField.dto';
2
+ import { BodyFiltered, CustomFieldFilterQuery, CustomFieldQuery, CustomFieldQueryParams, CustomFieldResponse, CustomFieldTypeParams } from '../dto/customField.dto';
3
3
  import { CustomFieldData } from '../types/customField.type';
4
4
  /**
5
5
  * Object containing client services.
@@ -19,5 +19,6 @@ declare const CustomFieldServices: {
19
19
  customFieldIds: string;
20
20
  }) => Promise<AxiosResponse>;
21
21
  getUsedCustomFields: () => Promise<AxiosResponse<CustomFieldResponse>>;
22
+ getAvailableAssetNameList: (type: CustomFieldTypeParams, queryParams?: CustomFieldQueryParams) => Promise<AxiosResponse>;
22
23
  };
23
24
  export default CustomFieldServices;
@@ -30,5 +30,9 @@ declare const TAGServices: {
30
30
  putReportTAG: (id: string, body: ReportTagBody) => Promise<AxiosResponse>;
31
31
  putReportTAGBulk: (body?: ReportTagBulkBody) => Promise<AxiosResponse>;
32
32
  putDeclineReport: (body: DeclineReportDto, tagType?: string) => Promise<AxiosResponse>;
33
+ postScanLog: (body: {
34
+ tag: string;
35
+ serialNumber: string;
36
+ }) => Promise<AxiosResponse>;
33
37
  };
34
38
  export default TAGServices;
@@ -18,5 +18,6 @@ declare const SettingAssetNameServiceGo: {
18
18
  setTagType: (body: SetTagTypeBody) => Promise<AxiosResponse<FetchResponse>>;
19
19
  updateAssetName: (body: UpdateAssetNameBody, id: string) => Promise<AxiosResponse<FetchResponse>>;
20
20
  deleteAssetName: (body: DeleteAssetNameBody) => Promise<AxiosResponse<FetchResponse>>;
21
+ postAssetNameList: (params?: GetAssetNameListQueryParams) => Promise<AxiosResponse>;
21
22
  };
22
23
  export default SettingAssetNameServiceGo;