Commit b78c84fad6e5e550fd362229e058d7d0e754b64c
1 parent
1f788a85
pref:DEFECT-1154 转换脚本问号提示后续需要进行相应的修改
Showing
1 changed file
with
24 additions
and
19 deletions
| ... | ... | @@ -58,25 +58,30 @@ export const searchFormSchema: FormSchema[] = [ |
| 58 | 58 | }, |
| 59 | 59 | ]; |
| 60 | 60 | |
| 61 | -export const defaultTitle = h('div', { style: 'background:#404040' }, [ | |
| 62 | - h('h3', { style: 'color:white' }, '示例'), | |
| 63 | - h('h3', { style: 'color:white' }, '输入参数:'), | |
| 64 | - h('h3', { style: 'color:white' }, '0103040150008D3BBB'), | |
| 65 | - h('h3', { style: 'color:white' }, [ | |
| 66 | - h('h3', { style: 'color:white' }, '脚本内容:'), | |
| 67 | - h( | |
| 68 | - 'h3', | |
| 69 | - { style: 'color:white' }, | |
| 70 | - "out.humidity = (parseInt('0x'+params.substr(6, 4))*0.1).toFixed(2);" | |
| 71 | - ), | |
| 72 | - h( | |
| 73 | - 'h3', | |
| 74 | - { style: 'color:white' }, | |
| 75 | - "out.temperature = (parseInt('0x'+params.substr(10, 4))*0.1).toFixed(2);" | |
| 76 | - ), | |
| 77 | - h('h3', { style: 'color:white' }, '输出参数:'), | |
| 78 | - h('h3', { style: 'color:white' }, "{'humidity':'33.60','temperature':'14.10'}"), | |
| 79 | - ]), | |
| 61 | +export const defaultAuthTitle = h('div', { style: 'background:#404040' }, [ | |
| 62 | + h('h3', { style: 'color:white' }, '设备鉴权示例'), | |
| 63 | + h('h3', { style: 'color:white' }, '输入参数:为16进制字符串'), | |
| 64 | + h('h3', { style: 'color:white' }, '输出参数:{"password":"","success":""}'), | |
| 65 | + h('h3', { style: 'color:white' }, 'password为设备鉴权信息,success为鉴权成功后响应给设备的内容'), | |
| 66 | +]); | |
| 67 | + | |
| 68 | +export const defaultUpTitle = h('div', { style: 'background:#404040' }, [ | |
| 69 | + h('h3', { style: 'color:white' }, '上行数据解析示例'), | |
| 70 | + h('h3', { style: 'color:white' }, '输入参数:为字符串'), | |
| 71 | + h( | |
| 72 | + 'h3', | |
| 73 | + { style: 'color:white' }, | |
| 74 | + `输出参数:{"datas":{"source":""},"telemetry":true,"ackMsg":"","deviceName":"","ts":1681701034289}` | |
| 75 | + ), | |
| 76 | + h( | |
| 77 | + 'h3', | |
| 78 | + { style: 'color:white' }, | |
| 79 | + `datas:json对象,属性名为遥测指标或子设备名称 | |
| 80 | + telemetry: datas内容是否为遥测数据 | |
| 81 | + ackMsg: 响应给设备的确认消息 | |
| 82 | + deviceName: 设备名称 | |
| 83 | + ts: 数据采集时间` | |
| 84 | + ), | |
| 80 | 85 | ]); |
| 81 | 86 | |
| 82 | 87 | // TRANSPORT_TCP_DOWN: 'out.datas = "";out.deviceName = "sensor";', | ... | ... |