自定义告警推送,部分产品不可用
Posted: 2025年 May 6日 11:40
- Tuya MiniApp IDE 版本信息:0.8.8
- @ray-js/ray, @ray-js/panel-sdk的版本: "@ray-js/panel-sdk": "1.13.1","@ray-js/ray": "1.6.1",
- 相关代码:
Code: Select all
const handleAdd = useCallback( evt => { addCustomAlarm({ name: `电池安全电量范围${mystart}~${myend}`, condition: [ [batteryStateDpId, '<', mystart], [batteryStateDpId, '>=', myend], ], }) .then(data => { console.log('🚀 ~ addCustomAlarm ~ success:', data,'时间段为',mystart,'~',myend); showToast({ title: '电池上下限告警设置成功', icon: 'none' }); }) .catch(err => { console.log('🚀 ~ addCustomAlarm ~ failed:', err,evt,'时间段为',mystart,'~',myend); showToast({ title: '电池上下限告警设置失败', icon: 'error' }); }); }, [mystart,myend] );
- 日志信息:
Code: Select all
🚀 ~ addCustomAlarm ~ failed: {"errorCode": 30001, "errorMsg": "atop request error", "innerError": {"errorMsg": "has been bind to another family Illegal", "errorCode": "ILLEGAL"}} {"type": "click", "detail": {"type": "tap", "timeStamp": 13955, "touches": [{"identifier": -968117566, "force": 0, "pageX": 226, "pageY": 228, "clientX": 226, "clientY": 228}], "changedTouches": [{"identifier": -968117566, "force": 0, "pageX": 226, "pageY": 228, "clientX": 226, "clientY": 228}], "currentTarget": {"id": "", "offsetLeft": 102, "offsetTop": 208, "dataset": {"detail": "<Null>"}}, "target": {"id": "", "offsetLeft": 102, "offsetTop": 208, "dataset": {"detail": "<Null>"}}, "detail": {"x": 226, "y": 228}}, "touches": "<Undefined>", "timeStamp": 14926, "changedTouches": "<Undefined>", "currentTarget": {"id": "", "dataset": {}}, "target": {"id": "<Undefined>", "dataset": {}}, "stopPropagation": "<Function>"} 时间段为 24 ~ 72
- 问题描述(复现步骤):在设备在配网添加成功后,添加自定义告警推送功能,但是只有部分产品添加成功了。我通过isSupportAlarm测试过设备,isSupportAlarm返回了true