소스 검색

1.音频文件添加搜索

huangxiaodong 2 달 전
부모
커밋
4586e5d0a3
1개의 변경된 파일36개의 추가작업 그리고 4개의 파일을 삭제
  1. 36 4
      创维盒子/code/Class/Set/previewFile/previewAudioOrDocumentViewController.m

+ 36 - 4
创维盒子/code/Class/Set/previewFile/previewAudioOrDocumentViewController.m

@@ -24,6 +24,9 @@
 #import "audioPlayerViewController.h"
 #import "videoPlayByAVPlayerViewController.h"
 #import "MJRefresh.h"
+#import "searchBarThridTypeView.h"
+#import "NasSearchViewController.h"
+
 
 @interface previewAudioOrDocumentViewController ()<UITableViewDelegate,UITableViewDataSource,DZNEmptyDataSetSource, DZNEmptyDataSetDelegate>
 {
@@ -47,6 +50,7 @@
 @property(nonatomic,assign) BOOL isEditType;
 @property(nonatomic,strong) editTypeHeadView*curEditTypeHeadView;
 @property(nonatomic,strong) editTypeBottomView*curEditTypeBottomView;
+@property(nonatomic,strong) searchBarThridTypeView* searchBarThridTypeV;//
 @property(nonatomic,strong) UIButton*uploadFileButton;
 
 @property (nonatomic, strong)  NSMutableArray*didSelectListArr;//选中的数据
@@ -125,13 +129,31 @@
         }
     };
     
+    _searchBarThridTypeV = [[searchBarThridTypeView alloc] init];
+    [self.view addSubview:_searchBarThridTypeV];
+    
+    [_searchBarThridTypeV mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.top.equalTo(self.navBarBGView.mas_bottom).offset(10.f);
+        make.height.mas_equalTo(32.0);
+        make.left.mas_equalTo(20.0);
+        //make.right.mas_equalTo(-48.0);
+        make.right.mas_equalTo(-20.0);
+    }];
+    
+#pragma mark 点击搜索
+    _searchBarThridTypeV.didClickBgFun = ^{
+        [weakSelf gotoSearchVCFun];
+    };
+
     [self.view addSubview:self.tableView];
     [self.tableView mas_makeConstraints:^(MASConstraintMaker *make) {
         make.left.mas_equalTo(0);
         make.right.mas_equalTo(0);
         //make.bottom.mas_equalTo(-(safeArea));
         make.bottom.mas_equalTo(0);
-        make.top.equalTo(self.navBarBGView.mas_bottom).offset(10.f);
+        //make.top.equalTo(self.navBarBGView.mas_bottom).offset(10.f);
+        make.top.equalTo(self.searchBarThridTypeV.mas_bottom).offset(10.f);
+
     }];
     
     //大+号
@@ -527,7 +549,8 @@
     _curEditTypeHeadView.hidden = NO;
     _curEditTypeBottomView.hidden = NO;
     _uploadFileButton.hidden = YES;
-    
+    self.searchBarThridTypeV.hidden = YES;
+
     [self.tableView mas_remakeConstraints:^(MASConstraintMaker *make) {
         make.left.mas_equalTo(0);
         make.right.mas_equalTo(0);
@@ -551,12 +574,14 @@
     _curEditTypeHeadView.hidden = YES;
     _curEditTypeBottomView.hidden = YES;
     _uploadFileButton.hidden = NO;
-    
+    self.searchBarThridTypeV.hidden = NO;
+
     [self.tableView  mas_remakeConstraints:^(MASConstraintMaker *make) {
         make.left.mas_equalTo(0);
         make.right.mas_equalTo(0);
         make.bottom.mas_equalTo(0);
-        make.top.equalTo(self.navBarBGView.mas_bottom).offset(10.f);
+        //make.top.equalTo(self.navBarBGView.mas_bottom).offset(10.f);
+        make.top.equalTo(self.searchBarThridTypeV.mas_bottom).offset(10.f);
     }];
 }
 
@@ -1128,4 +1153,11 @@
     }];
 }
 
+#pragma mark 点击了搜索
+- (void)gotoSearchVCFun
+{
+    NasSearchViewController *vc = [NasSearchViewController new];
+    [self.navigationController pushViewController:vc animated:YES];
+}
+
 @end