@etsoo/appscript 1.3.34 → 1.3.35
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.
|
@@ -54,6 +54,11 @@ export declare class EntityApi<T extends IApp = IApp> extends BaseApi<T> {
|
|
|
54
54
|
* @returns Result
|
|
55
55
|
*/
|
|
56
56
|
protected queryAuditBase<T extends DataTypes.IdType, R extends QueryRQ<T>>(rq: R, payload?: AuditLinePayload): Promise<AuditLineDto[] | undefined>;
|
|
57
|
+
/**
|
|
58
|
+
* Query favored country ids
|
|
59
|
+
* @returns Result
|
|
60
|
+
*/
|
|
61
|
+
protected queryFavoredCountryIdsBase(api?: string): Promise<string[]>;
|
|
57
62
|
/**
|
|
58
63
|
* Read
|
|
59
64
|
* @param id Id
|
package/lib/cjs/erp/EntityApi.js
CHANGED
|
@@ -59,6 +59,19 @@ class EntityApi extends BaseApi_1.BaseApi {
|
|
|
59
59
|
queryAuditBase(rq, payload) {
|
|
60
60
|
return this.api.post(`${this.flag}/QueryAudit`, rq, payload);
|
|
61
61
|
}
|
|
62
|
+
/**
|
|
63
|
+
* Query favored country ids
|
|
64
|
+
* @returns Result
|
|
65
|
+
*/
|
|
66
|
+
async queryFavoredCountryIdsBase(api) {
|
|
67
|
+
api !== null && api !== void 0 ? api : (api = `${this.flag}/QueryFavoredCountryIds`);
|
|
68
|
+
const result = await this.api.get(api, undefined, {
|
|
69
|
+
showLoading: false
|
|
70
|
+
});
|
|
71
|
+
if (result == null)
|
|
72
|
+
return [];
|
|
73
|
+
return result.map((item) => item.id);
|
|
74
|
+
}
|
|
62
75
|
/**
|
|
63
76
|
* Read
|
|
64
77
|
* @param id Id
|
|
@@ -54,6 +54,11 @@ export declare class EntityApi<T extends IApp = IApp> extends BaseApi<T> {
|
|
|
54
54
|
* @returns Result
|
|
55
55
|
*/
|
|
56
56
|
protected queryAuditBase<T extends DataTypes.IdType, R extends QueryRQ<T>>(rq: R, payload?: AuditLinePayload): Promise<AuditLineDto[] | undefined>;
|
|
57
|
+
/**
|
|
58
|
+
* Query favored country ids
|
|
59
|
+
* @returns Result
|
|
60
|
+
*/
|
|
61
|
+
protected queryFavoredCountryIdsBase(api?: string): Promise<string[]>;
|
|
57
62
|
/**
|
|
58
63
|
* Read
|
|
59
64
|
* @param id Id
|
package/lib/mjs/erp/EntityApi.js
CHANGED
|
@@ -56,6 +56,19 @@ export class EntityApi extends BaseApi {
|
|
|
56
56
|
queryAuditBase(rq, payload) {
|
|
57
57
|
return this.api.post(`${this.flag}/QueryAudit`, rq, payload);
|
|
58
58
|
}
|
|
59
|
+
/**
|
|
60
|
+
* Query favored country ids
|
|
61
|
+
* @returns Result
|
|
62
|
+
*/
|
|
63
|
+
async queryFavoredCountryIdsBase(api) {
|
|
64
|
+
api !== null && api !== void 0 ? api : (api = `${this.flag}/QueryFavoredCountryIds`);
|
|
65
|
+
const result = await this.api.get(api, undefined, {
|
|
66
|
+
showLoading: false
|
|
67
|
+
});
|
|
68
|
+
if (result == null)
|
|
69
|
+
return [];
|
|
70
|
+
return result.map((item) => item.id);
|
|
71
|
+
}
|
|
59
72
|
/**
|
|
60
73
|
* Read
|
|
61
74
|
* @param id Id
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@etsoo/appscript",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.35",
|
|
4
4
|
"description": "Applications shared TypeScript framework",
|
|
5
5
|
"main": "lib/cjs/index.js",
|
|
6
6
|
"module": "lib/mjs/index.js",
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"@types/jest": "^29.2.3",
|
|
68
68
|
"@typescript-eslint/eslint-plugin": "^5.43.0",
|
|
69
69
|
"@typescript-eslint/parser": "^5.43.0",
|
|
70
|
-
"eslint": "^8.
|
|
70
|
+
"eslint": "^8.28.0",
|
|
71
71
|
"eslint-config-airbnb-base": "^15.0.0",
|
|
72
72
|
"eslint-plugin-import": "^2.26.0",
|
|
73
73
|
"jest": "^29.3.1",
|
package/src/erp/EntityApi.ts
CHANGED
|
@@ -103,6 +103,19 @@ export class EntityApi<T extends IApp = IApp> extends BaseApi<T> {
|
|
|
103
103
|
return this.api.post(`${this.flag}/QueryAudit`, rq, payload);
|
|
104
104
|
}
|
|
105
105
|
|
|
106
|
+
/**
|
|
107
|
+
* Query favored country ids
|
|
108
|
+
* @returns Result
|
|
109
|
+
*/
|
|
110
|
+
protected async queryFavoredCountryIdsBase(api?: string) {
|
|
111
|
+
api ??= `${this.flag}/QueryFavoredCountryIds`;
|
|
112
|
+
const result = await this.api.get<{ id: string }[]>(api, undefined, {
|
|
113
|
+
showLoading: false
|
|
114
|
+
});
|
|
115
|
+
if (result == null) return [];
|
|
116
|
+
return result.map((item) => item.id);
|
|
117
|
+
}
|
|
118
|
+
|
|
106
119
|
/**
|
|
107
120
|
* Read
|
|
108
121
|
* @param id Id
|