@cpzxrobot/sdk 1.3.25 → 1.3.26
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/device_gateway.ts +8 -0
- package/dist/device_gateway.js +7 -0
- package/package.json +1 -1
package/device_gateway.ts
CHANGED
|
@@ -305,6 +305,14 @@ export class DeviceGateway extends Object {
|
|
|
305
305
|
});
|
|
306
306
|
}
|
|
307
307
|
|
|
308
|
+
async batchValidate(serialNumbers: string[], type: string = "pywl") {
|
|
309
|
+
let axios = await this.context.ready;
|
|
310
|
+
return axios.upload(`/api/v2/device/batchValidate`, {
|
|
311
|
+
serialNumbers,
|
|
312
|
+
type,
|
|
313
|
+
});
|
|
314
|
+
}
|
|
315
|
+
|
|
308
316
|
async faults(deviceId: number, startTime: Date, endTime: Date): Promise<DeviceFault[]> {
|
|
309
317
|
let axios = await this.context.ready;
|
|
310
318
|
const startTimeRfc3339 = startTime.toISOString();
|
package/dist/device_gateway.js
CHANGED
|
@@ -213,6 +213,13 @@ class DeviceGateway extends Object {
|
|
|
213
213
|
type,
|
|
214
214
|
});
|
|
215
215
|
}
|
|
216
|
+
async batchValidate(serialNumbers, type = "pywl") {
|
|
217
|
+
let axios = await this.context.ready;
|
|
218
|
+
return axios.upload(`/api/v2/device/batchValidate`, {
|
|
219
|
+
serialNumbers,
|
|
220
|
+
type,
|
|
221
|
+
});
|
|
222
|
+
}
|
|
216
223
|
async faults(deviceId, startTime, endTime) {
|
|
217
224
|
let axios = await this.context.ready;
|
|
218
225
|
const startTimeRfc3339 = startTime.toISOString();
|