# tslV2PerformAction ^8.13.1

操作(action)调用(物模型2.0)

# 请求参数

Prop Type Default Comment
moduleCode String N/A 物模型模块编码
actionCode String N/A 物模型动作编码
applianceCode String N/A 设备编码
body String N/A 控制参数
sync Number N/A 是否同步 1/0

# 接口调用示例

const params = {
  moduleCode: 'electricCurtain', //模块编码,
  actionCode: 'open', //动作编码
  applianceCode: '5123791273891273', //设备编码
  body: {},
  sync: 1
}
this.$bridge
  .tslV2PerformAction(params)
  .then(res => {
    this.$alert(res)
  })
  .catch(err => {
    this.$toast(err)
  })
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15

# 返回参数

Prop Type Default Description
code Number N/A 0: 请求成功
data Array N/A 物模型返回的数据
Last Updated: 3/1/2023, 6:34:39 PM