@tagsamurai/fats-api-services 1.1.0-dev-alpha.20 → 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.
package/api-services.es.js
CHANGED
|
@@ -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({
|
|
@@ -2440,6 +2445,11 @@ const SettingAssetNameServiceGo = {
|
|
|
2440
2445
|
return API$9.delete("", {
|
|
2441
2446
|
data: body
|
|
2442
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);
|
|
2443
2453
|
}
|
|
2444
2454
|
};
|
|
2445
2455
|
const API$8 = createAxiosInstance({
|
package/api-services.system.js
CHANGED
|
@@ -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({
|
|
@@ -2448,6 +2453,11 @@ System.register(["axios"], function(exports, module) {
|
|
|
2448
2453
|
return API$9.delete("", {
|
|
2449
2454
|
data: body
|
|
2450
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);
|
|
2451
2461
|
}
|
|
2452
2462
|
});
|
|
2453
2463
|
const API$8 = createAxiosInstance({
|
package/package.json
CHANGED
|
@@ -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;
|
|
@@ -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;
|