更新沃棣背景适配
This commit is contained in:
@@ -428,27 +428,29 @@ class MHTBlueToothController extends GetControllerEx<MHTBlueToothModel> {
|
||||
if (Base64Tool.decode(commandData['data']) != "FFFFFFFF00031000010014FD" &&
|
||||
Base64Tool.decode(commandData['data']).length <= 24) {
|
||||
ef.log("下发指令: ${Base64Tool.decode(commandData['data'])}");
|
||||
commandData['wfr'] = false;
|
||||
//todo 填充蓝牙指令
|
||||
String serviceAddress = ServiceConstant.service_address;
|
||||
String serviceName = ServiceConstant.server_service;
|
||||
String serviceApi = ServiceConstant.sendWifiCommand;
|
||||
String queryUrl = "${serviceAddress}${serviceName}${serviceApi}";
|
||||
await requestWithLog(
|
||||
logTitle: "下发wifi控制指令",
|
||||
method: MyHttpMethod.post,
|
||||
queryUrl: queryUrl,
|
||||
data: commandData,
|
||||
onSuccess: (res) {
|
||||
ef.log("下发指令成功: ${res.msg}");
|
||||
},
|
||||
onFailure: (res) {
|
||||
throw "下发wifi控制指令失败: ${res.msg}";
|
||||
},
|
||||
);
|
||||
} else {
|
||||
// ef.log("下发指令: ${Base64Tool.decode(commandData['data'])}");
|
||||
}
|
||||
ef.log("全部指令");
|
||||
commandData['wfr'] = false;
|
||||
commandData['type'] = 0; //0 base64数据 1 二进制数据
|
||||
String serviceAddress = ServiceConstant.service_address;
|
||||
String serviceName = ServiceConstant.server_service;
|
||||
String serviceApi = ServiceConstant.sendWifiCommand;
|
||||
String queryUrl = "${serviceAddress}${serviceName}${serviceApi}";
|
||||
await requestWithLog(
|
||||
logTitle: "下发wifi控制指令",
|
||||
method: MyHttpMethod.post,
|
||||
queryUrl: queryUrl,
|
||||
data: commandData,
|
||||
onSuccess: (res) {
|
||||
ef.log("下发指令成功: ${res.msg}");
|
||||
},
|
||||
onFailure: (res) {
|
||||
ef.log("下发指令失败: ${res.msg}");
|
||||
throw "下发wifi控制指令失败: ${res.msg}";
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
//todo 解绑的时候删除自己所拥有的所有设备的睡眠习惯
|
||||
|
||||
Reference in New Issue
Block a user