@cpzxrobot/sdk 1.3.45 → 1.3.46

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 CHANGED
@@ -985,9 +985,9 @@ export class DeviceGateway extends Object {
985
985
  var axios = await this.context.ready;
986
986
  return axios.post(`/api/v2/disinfect/${deviceId}`, { door, open })
987
987
  },
988
- start: async (deviceId: number) => {
988
+ action: async (deviceId: number,action: "start"|"end") => {
989
989
  var axios = await this.context.ready;
990
- return axios.post(`/api/v2/disinfect/${deviceId}`, { end:true })
990
+ return axios.post(`/api/v2/disinfect/${deviceId}`, { action })
991
991
  },
992
992
  config: async (deviceId: number, config: {
993
993
  mode?: number; // 0:没有消毒 1:高温消毒 2:臭氧消毒 3:高温+臭氧
@@ -753,9 +753,9 @@ class DeviceGateway extends Object {
753
753
  var axios = await this.context.ready;
754
754
  return axios.post(`/api/v2/disinfect/${deviceId}`, { door, open });
755
755
  },
756
- start: async (deviceId) => {
756
+ action: async (deviceId, action) => {
757
757
  var axios = await this.context.ready;
758
- return axios.post(`/api/v2/disinfect/${deviceId}`, { end: true });
758
+ return axios.post(`/api/v2/disinfect/${deviceId}`, { action });
759
759
  },
760
760
  config: async (deviceId, config) => {
761
761
  let axios = await this.context.ready;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cpzxrobot/sdk",
3
- "version": "1.3.45",
3
+ "version": "1.3.46",
4
4
  "description": "提供给上海正芯数智APP第三方H5应用使用的SDK",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {