ty.device.openCategoryActivatorPage
进入配网-选品类首页
需引入
DeviceKit,且在>=2.3.2版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
ty.device.openDeviceDetailPage
跳转设备详情
需引入
DeviceKit,且在>=1.2.6版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| deviceId | string | 是 | deviceId 设备 id | |
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
ty.device.openDeviceEdit
跳转设备编辑页面
需引入
DeviceKit,且在>=2.2.0版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| deviceId | string | 是 | deviceId 设备 id | |
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
ty.device.openDeviceExecutionAndAnutomation
跳转一键执行和自动化页面
需引入
DeviceKit,且在>=2.5.3版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| deviceId | string | 是 | deviceId 设备 id | |
| title | string | 否 | 页面标题,Android 需要 | |
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
👉 立即开发。
ty.device.openDeviceInfo
跳转设备信息页面
需引入
DeviceKit,且在>=2.2.0版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| deviceId | string | 是 | deviceId 设备 id | |
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
ty.device.openDeviceQuestionsAndFeedback
跳转常见问题与反馈页面
需引入
DeviceKit,且在>=2.2.0版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| deviceId | string | 是 | deviceId 设备 id | |
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
ty.device.openDeviceWifiNetworkMonitorPage
跳转设备 wifi 网络监测页面
需引入
DeviceKit,且在>=1.2.6版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| deviceId | string | 是 | deviceId 设备 id | |
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
ty.device.openPreConditionPage
打开生效时间段页面
需引入
DeviceKit,且在>=2.5.4版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| id | string | 否 | id | |
| condType | string | 否 | 固定值 timeCheck | |
| expr | Expr | 否 | 规则 | |
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
object.success 回调参数
参数
Object res
| 属性 | 类型 | 说明 | 
|---|---|---|
| id | string | id | 
| condType | string | 固定值 timeCheck | 
| expr | Expr | 规则 | 
object.fail 回调参数
参数
Object res
| 属性 | 类型 | 说明 | 
|---|---|---|
| errorMsg | string | 插件错误信息 | 
| errorCode | string | 错误码 | 
| innerError | object | 插件外部依赖错误信息 {errorMsg: string, errorCode: string } | 
Expr
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| start | string | 是 | 开始时间 imeInterval=custom 时自定义,其余默认 00:00 | |
| end | string | 是 | 结束时间,timeInterval=custom 时自定义,其余默认 23:59 | |
| timeInterval | string | 是 | 自定义:custom,全天:allDay,白天:daytime,夜间:night,默认 allDay | |
| loops | string | 是 | 按 7123456 顺序标记,例:0001100,每周三、四;0000000 表示只执行一次 | |
| timeZoneId | string | 是 | 时区 | |
| cityId | string | 是 | 城市 Id | |
| cityName | string | 是 | 城市名称 | 
ty.device.openReconnectPage
跳转设备断线重连页面
需引入
DeviceKit,且在>=1.2.6版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| deviceId | string | 是 | 设备模型 deviceId 设备 Id | |
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
ty.device.openShareDevice
跳转共享设备页面
需引入
DeviceKit,且在>=2.2.0版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| deviceId | string | 是 | deviceId 设备 id | |
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
ty.device.openRecommendSceneDetail
打开推荐场景详情页面
需引入
DeviceKit,且在>=2.5.3版本才可使用
参数
Object object
| 属性 | 类型 | 默认值 | 必填 | 说明 | 
|---|---|---|---|---|
| source | string | 是 | 来源 | |
| sceneModel | any | 是 | 场景模型 | |
| complete | function | 否 | 接口调用结束的回调函数(调用成功、失败都会执行) | |
| success | function | 否 | 接口调用成功的回调函数 | |
| fail | function | 否 | 接口调用失败的回调函数 | 
object.success 回调参数
参数
Object res
| 属性 | 类型 | 说明 | 
|---|---|---|
| status | boolean | 返回状态,默认返回 true | 
| type | number | 成功返回的类型。0-未操作,1-保存成功,2-点击不感兴趣 | 
| data | any | 返回的场景数据,可能为空 | 
object.fail 回调参数
参数
Object res
| 属性 | 类型 | 说明 | 
|---|---|---|
| errorMsg | string | 插件错误信息 | 
| errorCode | string | 错误码 | 
| innerError | object | 插件外部依赖错误信息 {errorMsg: string, errorCode: string } | 
👉 立即开发。