优化配网成功后的提示问题
This commit is contained in:
parent
18f059663a
commit
d44c7ee20e
@ -54,7 +54,7 @@ class DeviceNetworkInfo {
|
|||||||
String? networkMac;
|
String? networkMac;
|
||||||
String? secretKey;
|
String? secretKey;
|
||||||
String? peerId;
|
String? peerId;
|
||||||
String? rssi;
|
int? rssi;
|
||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final map = <String, dynamic>{};
|
final map = <String, dynamic>{};
|
||||||
|
|||||||
@ -61,7 +61,7 @@ class ConfiguringWifiLogic extends BaseGetXController {
|
|||||||
required String secretKey,
|
required String secretKey,
|
||||||
required String deviceMac,
|
required String deviceMac,
|
||||||
required String networkMac,
|
required String networkMac,
|
||||||
int? rssi,
|
required int rssi,
|
||||||
}) async {
|
}) async {
|
||||||
try {
|
try {
|
||||||
final LoginEntity entity = await ApiRepository.to.settingDeviceNetwork(
|
final LoginEntity entity = await ApiRepository.to.settingDeviceNetwork(
|
||||||
@ -174,7 +174,7 @@ class ConfiguringWifiLogic extends BaseGetXController {
|
|||||||
secretKey: secretKey,
|
secretKey: secretKey,
|
||||||
deviceMac: deviceMac ?? '',
|
deviceMac: deviceMac ?? '',
|
||||||
networkMac: networkMac ?? '',
|
networkMac: networkMac ?? '',
|
||||||
rssi: rssi,
|
rssi: rssi ?? 0,
|
||||||
);
|
);
|
||||||
if (info.errorCode!.codeIsSuccessful) {
|
if (info.errorCode!.codeIsSuccessful) {
|
||||||
// 设置锁的peerID
|
// 设置锁的peerID
|
||||||
@ -183,7 +183,7 @@ class ConfiguringWifiLogic extends BaseGetXController {
|
|||||||
networkMac: networkMac,
|
networkMac: networkMac,
|
||||||
secretKey: secretKey,
|
secretKey: secretKey,
|
||||||
peerId: peerId,
|
peerId: peerId,
|
||||||
rssi: rssi.toString(),
|
rssi: rssi,
|
||||||
);
|
);
|
||||||
|
|
||||||
state.lockSetInfoData.value?.lockBasicInfo?.networkInfo?.peerId =
|
state.lockSetInfoData.value?.lockBasicInfo?.networkInfo?.peerId =
|
||||||
@ -191,7 +191,7 @@ class ConfiguringWifiLogic extends BaseGetXController {
|
|||||||
state.lockSetInfoData.value?.lockBasicInfo?.networkInfo?.wifiName =
|
state.lockSetInfoData.value?.lockBasicInfo?.networkInfo?.wifiName =
|
||||||
wifiName;
|
wifiName;
|
||||||
state.lockSetInfoData.value?.lockBasicInfo?.networkInfo?.rssi =
|
state.lockSetInfoData.value?.lockBasicInfo?.networkInfo?.rssi =
|
||||||
rssi as int?;
|
rssi;
|
||||||
|
|
||||||
/// 配网成功后,赋值锁的peerId
|
/// 配网成功后,赋值锁的peerId
|
||||||
StartChartManage().lockPeerId = peerId;
|
StartChartManage().lockPeerId = peerId;
|
||||||
|
|||||||
@ -79,14 +79,14 @@ class _ConfiguringWifiPageState extends State<ConfiguringWifiPage>
|
|||||||
SizedBox(
|
SizedBox(
|
||||||
height: 20.h,
|
height: 20.h,
|
||||||
),
|
),
|
||||||
Text(
|
// Text(
|
||||||
'请确保网络是2.4GHz Wi-Fi'.tr,
|
// '请确保网络是2.4GHz Wi-Fi'.tr,
|
||||||
style: TextStyle(
|
// style: TextStyle(
|
||||||
color: AppColors.blackColor,
|
// color: AppColors.blackColor,
|
||||||
fontSize: 20.sp,
|
// fontSize: 20.sp,
|
||||||
fontWeight: FontWeight.w500,
|
// fontWeight: FontWeight.w500,
|
||||||
),
|
// ),
|
||||||
),
|
// ),
|
||||||
],
|
],
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user