From 3698c13aba988cd3e41b91b255e1c682c057e565 Mon Sep 17 00:00:00 2001
From: chenqiyang <1406175257@qq.com>
Date: 星期四, 23 三月 2023 11:49:58 +0800
Subject: [PATCH] 1.新增历史记录相关页面及功能 2.修改配网为热点配网 3.设备列表增加过滤门锁功能 4.增加添加设备通知功能
---
EZSDK/EZSDK/EZ/UIViewControllers/EZDeviceTableViewController.m | 44 +++++++++++++++++++++++++++++++++++---------
1 files changed, 35 insertions(+), 9 deletions(-)
diff --git a/EZSDK/EZSDK/EZ/UIViewControllers/EZDeviceTableViewController.m b/EZSDK/EZSDK/EZ/UIViewControllers/EZDeviceTableViewController.m
index 222b769..c27e2b8 100644
--- a/EZSDK/EZSDK/EZ/UIViewControllers/EZDeviceTableViewController.m
+++ b/EZSDK/EZSDK/EZ/UIViewControllers/EZDeviceTableViewController.m
@@ -20,7 +20,7 @@
#import "EZAreaInfo.h"
#import "EZUserInfo.h"
#import "Toast+UIView.h"
-#import "EZVideoTalkViewcontroller.h"
+//#import "EZVideoTalkViewcontroller.h"
#import "EZMultiChannelRealPlayVC.h"
#import "EZHubDebugViewController.h"
#import "GlobalKit.h"
@@ -52,8 +52,8 @@
{
[super viewDidLoad];
- [[UIBarButtonItem appearance] setBackButtonTitlePositionAdjustment:UIOffsetMake(0, -60)
- forBarMetrics:UIBarMetricsDefault];
+// [[UIBarButtonItem appearance] setBackButtonTitlePositionAdjustment:UIOffsetMake(0, -60)
+// forBarMetrics:UIBarMetricsDefault];
// Uncomment the following line to preserve selection between presentations.
// self.clearsSelectionOnViewWillAppear = NO;
@@ -66,8 +66,14 @@
// self.title.
self.logoutBtn.title = NSLocalizedString(@"Logout", @"娉ㄩ攢");
+ self.logoutBtn.title = @"";
+ [self.logoutBtn setEnabled: NO];
[self checkEZIsLogin];
+
+// self.addButton=nil;
+ self.addButton=[[UIBarButtonItem alloc] init];
+// self.addButton=[UIImage imageNamed:@""];
}
@@ -75,7 +81,7 @@
{
[super viewWillAppear:animated];
- // self.navigationController.navigationBarHidden = NO;//2021-02-01
+ self.navigationController.navigationBar.hidden = NO;//2021-02-01
if (_needRefresh)
{
@@ -251,7 +257,17 @@
return;
}
[weakSelf.deviceList removeAllObjects];
- [weakSelf.deviceList addObjectsFromArray:deviceList];
+ HDLEZLog(@"鑾峰彇鍒扮殑璁惧鍒楄〃锛�%@",deviceList);
+ NSMutableArray *finalDeviceList=[NSMutableArray arrayWithArray:deviceList];
+ if (self.filterTypes&&self.filterTypes.count!=0) {//鍒ゆ柇鏄惁闇�瑕佽繃婊�
+ for (EZDeviceInfo *deviceInfo in deviceList) {
+ HDLEZLog(@"鑾峰彇鍒扮殑璁惧鍒楄〃category锛�%@",deviceInfo.category);
+ if ([self.filterTypes containsObject:[HDLEZConstants turnNil:deviceInfo.category]]) {
+ [finalDeviceList removeObject:deviceInfo];
+ }
+ }
+ }
+ [weakSelf.deviceList addObjectsFromArray:finalDeviceList];
[weakSelf.tableView reloadData];
[weakSelf.tableView.header endRefreshing];
if (weakSelf.deviceList.count == totalCount)
@@ -308,7 +324,17 @@
// [weakSelf.view makeToast:error.description duration:2.0 position:@"bottom"];
// return;
// }
- [weakSelf.deviceList addObjectsFromArray:deviceList];
+
+ NSMutableArray *finalDeviceList=[NSMutableArray arrayWithArray:deviceList];
+ if (self.filterTypes&&self.filterTypes.count!=0) {//鍒ゆ柇鏄惁闇�瑕佽繃婊�
+ for (EZDeviceInfo *deviceInfo in deviceList) {
+ if ([self.filterTypes containsObject:[HDLEZConstants turnNil:deviceInfo.category]]) {
+ [finalDeviceList removeObject:deviceInfo];
+ }
+ }
+ }
+ [weakSelf.deviceList addObjectsFromArray:finalDeviceList];
+// [weakSelf.deviceList addObjectsFromArray:deviceList];
[weakSelf.tableView reloadData];
[weakSelf.tableView.footer endRefreshing];
if (weakSelf.deviceList.count == totalCount)
@@ -388,9 +414,9 @@
}
- (void) go2VideoTalk:(EZDeviceInfo *)deviceInfo {
- EZVideoTalkViewcontroller *vc = [EZVideoTalkViewcontroller videoTalkVC];
- vc.deviceInfo = deviceInfo;
- [self.navigationController pushViewController:vc animated:YES];
+// EZVideoTalkViewcontroller *vc = [EZVideoTalkViewcontroller videoTalkVC];
+// vc.deviceInfo = deviceInfo;
+// [self.navigationController pushViewController:vc animated:YES];
}
- (IBAction)go2MultiPlay:(id)sender {
--
Gitblit v1.8.0