修复眠花糖设置闹钟无效

This commit is contained in:
wyf
2025-10-31 15:03:36 +08:00
parent 3c5db3bdf2
commit 58f4b1f0bb
18 changed files with 812 additions and 124 deletions

View File

@@ -74,9 +74,9 @@ class MHTBlueToothController extends GetControllerEx<MHTBlueToothModel> {
RxBool isScanning = false.obs;
RxMap<String, Map> localUpgradeMac = <String, Map>{}.obs; //mac 进度
String? currentUpgradeVersion;//最新版本号
String? currentUpgradeName;//最新固件名
String? currentUpgradeUrl;//最新固件名
String? currentUpgradeVersion; //最新版本号
String? currentUpgradeName; //最新固件名
String? currentUpgradeUrl; //最新固件名
void startStatusPolling() {
updateDeviceStatus().then((res) {
@@ -264,7 +264,8 @@ class MHTBlueToothController extends GetControllerEx<MHTBlueToothModel> {
return ApiResponse(code: -1, msg: "未知错误".tr);
}
saveHabitData(sleepData) async {
Future<bool> saveHabitData(sleepData) async {
bool resFlag = false;
String serviceAddress = ServiceConstant.service_address;
String serviceName = ServiceConstant.server_service;
String serviceApi = ServiceConstant.user_setting;
@@ -281,7 +282,14 @@ class MHTBlueToothController extends GetControllerEx<MHTBlueToothModel> {
method: MyHttpMethod.put,
queryUrl: queryUrl,
data: data,
onSuccess: (res) {
resFlag = true;
},
onFailure: (res) {
resFlag = false;
},
);
return resFlag;
}
Future<Map> loadHabitDataApi(String mac, {int time = 3}) async {