@edgeiq/edgeiq-api-js 1.4.5 → 1.4.7
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.
|
@@ -8,7 +8,7 @@ interface SoftwareUpdatesInterface extends BaseModelInterface<SoftwareUpdate, So
|
|
|
8
8
|
assignToDeviceType(softwareUpdateId: string, deviceTypeId: string): Promise<string>;
|
|
9
9
|
removeFromDevice(softwareUpdateId: string, deviceId: string): Promise<string>;
|
|
10
10
|
removeFromDeviceType(softwareUpdateId: string, deviceTypeId: string): Promise<string>;
|
|
11
|
-
bulkSoftwareUpdate(payload: IssueSoftwareUpdateInput): Promise<BulkActionResponse>;
|
|
11
|
+
bulkSoftwareUpdate(payload: IssueSoftwareUpdateInput, generateChildCommandExecutions?: boolean): Promise<BulkActionResponse>;
|
|
12
12
|
uploadFile(id: string, file: File[]): Promise<FileLocation[]>;
|
|
13
13
|
}
|
|
14
14
|
export declare const SoftwareUpdates: SoftwareUpdatesInterface;
|
|
@@ -14,6 +14,17 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
14
14
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
15
15
|
};
|
|
16
16
|
})();
|
|
17
|
+
var __assign = (this && this.__assign) || function () {
|
|
18
|
+
__assign = Object.assign || function(t) {
|
|
19
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
20
|
+
s = arguments[i];
|
|
21
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
22
|
+
t[p] = s[p];
|
|
23
|
+
}
|
|
24
|
+
return t;
|
|
25
|
+
};
|
|
26
|
+
return __assign.apply(this, arguments);
|
|
27
|
+
};
|
|
17
28
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
18
29
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
19
30
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -316,7 +327,7 @@ exports.SoftwareUpdates = (function (_super) {
|
|
|
316
327
|
});
|
|
317
328
|
});
|
|
318
329
|
};
|
|
319
|
-
class_1.bulkSoftwareUpdate = function (payload) {
|
|
330
|
+
class_1.bulkSoftwareUpdate = function (payload, generateChildCommandExecutions) {
|
|
320
331
|
return __awaiter(this, void 0, void 0, function () {
|
|
321
332
|
var axios, result, error_11;
|
|
322
333
|
return __generator(this, function (_a) {
|
|
@@ -325,7 +336,7 @@ exports.SoftwareUpdates = (function (_super) {
|
|
|
325
336
|
_a.trys.push([0, 2, , 3]);
|
|
326
337
|
this.logAction("Issuing software updates with payload " + payload);
|
|
327
338
|
axios = __1.EdgeIQAPI.getAxios();
|
|
328
|
-
return [4, axios.post(constants_1.Endpoints.device + "/bulk/software_update", payload)];
|
|
339
|
+
return [4, axios.post(constants_1.Endpoints.device + "/bulk/software_update", __assign(__assign({}, payload), { generate_child_command_executions: generateChildCommandExecutions !== null && generateChildCommandExecutions !== void 0 ? generateChildCommandExecutions : false }))];
|
|
329
340
|
case 1:
|
|
330
341
|
result = _a.sent();
|
|
331
342
|
return [2, result === null || result === void 0 ? void 0 : result.data];
|
package/dist/testConstants.js
CHANGED
|
@@ -180,7 +180,7 @@ exports.EmptyIngestor = __assign(__assign({}, baseModel), { company_id: '', name
|
|
|
180
180
|
}, handler: {
|
|
181
181
|
routes: [
|
|
182
182
|
{
|
|
183
|
-
|
|
183
|
+
methods: ['get'],
|
|
184
184
|
path: '',
|
|
185
185
|
},
|
|
186
186
|
],
|
|
@@ -215,7 +215,7 @@ exports.TestIngestor = {
|
|
|
215
215
|
handler: {
|
|
216
216
|
routes: [
|
|
217
217
|
{
|
|
218
|
-
|
|
218
|
+
methods: ['get'],
|
|
219
219
|
path: '',
|
|
220
220
|
},
|
|
221
221
|
],
|
|
@@ -251,7 +251,7 @@ exports.TestIngestor2 = {
|
|
|
251
251
|
handler: {
|
|
252
252
|
routes: [
|
|
253
253
|
{
|
|
254
|
-
|
|
254
|
+
methods: ['get'],
|
|
255
255
|
path: '',
|
|
256
256
|
},
|
|
257
257
|
],
|