chooseImage 选择图片

chooseImage ^6.8

选择图片

#请求参数

Prop Type Comment
count Number 最多可以选择的图片张数,不得大于 9

#引入接口模块

import bridge from '@minix-iot/etsbridge-sdk'

#参数代码示例

let params = { count: 9 }

#接口调用示例

let params = { count: 9 }
bridge
  .chooseImage(params)
  .then((res) => {
    console.log(res)
  })
  .catch((err) => {
    console.log(err)
  })

#返回参数

  • 成功时返回
Prop Type Value
tempFilePaths Array -
  • 失败时返回
Prop Type Value Comment
code Number -11 用户取消操作
msg String -

#返回示例

{
    "tempFilePaths": [
        "localImages/weex_1609393434_0.jpg",
        "localImages/weex_1609393772_0.jpg"
    ]
}
posted on 2024-12-27 09:32  AtlasLapetos  阅读(11)  评论(0)    收藏  举报