@arrowsphere/api-client 3.77.1-bdj.1 → 3.77.1-bdj.2
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.
|
@@ -29,16 +29,15 @@ export declare class LicenseRequest extends AbstractEntity<LicenseRequestType> {
|
|
|
29
29
|
get message(): string | undefined;
|
|
30
30
|
toJSON(): LicenseRequestType;
|
|
31
31
|
}
|
|
32
|
-
export declare type LicenseRequestResultDataType = LicenseRequestType[];
|
|
33
32
|
export declare enum LicenseRequestResultFields {
|
|
34
33
|
COLUMN_LICENSE_REQUEST = "licenseRequests"
|
|
35
34
|
}
|
|
36
35
|
export declare type LicenseRequestResultType = {
|
|
37
36
|
[LicenseRequestResultFields.COLUMN_LICENSE_REQUEST]?: LicenseRequestType[];
|
|
38
37
|
};
|
|
39
|
-
export declare class LicenseRequestResult extends AbstractEntity<
|
|
38
|
+
export declare class LicenseRequestResult extends AbstractEntity<LicenseRequestResultType> {
|
|
40
39
|
#private;
|
|
41
|
-
constructor(input:
|
|
40
|
+
constructor(input: LicenseRequestResultType);
|
|
42
41
|
get licenseRequest(): LicenseRequest[] | undefined;
|
|
43
|
-
toJSON(): LicenseRequestResultType
|
|
42
|
+
toJSON(): LicenseRequestResultType;
|
|
44
43
|
}
|
|
@@ -83,9 +83,10 @@ var LicenseRequestResultFields;
|
|
|
83
83
|
})(LicenseRequestResultFields = exports.LicenseRequestResultFields || (exports.LicenseRequestResultFields = {}));
|
|
84
84
|
class LicenseRequestResult extends abstractEntity_1.AbstractEntity {
|
|
85
85
|
constructor(input) {
|
|
86
|
+
var _a;
|
|
86
87
|
super(input);
|
|
87
88
|
_LicenseRequestResult_licenseRequests.set(this, void 0);
|
|
88
|
-
__classPrivateFieldSet(this, _LicenseRequestResult_licenseRequests, input.map((result) => new LicenseRequest(result)), "f");
|
|
89
|
+
__classPrivateFieldSet(this, _LicenseRequestResult_licenseRequests, (_a = input[LicenseRequestResultFields.COLUMN_LICENSE_REQUEST]) === null || _a === void 0 ? void 0 : _a.map((result) => new LicenseRequest(result)), "f");
|
|
89
90
|
}
|
|
90
91
|
get licenseRequest() {
|
|
91
92
|
return __classPrivateFieldGet(this, _LicenseRequestResult_licenseRequests, "f");
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import { AbstractRestfulClient } from '../abstractRestfulClient';
|
|
5
5
|
import { GetResult } from '../getResult';
|
|
6
|
-
import {
|
|
6
|
+
import { LicenseRequestResult } from './entities/request/licenseRequest';
|
|
7
7
|
export declare class LicenseRequestClient extends AbstractRestfulClient {
|
|
8
8
|
protected basePath: string;
|
|
9
|
-
getLastRequests(licenseReference: string): Promise<GetResult<
|
|
9
|
+
getLastRequests(licenseReference: string): Promise<GetResult<LicenseRequestResult>>;
|
|
10
10
|
}
|
|
@@ -14,7 +14,14 @@ class LicenseRequestClient extends abstractRestfulClient_1.AbstractRestfulClient
|
|
|
14
14
|
}
|
|
15
15
|
async getLastRequests(licenseReference) {
|
|
16
16
|
this.path = `/${licenseReference}/request`;
|
|
17
|
-
|
|
17
|
+
const response = await this.get();
|
|
18
|
+
//A workaround, the public api endpoint is not returning "data" in the payload
|
|
19
|
+
response[getResult_1.GetResultFields.COLUMN_DATA] = {
|
|
20
|
+
[licenseRequest_1.LicenseRequestResultFields.COLUMN_LICENSE_REQUEST]: licenseRequest_1.LicenseRequestResultFields.COLUMN_LICENSE_REQUEST in response
|
|
21
|
+
? response[licenseRequest_1.LicenseRequestResultFields.COLUMN_LICENSE_REQUEST]
|
|
22
|
+
: [],
|
|
23
|
+
};
|
|
24
|
+
return new getResult_1.GetResult(licenseRequest_1.LicenseRequestResult, response);
|
|
18
25
|
}
|
|
19
26
|
}
|
|
20
27
|
exports.LicenseRequestClient = LicenseRequestClient;
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"type": "git",
|
|
5
5
|
"url": "https://github.com/ArrowSphere/nodejs-api-client.git"
|
|
6
6
|
},
|
|
7
|
-
"version": "3.77.1-bdj.
|
|
7
|
+
"version": "3.77.1-bdj.2",
|
|
8
8
|
"description": "Node.js client for ArrowSphere's public API",
|
|
9
9
|
"main": "build/index.js",
|
|
10
10
|
"types": "build/index.d.ts",
|