Skip to content

Commit 0d6892f

Browse files
author
ccharlesren
committed
纯蓝牙LLSync-修改绑定结果文案提示
Tapd 参考小程序:http://tapd.oa.com/NEW_IOT/prong/stories/view/1020393192859210463 Change-Id: I890940fd6aab217db4a0c0a67f278a0337631c1b
1 parent 52131e5 commit 0d6892f

File tree

3 files changed

+12
-5
lines changed

3 files changed

+12
-5
lines changed

Source/LinkApp/Classes/Module/NewDistributionNetwork/Controller/TIoTLLSyncDeviceController.m

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ - (__kindof UICollectionViewCell *)collectionView:(UICollectionView *)collection
220220
if (self.productNameArray.count == self.blueDevices.count) {
221221
NSString *productName = self.productNameArray[indexPath.row];
222222
if ([productName isEqualToString:@"error"]) {
223-
cell.itemString = @"未知设备";
223+
cell.itemString = NSLocalizedString(@"unknow_device", @"未知设备");
224224
cell.detailString = [self getBlueDeviceMacIndex:indexPath];
225225
}else {
226226
cell.itemString = productName;
@@ -466,20 +466,21 @@ - (void)bindSubDevice {
466466
NSString *writeInfo = [NSString stringWithFormat:@"02000D02%@%@",randomHex,bingIDString];
467467
[self.blueManager sendNewLLSynvWithPeripheral:self.currentConnectedPerpheral Characteristic:self.characteristicFFE1 LLDeviceInfo:writeInfo];
468468

469+
[MBProgressHUD showMessage:NSLocalizedString(@"bind_LLSync_device_success", @"绑定纯蓝牙设备成功") icon:@""];
470+
469471
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(1.0 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
470472
[self.blueManager disconnectPeripheral];
471-
[MBProgressHUD showMessage:@"绑定纯蓝牙设备成功" icon:@""];
472473
[self.navigationController popViewControllerAnimated:YES];
474+
//TODO: 将local psk 上传服务器,后续有用到(子设备连接有用)
475+
[self uploadLocalPsk:randomHex];
473476
});
474477

475-
//TODO: 将local psk 上传服务器,后续有用到(子设备连接有用)
476-
[self uploadLocalPsk:randomHex];
477-
478478
} failure:^(NSString *reason, NSError *error, NSDictionary *dic) {
479479
[self.blueManager sendNewLLSynvWithPeripheral:self.currentConnectedPerpheral Characteristic:self.characteristicFFE1 LLDeviceInfo:@"03200101"];
480480

481481
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(1.0 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
482482
[MBProgressHUD showMessage:@"绑定纯蓝牙设备失败" icon:@""];
483+
[MBProgressHUD showMessage:NSLocalizedString(@"bind_LLSync_device_failure", @"绑定纯蓝牙设备失败") icon:@""];
483484
[self.blueManager disconnectPeripheral];
484485
});
485486
}];

Source/LinkApp/Supporting Files/Resource/en.lproj/Localizable.strings

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -955,3 +955,6 @@ If the problem still persists, we recommend you remove the device and add it aga
955955
"authentation_resister_title" = "国家/地区";
956956
"authentation_resister_privacy" = "为了向您提供对应国家/地区的用户协议和隐私政策,请您选择所在的国家及地区";
957957
"authentation_thirdsdk_title" = "第三方SDK目录";
958+
"unknow_device" = "未知设备";
959+
"bind_LLSync_device_success" = "绑定纯蓝牙设备成功";
960+
"bind_LLSync_device_failure" = "绑定纯蓝牙设备失败";

Source/LinkApp/Supporting Files/Resource/zh-Hans.lproj/Localizable.strings

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -947,3 +947,6 @@
947947
"authentation_resister_title" = "国家/地区";
948948
"authentation_resister_privacy" = "为了向您提供对应国家/地区的用户协议和隐私政策,请您选择所在的国家及地区";
949949
"authentation_thirdsdk_title" = "第三方SDK目录";
950+
"unknow_device" = "未知设备";
951+
"bind_LLSync_device_success" = "绑定纯蓝牙设备成功";
952+
"bind_LLSync_device_failure" = "绑定纯蓝牙设备失败";

0 commit comments

Comments
 (0)