收藏
回答

hardwareDevice.send 接口提交数据为中文就报错?

问题一:

hardwareDevice.send 接口提交数据character_string2为中文就报错,提交参数如下。如果character_string2改成英文或数字就可以。

{"template_id": "9KfVCKix4YrZ3723B1JM8_CRXTmCHdkJpru2HJz-T0c","sn": "98373222aaaa893","model_id": "ug6wkx64Bo8ElaUAYBPxhA","page": "pages/index/index","to_openid_list":["oZMkn5CR20GHJrPPpK3iTXmEA--w"],"data":{"time1":{"value":"2022-04-08 16:17:12"},"character_string2":{"value":"测试"}},"miniprogram_state":"formal","lang":"zh_CN"}

返回结果:{"errcode":47003,"errmsg":"argument invalid! data.character_string2.value i rid: 637c31bf-2a071635-2b9aa5e5"}

问题二:如果模板中选用 enum_string5,无论enum_string5赋值中文或字母都报argument invalid!
{"template_id": "9KfVCKix4YrZ3723B1JM899nEvE_gkLnunONy_qCn70","sn": "98373222aaaa893","model_id": "ug6wkx64Bo8ElaUAYBPxhA","page": "pages/index/index","to_openid_list":["oZMkn5CR20GHJrPPpK3iTXmEA--w"],"data":{"time1":{"value":"2022-04-08 16:17:12"},"character_string2":{"value":"SCX-4521HS"},"enum_string5":{"value":"院长"}},"miniprogram_state":"formal","lang":"zh_CN"}
结果:{"errcode":47003,"errmsg":"argument invalid! data.enum_string5.value invali rid: 637c33c4-4fbd69b8-40fdaead"}



回答关注问题邀请回答
收藏

1 个回答

登录 后发表内容