安装
使用
export default {
debugMeter: async () => {
let rID = Number(Select1.selectedOptionValue);
let metricName = Input6.text;
let meterAsset = Input7.text;
let busAddr = Input8.text;
let meterAddr = Number(Input9.text);
let registerAddr = Number(Input10.text);
let registerCount = Number(Input11.text);
let ratio = Number(Input12.text);
let result = await ky.post("http://172.16.0.181:9090/debug_meter",{json:{rID,metricName,meterAsset,busAddr,meterAddr,registerAddr,registerCount,ratio}});
if (result.ok) {
let data = await result.json();
showAlert("At "+data.timestamp+" debug meter data is "+data.value,"success");
}else {
showAlert("debug meter is failed.","error");
}
}
}
标签:appsmith,http,text,Number,meter,let,result,data,第三方
From: https://www.cnblogs.com/bitterteaer/p/17568538.html