Skip to content

Commit 36b25bf

Browse files
committed
文档 改为 文件。。bugfix
1 parent 7418adc commit 36b25bf

4 files changed

Lines changed: 13 additions & 20 deletions

File tree

Coding_iOS/Controllers/FileListViewController.m

Lines changed: 10 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,13 @@ - (void)viewDidLoad
8585
}
8686

8787
- (void)changeEditState{
88-
[_myTableView setEditing:!_myTableView.isEditing animated:YES];
88+
[self changeEditStateToEditing:!_myTableView.isEditing];
89+
}
90+
91+
- (void)changeEditStateToEditing:(BOOL)isEditing{
92+
[_myTableView setEditing:isEditing animated:YES];
8993
NSArray *rightBarButtonItems;
90-
if (_myTableView.isEditing) {
94+
if (isEditing) {
9195
UIBarButtonItem *item1 = [UIBarButtonItem itemWithBtnTitle:@"完成" target:self action:@selector(changeEditState)];
9296
UIBarButtonItem *spaceItem = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemFixedSpace target:nil action:nil];
9397
spaceItem.width = 20;
@@ -124,17 +128,6 @@ - (void)reverseSelect{
124128
}
125129
}
126130

127-
- (void)didReceiveMemoryWarning
128-
{
129-
[super didReceiveMemoryWarning];
130-
// Dispose of any resources that can be recreated.
131-
}
132-
133-
- (void)viewWillAppear:(BOOL)animated{
134-
[super viewWillAppear:animated];
135-
[self.myTableView reloadData];
136-
}
137-
138131
- (void)configuploadFiles{
139132
self.uploadFiles = [[Coding_FileManager sharedManager] uploadFilesInProject:self.curProject.id.stringValue andFolder:self.curFolder.file_id.stringValue];
140133
if (!self.uploadFiles) {
@@ -376,7 +369,7 @@ - (void)downloadFilesBtnClicked{
376369
NSString *tipStr = downloadingCount == 0? @"所选的文件都已经下载到本地了" : @"所选的文件都已经在下载队列中了";
377370
[self showHudTipStr:tipStr];
378371
}
379-
[self changeEditState];
372+
[self changeEditStateToEditing:NO];
380373
}
381374
}
382375

@@ -390,10 +383,10 @@ - (void)deleteFilesBtnClicked{
390383
__weak typeof(self) weakSelf = self;
391384
NSArray *selectedFiles = [self selectedFiles];
392385
if (selectedFiles.count > 0) {
393-
[[UIActionSheet bk_actionSheetCustomWithTitle:[NSString stringWithFormat:@"确认删除选定的 %lu 个文档\n删除后将无法恢复!", (unsigned long)selectedFiles.count] buttonTitles:nil destructiveTitle:@"确认删除" cancelTitle:@"取消" andDidDismissBlock:^(UIActionSheet *sheet, NSInteger index) {
386+
[[UIActionSheet bk_actionSheetCustomWithTitle:[NSString stringWithFormat:@"确认删除选定的 %lu 个文件\n删除后将无法恢复!", (unsigned long)selectedFiles.count] buttonTitles:nil destructiveTitle:@"确认删除" cancelTitle:@"取消" andDidDismissBlock:^(UIActionSheet *sheet, NSInteger index) {
394387
if (index == 0) {
395388
[weakSelf deleteFiles:selectedFiles];
396-
[weakSelf changeEditState];
389+
[weakSelf changeEditStateToEditing:NO];
397390
}
398391
}] showInView:self.view];
399392
}
@@ -742,7 +735,7 @@ - (void)moveFiles:(NSArray *)files fromFolder:(ProjectFolder *)folder{
742735
vc.rootFolders = self.rootFolders;
743736
vc.curFolder = nil;
744737
vc.moveToFolderBlock = ^(ProjectFolder *curFolder, NSArray *toMovedFileIdList){
745-
[weakSelf changeEditState];
738+
[weakSelf changeEditStateToEditing:NO];
746739
[[Coding_NetAPIManager sharedManager] request_MoveFiles:toMovedFileIdList toFolder:curFolder andBlock:^(id data, NSError *error) {
747740
if (data) {
748741
[weakSelf refreshRootFolders];

Coding_iOS/Controllers/NProjectViewController/NProjectViewController.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N
190190
if (_myProject.is_public.boolValue) {
191191
[cell setImageStr:@"project_item_member" andTitle:@"成员"];
192192
}else{
193-
[cell setImageStr:@"project_item_file" andTitle:@"文档"];
193+
[cell setImageStr:@"project_item_file" andTitle:@"文件"];
194194
}
195195
break;
196196
case 4:

Coding_iOS/Views/Cell/ProjectItemsCell.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ - (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reus
3434

3535
itemsIconList = @[@"icon-bolt", @"icon-tasks", @"icon-comments", @"icon-folder-open", @"icon-code", @"icon-user"];
3636
itemsColorList = @[@"0x3bbd79", @"0x25c2d5", @"0x3899d0", @"0xf8b327", @"0xee8c35", @"0xe7683d"];
37-
itemsTitleList = @[@"动态", @"任务", @"讨论", @"文档", @"代码", @"成员"];
37+
itemsTitleList = @[@"动态", @"任务", @"讨论", @"文件", @"代码", @"成员"];
3838

3939
}else if ([reuseIdentifier isEqualToString:kCellIdentifier_ProjectItemsCell_Public]){
4040
itemsNum = 4;

Coding_iOS/Views/TableListView/ProjectActivitiesView.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ - (NSArray*)titlesArray
6666
if (_myProject.is_public.boolValue) {
6767
_titlesArray = @[@"全部", @"讨论", @"代码", @"其他"];
6868
}else{
69-
_titlesArray = @[@"全部", @"任务", @"讨论", @"文档", @"代码", @"其他"];
69+
_titlesArray = @[@"全部", @"任务", @"讨论", @"文件", @"代码", @"其他"];
7070
}
7171
}
7272
return _titlesArray;

0 commit comments

Comments
 (0)